Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


3D to 2D projection problems..

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

Hi, I want to use my own projection matrix hiven by some function like : void SetProjection(FOV, Aspect, ZNear, ZFar); It setups projection matrix that works in software renderer. It also produces W-coordinate. My question is why I cannot see anything when I put this W-coordinate into glVertex4f(x, y, z, W)???? My code is something like : glMatrixMode(GL_PROJECTION); glLoadIdentity(); glOrtho(0, W, 0, H, 1, 10000); And then I apply projection matrix : for (i=0; i.xyz, l_ResultVector, lf_W); L1_POLYGON.vertexes[i].xyz = l_ResultVector; L1_POLYGON.vertexes[i].rhw = lf_W; } And then some viewport : for (i=0; i

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

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

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!