RE: Camera Movement.
"William Woodbury" <[email protected]> Wed, 29 Mar 2006 00:49:24 -0800
| Newsgroups | gmane.games.devel.opengl |
|---|---|
| Organization | Fat City Network Services, San Diego, California |
| Message-ID | <[email protected]> |
The easiest way to do this is to take a forward vector (z axis?) then apply the rotation to it. This will give you the vector to move along to make the camera move forward. -----Original Message----- Singh Sent: 29 March 2006 06:24 To: Multiple recipients of list OPENGL-GAMEDEV-L Hello Friends, First of all let me clarify my problem. I'm able to perform rotations and translations in all three axis, using. glRotatex(-angle,x,y,z); glTranslatex(-x,-y,-z); But my real problem is of calculating View Direction. That is say if I rotate my camera along y-axis at 10 degrees and now I move forward. In this case the translation coordinates will depend on the angle(10). Yes there is no such thing like gluLookat(); Please guide me in the same. Regards & Thanks Ajit Singh Trainee Software Engineer. Lambent Technologies Pvt. Ltd. -----Original Message----- William Woodbury Sent: Tuesday, March 28, 2006 8:14 PM To: Multiple recipients of list OPENGL-GAMEDEV-L I don't think there is any GLU in OpenGL ES! Also that function is designed for pointing at a particular target, which in most cases is not the kind of view used. In fps games for instance the view has translation, rotation and elevation (generally), which can only be used in gluLookAt if the rotation is first converted to a vector. -----Original Message----- Sent: 28 March 2006 14:59 To: Multiple recipients of list OPENGL-GAMEDEV-L you can use gluLookAt function. Its very easy to use. :-) You will need to describe camera in 3 vector. Position vector (p), View Vector (v), and Up Vector (u). (u) | | | (p)----------> (v) Ajit Singh wrote: Hello Friends, I'm new to OpenGL and I want to develop a Mobile Game using OpenGL ES for Brew platform. Right now I'm stuck with camera movement in OpenGL ES. As it is clear that there is on such thing like Camera, it is been implement by transforming the world in the inverse direction. I'm following the same above concept. Please help in the same. Any Help Appreciated. -- This message has been scanned for viruses and dangerous content by and is believed to be clean. ----- FAQ and OpenGL Resources at: http://www.geocities.com/SiliconValley/Hills/9956/OpenGL -- Author: William Woodbury INET: [email protected] Fat City Hosting, San Diego, California -- http://www.fatcity.com --------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: [email protected] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB OPENGL-GAMEDEV-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- This message has been scanned for viruses and dangerous content and is believed to be clean. -- This message has been scanned for viruses and dangerous content and is believed to be clean. ----- FAQ and OpenGL Resources at: http://www.geocities.com/SiliconValley/Hills/9956/OpenGL -- Author: Ajit Singh INET: [email protected] Fat City Hosting, San Diego, California -- http://www.fatcity.com --------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: [email protected] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB OPENGL-GAMEDEV-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). -- No virus found in this incoming message. Checked by AVG Free Edition. Version: 7.1.385 / Virus Database: 268.3.3/295 - Release Date: 28/03/2006 ----- FAQ and OpenGL Resources at: http://www.geocities.com/SiliconValley/Hills/9956/OpenGL -- Author: William Woodbury INET: [email protected] Fat City Hosting, San Diego, California -- http://www.fatcity.com --------------------------------------------------------------------- To REMOVE yourself from this mailing list, send an E-Mail message to: [email protected] (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB OPENGL-GAMEDEV-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).