UI Toolkit Document is rendered pink on some android devices

Hi everyone.
I’ve got an issue in my live game that I’m struggling to solve for a long time now.
some players complained that the game “does not display graphics” and that the whole screen is pink.
for a long time I was not able to reproduce this issue until a few days ago, with a very specific emulator configuration.

In my game, 90% of the UI is using UI Toolkit, and we have a few systems that use the old UI system with a canvas. Thanks to that, i noticed that the issue comes from UI Toolkit, and when I disable the main UI document, the game renders fine.

I manage to reproduce this behavior on a fresh project, that have just 2 scenes:

  • Scene 1 - a canvas with 1 button that will navigate to scene 2
  • Scene 2 - a UI document with 1 visual element as the background and 1 text label.

scene 1 is rendered fine, and as soon as I navigate to scene 2, the whole screen is pink.

In android studio i can see the following errors when scene 2 is loaded:

eglGetConfigAttrib: Unsupported attribute 1/GL_LINES
eglGetConfigAttrib: Unsupported attribute EGL_DEPTH_ENCODING_NV
eglGetConfigAttrib: Not Implemented: attribute EGL_NATIVE_VISUAL_TYPE
eglGetConfigAttrib: Not Implemented: attribute EGL_MIN_SWAP_INTERVAL

I know that when something is rendered as pink it’s related to some issue with materials or shaders, but since the issue comes from UI Toolkit I’m kind of lost. (I tried almost any fix attempt I could find online)

If anyone encountered a similar issue or have an idea what could be the issue I’ll be grateful.

Screenshots:


Hi, dorcohendev! Since you mentioned that you’re able to reproduce the issue on a fresh project, could you please report a bug via the Bug Reporter (“Help → Report a Bug…” in the Unity Editor)? Make sure to attach the mentioned project. Cheers!

Do you have this issue only on specific devices, or every device?

And yes, reporting a bug with your test scene will help a ton.

Thanks for the reply.
Only on some devices. on most devices everything works fine.
and np, I’ll open a bug report.

Thanks for the reply.
sure thing, I’ll open a bug report and put as much data as possible.