Author Topic: Resize atlas texture even with text coords broken all labels  (Read 3400 times)

sisso

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 1
  • Posts: 46
    • View Profile
Hello,

I am trying to change atlas texture max size but it is broken the labels. These was my steps:

1 - I have everything working nice, sprites, labels, fonts and atlas.
2 - I selected atla texture and changed its max size to 512px
3 -  Every sprites has broken
4 - I reverted the atlas texture max size
5 - Changed atlas to use Text Coords
6 - Resize atlas texture again to 512
7 - Everything works fine, but, when I play and change some scenes every label get broken, but sprites didn't.

If I select the Font prefab, in the preview its show the full atlas, even with Prevew->Font selected.

I haved tryied to change Font sprite to something and get back without success.

If I reimport the font, the importer changes automatically the atlas to pixel coords and max size, but when I did steps 5-7 again, the labels got broken.

If a make changes 5-7 and restart the unity3d it always start with labels broken, I didn't need to play to mess things up.

I am doing something wrong?

Bug in persist stuff?

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Resize atlas texture even with text coords broken all labels
« Reply #1 on: July 03, 2013, 05:47:57 AM »
You can't resize an atlas texture like that and expect text to work. Fonts don't know anything about your resize operations. Bottom line: don't do it. If you need to resize your texture, either create a higher-res atlas, or at the very least remove fonts textures from it first.

sisso

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 1
  • Posts: 46
    • View Profile
Re: Resize atlas texture even with text coords broken all labels
« Reply #2 on: July 03, 2013, 07:31:57 AM »
Only  to confirm, it is ok to use textcord and resize atlas for sprites only?

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Resize atlas texture even with text coords broken all labels
« Reply #3 on: July 03, 2013, 10:09:38 AM »
Yeah

sisso

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 1
  • Posts: 46
    • View Profile
Re: Resize atlas texture even with text coords broken all labels
« Reply #4 on: July 05, 2013, 01:13:33 PM »
Nice, thanks.