Skip to main content

TMP Text Mesh Pro rendering behind UI Image component wrong rendering order

This is possibly due to a bug in Unity Playworks Plugin where the game object hierarchy order isn’t being taken into account when rendering.

Possible solution:

  • Apply ZWrite On and ZTest LEQual in both the TMP and Image component shaders.

    images-large

If you need the adjust one of the Unity built-in shaders, they can be downloaded here and then added to the project. Next, move the TMP text slightly more towards the camera so that it renders in front of the background.

images-large

Full example:

![images-large](/assets/common-issues/fix-tmp-example.pn