Jump to content
  • Advertisement
Sign in to follow this  
Grattier

[MDX] Top view of a 3D object..

This topic is 4561 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

I have a cylinder and my projection is PerspectiveFovLH ... Now I want to set my projection to a Top view so i can see my cylinder from the top. My problem is... when you look at a cylinder in PerspectiveFovLH, each side look curved... i don't wan't to see that... I just want to see it like in reality... no curved side How can I do that?

Share this post


Link to post
Share on other sites
Advertisement
I'm not sure I quite follow your description, but I'll guess that you're referring to the "perspective" part of D3DXMatrixPerspectiveFovLH(). If I'm correct, then you'll want to look at the Orthogonal projections (with "Ortho" in their name) - D3DXMatrixOrthoLH() and D3DXMatrixOrthoOffCenterLH().

hth
Jack

Share this post


Link to post
Share on other sites
My topic begin with [MDX] wich mean i'm asking for managed DirectX help.. you talk to me about unmanaged directx .. iknow it's similar but it's not what i want.. and i just dont understans how ortho work because i can't get all my scece in my windows when i try ortho

Share this post


Link to post
Share on other sites
Quote:
Original post by Grattier
My topic begin with [MDX] wich mean i'm asking for managed DirectX help.. you talk to me about unmanaged directx .. iknow it's similar but it's not what i want.. and i just dont understans how ortho work because i can't get all my scece in my windows when i try ortho

heh, apologies about the MDX part - I obviously wasn't paying enough attention [wink]

You seem to indicate you've found it, but Matrix.OrthoLH and Matrix.OrthoOffCenterLH should be the MDX equivalents of what I referred to.

Orthographic projections will give you different results to perspective - the view frustum is essentially a different shape. It might take some experimentation to find an equivalent set of ortho parameters that give you the results you want.

A screenshot might well be of use when it comes to explaining what is wrong and what you're actually trying to get.

Jack

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!