Jump to content
  • Advertisement
Sign in to follow this  

rotate or translate is the q

This topic is 3932 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 everyone, this i know, to draw an object in ogl you translate, then rotate it. good if you want to move an object on 1 of the axis of the object, you rotate, then translate (is this correct?) im trying make an app to visualize how to make "cut-outs" on paper (like we did when we were A LOT younger) so if i have a grid ( x and z axis) and a few point on it, to make a triangle move along the lines, you would.. drawgrid loop (for all triangles) glpushmatrix glrotate (triangle in the right direction, usig atan2) gltranslate (the triangles front point, increase z axis) draw traingle glpopmatrix this does not work. either it rotates around middle an outwards, or move in right direction til new point is reached then goes bezerk. so simple task, but so annoying!

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!