Jump to content

  • Log In with Google      Sign In   
  • Create Account

Banner advertising on our site currently available from just $5!


1. Learn about the promo. 2. Sign up for GDNet+. 3. Set up your advert!


DirectX - Is it Using only left angle triangles?


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
2 replies to this topic

#1 sara_DE   Members   -  Reputation: 127

Like
0Likes
Like

Posted 22 October 2012 - 11:21 PM

Hi,

DirectX is using Left handed co- ordinate system, so Can we say DirectX Using only left angle triangles?, or is there any other reasons for that, or it is using both (left angle and right angle) angle triangles?.


Thanks,
Bye. Posted Image

Sponsor:

#2 Tom KQT   Members   -  Reputation: 1637

Like
1Likes
Like

Posted 23 October 2012 - 01:33 AM

What do you mean by left angle triangle? A right-angled triangle (or just right triangle) is a triangle with one right angle (90 degrees). But left angle triangle? There's nothing like that ;)

DirectX is "using" left-handed coordinate system. But this in fact doesn't mean much, you can use right-handed system in DirectX with absolutely no problem if you want. The D3DX library even provided you both LH and RH versions of all functions that are dependent on the coordinate system, like D3DXMatrixPerspectiveRH/LH, D3DXMatrixLookAtRH/LH etc.

Switching between LH and RH system requires just proper view and projection matrices (using the above mentioned functions with proper ending ...RH / ...LH), proper winding order of your triangles vertices (+ proper backface culling mode) and maybe proper layout of cube textures? None of these is strictly dictated by DirectX, it depends purely on you - on how do you generate your meshes (in 3ds max or maya or ...) and how do you set the transform matrices.



Btw, of course also your world/scene/map/terrain/whatever coordinates must correspond to the coordinate system you're using, but this has ABSOLUTELY nothing to do with DirectX.

Edited by Tom KQT, 23 October 2012 - 01:42 AM.


#3 Gavin Williams   Members   -  Reputation: 807

Like
0Likes
Like

Posted 24 October 2012 - 03:34 AM

I always use RH (Right Handed) systems. And I use Counter-ClockWise winding to indicate front face. I'm using SlimDX so those facilities are available in DirectX as Tom has explained.




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS