Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: laurentl on April 08, 2013, 03:40:43 AM

Title: Atlas breaking very often, a "shake it then rebuild atlas" button could help ?
Post by: laurentl on April 08, 2013, 03:40:43 AM
I find that Atlas do break a lot meaning the image will miss 90% of elements sometimes.
To fix it I have to remove images one by one until it works again and that is not reliable so I don't think it depends on what image has been added.
That is why I'd like to have a rebuild atlas button (or a kick atlas until it work button).
Title: Re: Atlas breaking very often, a "shake it then rebuild atlas" button could help ?
Post by: ArenMook on April 08, 2013, 02:33:04 PM
Don't exceed the max texture size. When you do that, shit hits the fan. Got large sprites? Keep them outside the atlas and use UITexture to draw them instead.
Title: Re: Atlas breaking very often, a "shake it then rebuild atlas" button could help ?
Post by: laurentl on April 08, 2013, 03:09:48 PM
Max texture size of the atlas is 4096, size of the atlas is 2048.

I'm on my 3rd rebuild and now it breaks the atlas but also I'm getting a new error from widgets that used to work:

Too many vertices on one panel: 81692
UnityEngine.Debug:LogError(Object)
UIDrawCall:Set(BetterList`1, BetterList`1, BetterList`1, BetterList`1, BetterList`1) (at Assets/NGUI/Scripts/Internal/UIDrawCall.cs:296)
UIPanel:Fill(Material) (at Assets/NGUI/Scripts/UI/UIPanel.cs:941)
UIPanel:LateUpdate() (at Assets/NGUI/Scripts/UI/UIPanel.cs:993)
Title: Re: Atlas breaking very often, a "shake it then rebuild atlas" button could help ?
Post by: Nicki on April 08, 2013, 05:22:12 PM
If you have 81692 vertices in a single panel something is amiss too. Maybe when it breaks, it doesn't clean up properly - or you simply have too much stuff in a single panel. Try splitting it up in multiple panels.
Title: Re: Atlas breaking very often, a "shake it then rebuild atlas" button could help ?
Post by: laurentl on April 09, 2013, 01:59:55 AM
Like I said, this gazilion poly happened after the atlas broke - looks like a bug.