- Home /
Fixed Screen Resolution
Is there any way i could fixed the screen resolution? i mean if it played at 800x600, 1280x1024, 1280x720, or wide screen, the camera keep showing same scene, same height and same width.. maybe by making the object bigger, or else..
Answer by haim96 · Dec 08, 2013 at 12:04 PM
check this page for dealing with screen resolutions by script: http://docs.unity3d.com/Documentation/ScriptReference/Screen.html
and this: http://docs.unity3d.com/Documentation/ScriptReference/Screen.SetResolution.html
You may also need to adjust the viewport to capture the same field of view with the camera.
i don't suggest to play with field of view. this change perspective and can cause view deformation. 60 (the default value) should simulate the natural eyes view. changing the value will cause fish eye effect...
http://docs.unity3d.com/Documentation/Components/class-Camera.html
I say this as Unity likes to change the viewport when the res changes. OP wants to keep the view consistent throughout all resolutions, so a viewport change may be necessary to achieve this. I think jpc133's W H change does the same thing.
well, i thing you wrong. :) change the FOV will change perspective view. no mater what screen size or resolution. change the view port size will change the window size in window mode or stretch\squeeze the view in full screen mode.
In Game view, you can click the box that says "Free Aspect" and set a resolution for your game view. This will help you keep things consistent. This doesn't change the build res, only editor game view.
Answer by jpc133 · Dec 08, 2013 at 11:57 AM
You could have script which checks screen resolution then edits the cameras W and H variables, have look at possibly doing that.
Your answer
![](https://koobas.hobune.stream/wayback/20220613123702im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Standalone fullscreen-fixed size 0 Answers
Fixed to the screen GUI ? 1 Answer
Clamping after forcing aspect ratio 0 Answers
Minimum resolution fix? [Solved] 0 Answers
AutoScale Screen with Perspective Camera 0 Answers