- Home /
How to put 3d object between two canvases?
I'm making a character setting view with 3d character and gui.
I want to use two canvases, therefore I can locate my 3d object between these 2 gui layers. In the picture, I want to put red button above the cat mesh.
I made it work by setting bottom canvas render mode to 'Screen Space-Camera' and top canvas render mode to 'Screen Space-Overlay'. But it's not nice because in editor view, I cannot work on my gui at once ( as 2 canvases differ in size and position )
Is there any better way to do this? Thank you in advance.
Answer by jeffreyrampineda · Nov 21, 2017 at 07:52 AM
Try using RenderTexture: https://forum.unity.com/threads/what-is-the-best-way-to-display-3d-models-as-ui-elements.343205/
Is there no fps issue for using render texture on mobile? I also need to rotate or animate 3d object.
Sorry I'm not entirely sure about mobiles. Also, yes, you can rotate or animate 3d objects. The way it works is kind of like having another Camera look at the 3d object and it will be rendered as textures. $$anonymous$$ind of like a television:
Skip to 3:40 for quick example: https://www.youtube.com/watch?v=pA7ZC8owaeo
Thank you :) I'll try using render texture.
Your answer
![](https://koobas.hobune.stream/wayback/20220612143105im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Unity 4.6 adding a Canvas Text onto a gameobject prefab?? -1 Answers
Screen space canvas not resizing correctly when android device is rotated 0 Answers
Using Canvas/Gui with splitscreen(several cameras) 0 Answers
[VR] How to display a canvas with Oculus 5 Answers
Good way to scale 3D GameObjects in a Canvas (Screen Space - Camera)? 1 Answer