0

In the following screenshot we can observe that the canvas renderer is covered by another game object (which is also a mesh renderer by the way). However, the mesh renderer (which is at the same z position from the camera is never covered by another game object:

screenshot

I have tried to use a Screen Overlay, but I cannot use it because I'm using the Google Cardboard - Google VR asset.

I also have tried using a Transform instead a Rect Transform with the same result.

I have changed the z position with a weird behaviour of a result:

screenshot2

Should I use something like layers to fix this? Why the weird behaviour of changing the z coordinate? (It is a child of the camera, so I guess modifying the z should make it closer). The workaround would be changing the z to make it closer (so it won't be covered by the other game object) and reducing the scale.


UPDATE:

I have used the code of the following link that add the possibility of adding a sorting layer to a (3d) mesh renderer. The sorting layer appear in the inspector, but it does not seem to work anymore: http://forum.unity3d.com/threads/drawing-order-of-meshes-and-sprites.212006/

chelder
  • 3,819
  • 6
  • 56
  • 90

1 Answers1

0

What I have done is using a font with a character which is a target: http://fontello.com/#search=target

I don't know why the Text Mesh component is never covered by the other 3D Mesh Renderer. So it worked.

chelder
  • 3,819
  • 6
  • 56
  • 90