Skip to main content
gamedev.net
🔒 Locked

orientation & camera matrix problems

Started by bobatefrei Apr 30, 2001 at 7:33 AM 0 replies 250+ views
Original Post
bobatefrei
bobatefrei
First excuse me because I''m french and I don''t speak english... I try to write a 3D game with an aeroplane, so I need to define his orientation and his rotation. I use 4 vectors and 1 matrix: Vector pos, side, up, look;//local repair of the aeroplane GLfloat orientation[][] = { {side.x, up.x, look.x, 0}, {side.y, up.y, look.z, 0}, {side.z, up.y, look.z, 0}, {pos.x, pos.y, pos.z, 1}}; The render code looks like: glPushMatrix(); gluLookAt(...) glPushMatrix(); glMulMatrixf(orientation); DrawAeroplane(); glPopMatrix(); glPopMatrix(); My problem is that don''t work, the aeroplane seems turn in inverse angle! Please help me!

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.