Jump to content
  • Advertisement
Sign in to follow this  
coderchris

OpenGL Dealing with different coordinate systems across API's

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

In directx, the coordinate system places (0,0) at the top left both for rendering and texture coordinates. +Z is also oriented into the screen. For opengl on the other hand, everything that I mentioned is reversed. My question is, in a cross platform engine, how does one gracefully handle these issues? An example of where this issue is particularly bad is in specifying texture coordinates. In your vertex shader (Im using CG btw), you have to flip your texture coordinates depending on what API is being used...

Share this post


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

  • Advertisement
×

Important Information

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

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!