Aspect Ratio in 3D

Started by
0 comments, last by Tachikoma 12 years, 2 months ago
Here's something I've always wondered about.

What kinds of things are going on when the same game is viewed in different aspect ratios? Is more of the scene present in widescreen than non-widescreen, or is the game written using one ratio and then scaled accordingly to match the new ratio?

I tried to look for this online, but I wasn't sure what to search for.

Thanks, guys!
Advertisement
Well, the 3D side of things are completely independent of the display space. The only connection between the two are matrices, more importantly, the projection matrix. So that means the aspect ratio is usually defined by the projection matrix.

Now, to accomodate different aspect ratios, you could choose from several methids. One trick is to keep the vertical FOV (field of view) constant, and only change the horizontal FOV. Other method keeps the horizontal fixed and changes the vertical one. Or you could also use some combination of both.

Your real problem is the display resolution vs. the display aspect ratio. For example, the graphics card may expose a bunch of display resolutions with 4:3 aspect ratios, even though the display itself is 16:9 or 16:10. The reverse may also be true. By looking at the display mode list, there is no reliable way to know what physical aspect ratio the display uses, unless you do some OS specific queries about the display hardware and its native resolution. Even then, such info may not be available.

I guess your "fail safe" option is to allow your users to explicity chage the projection matrix aspect ratio, if needed.
Latest project: Sideways Racing on the iPad

This topic is closed to new replies.

Advertisement