Sign in to follow this  
tokaplan

Geometric distortion

Recommended Posts

Hi everyone, After rendering a box with equal dimensions, I notice that it's being distorted (width is greater than height). On changing the screen dimensions, the distortion changes accordingly, so when it's 1024x768 (4:3) the ratio width / height looks much more like 4:3 rather than 1:1, which it should be. I don't use the full screen mode. How do I fix this? Thank you

Share this post


Link to post
Share on other sites
When creating your view Matrix you need to specify an aspect ratio. This aspect ratio should be set to (ResolutionX / ResolutionY) of your viewport. A 1280x1024 window has an aspect ratio of 1.25, while 1024x768 is 1.333 ... so you can see every time you change resolutions/window size you need to recreate the view matrix.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this