- Home /
Zooming without moving camera
Hello guys, I am creating an application for android in which I use isometric view having the camera fixed in 3D scene. To make some menu buttons some objects always need to be at the side of my scene , and their position should change accordingly to camera. in order to create zooming event on android, is this possible to change the positions all of the objects of the scene except those menu buttons accordingly to camera position instead of moving camera accordingly to theirs? This means that I want to zoom into objects but I still need those menu buttons which are also some objects in the scene to stay at side of my display. Any better idea to do so?
Answer by screenname_taken · Apr 28, 2014 at 08:54 AM
Either make your GUI as GUITextures, or if you have 3D poly stuff for the GUI, make a second camera that only renders your GUI elements infront of the game area (by assigning a layer just for them), and have the game area rendered on its own by another camera and zoom with that. Don't scale the objects as that will brake stuff like batching. Just change the "size" value of your iso camera.
thanks alot, It seems that GUI usage will reduce performance significantly on Android or IOS, this is why I do not want to use them. Do you mean two cameras displaying their view simultaneously?
Yes, both will render at the same time. You can set which camera will be infront of which by using the depth value on the camera object. You can set various objects in different layers and have the cameras render only some layers each (culling mask). Also, remember to check with the Clear flags variable so that the top camera won't render a solid color over the other camera.
Great, That sounds pretty good. I will try to work it out. many thanks.
Your answer
Follow this Question
Related Questions
Diagonal camera limit 0 Answers
Cinemachine Noise Messes Up Isometric Z as Y Tilemap 1 Answer
Isometric Camera not rendering correctly 0 Answers
Background hides text. How to solve that? -1 Answers
Isometric camera skybox not working. 0 Answers