Is it possible to draw a 3d object on top of the GUI layer?
I’m trying:
GUI.depth = 1;
but that doesn’t work. Is it even possible?
Is it possible to draw a 3d object on top of the GUI layer?
I’m trying:
GUI.depth = 1;
but that doesn’t work. Is it even possible?
It’s not possible.
–Eric
Well, you could render the 3d object into a render texture, and then draw that on the GUI layer. With some clever mouse input checks, you could then get the object to turn etc., when moving the mouse. Or select the object by shooting the raycast from the view of the camera that renders the object (from the render texture camera).
I have done something similar with a cinema. It had a minimap with a rendering of all seats from above. You could click on this map, and the raycast would be shot from the view of the render texture camera, enabling you to select seats from this map. Works perfect.
If you do it right, the user will have no idea your GUI texture, the render texture, is anything other than an actual 3d object…