I cannot give perfect details on this, as my QA source has described the error to me, but I have not seen it myself. It may not even be related to NGUI, but given the similarity to
this topic, I want to explore the idea at least in case there's something I'm missing here.
Already, I found that the issue in the above topic was an issue in my game. That is now fixed, where previously I had a 2048x4096 texture, now everything is 2048x2048 for the Nexus 7 (whose max texture size is 2048).
Even so, in the process I found a
Unity Answer that said Resize could also create a similar issue. It suggested that
this code would work, which uses these functions...
tex.Resize (newWidth, newHeight);
tex.SetPixels32 (newColors);
tex.Apply();
...so I double checked all the code in my project, and found that NGUI's UITexturePacker.cs file uses...
texture.Resize(width, height);
texture
.SetPixels(new Color
[width
* height
]);
...and now my question is, why isn't Apply() used in NGUI? Is there any chance this could be causing my black and grey box problems (where textures end up as not what they should be, but instead as grey boxes that flicker to black (or potentially flicker to transparent on top of a black background))? This issue has only been seen on a Nexus 7 after minimizing the Unity game, then maximizing it later, and has not been tested since I fixed the atlas size issue (so I'm hoping to just be extra thorough in my fixes before sending it off for another round of testing).
Many thanks for any and all help!