1
NGUI 3 Support / Shaders not working on Tegra devices
« on: October 17, 2014, 10:47:50 PM »
I've just released a new app using the latest NGUI and I've been getting reports from users that none of the UI graphics are appearing.
The problem seems to be the Unlit/Transparent Colored shader. I tried changing to a different shader (that doesn't handle the border and padding correctly) and some of the UI elements showed up.
Bitmap font based text is also affected, but only when it appears to be in front of an Unlit/Transparent Colored UI element. Free floating UI Labels that are behind everything in the background are being rendered.
I was able to reproduce the problem on a Ouya console (Tegra 3), but it works fine on any other non-Tegra device.
There are no messages in the log reporting errors of any kind.
I'm still investigating, but it appears to be the shader. Any ideas?
Edit: I've now had reports of the same problem on Tegra2, 3 and 4 devices
Edit: After spending a lot of time on this, I narrowed it down. It's caused by selecting orthographic rendering with a large far value for the clipping plane. This causes only the most distant GUI objects to render, everything else vanishes. If the camera is switched to perspective, or the far value is reduced, everything will be rendered.
The problem seems to be the Unlit/Transparent Colored shader. I tried changing to a different shader (that doesn't handle the border and padding correctly) and some of the UI elements showed up.
Bitmap font based text is also affected, but only when it appears to be in front of an Unlit/Transparent Colored UI element. Free floating UI Labels that are behind everything in the background are being rendered.
I was able to reproduce the problem on a Ouya console (Tegra 3), but it works fine on any other non-Tegra device.
There are no messages in the log reporting errors of any kind.
I'm still investigating, but it appears to be the shader. Any ideas?
Edit: I've now had reports of the same problem on Tegra2, 3 and 4 devices
Edit: After spending a lot of time on this, I narrowed it down. It's caused by selecting orthographic rendering with a large far value for the clipping plane. This causes only the most distant GUI objects to render, everything else vanishes. If the camera is switched to perspective, or the far value is reduced, everything will be rendered.
