Jump to content
  • Advertisement
Sign in to follow this  
ahmadi86

Perspective

This topic is 4134 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello What's the difference between Matrix.PerspectiveFovLH and Matrix.PerspectiveLH Methods in directX?

Share this post


Link to post
Share on other sites
Advertisement
Quote:
Original post by ahmadi86
Hello

What's the difference between Matrix.PerspectiveFovLH and
Matrix.PerspectiveLH Methods in directX?
Compare the two functions. One takes a FOV and an aspect ratio, one takes a width and height of the viewport. That's the only difference.

Share this post


Link to post
Share on other sites
Do you mean that Matrix.PerspectiveLH computes the FOV and aspect ratio
from width and height itself?

Share this post


Link to post
Share on other sites
Quote:
Original post by ahmadi86
Do you mean that Matrix.PerspectiveLH computes the FOV and aspect ratio
from width and height itself?
No, he means you can choose either function to create your perspective matrix depending on which set of parameters you wish to base it on. You can build your perspective matrix either way depending on how you have your engine coded. Do you want to supply <width, height> or <FOV, aspect> to describe your view?

Share this post


Link to post
Share on other sites
I want to simulate a real scene (which is seen by the human eyes)
What type of perspective i should use?

Share this post


Link to post
Share on other sites
Quote:
Original post by ahmadi86
I want to simulate a real scene (which is seen by the human eyes)
What type of perspective i should use?
You can't really do that without introducing a lot of distortion. The human field of view is around 180° horizontally and 135° vertically (45° above, 90° below). If you try to create a projection matrix with corresponding FOV and aspect ratio your user will have a tough time moving around. Far more common is a 90° FOV.

The reason it's so small is that the user sits a distance back from the monitor, which doesn't occupy their field of vision. It's much more like the viewer is watching the game through a window. Cramming an oversized projection onto the screen will destroy the illusion altogether.

I'm afraid there's nothing you can do about it unless you change your target audience to VR or force them to hold their faces up to the screen [rolleyes].

Admiral

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!