I have been searching the forum, but can only find out how to rotate the camera using the mouse. What I need to do is to rotate the camera using the arrow keyes.
EET_KEY_KEY_RIGHT=rotate right etc...
Is there an example around here that will tell me how to do this? Or an example tutorial on the web?
rotate camera
rotate camera
If it exists in the real world, it can be created in 3d
Sys specs:
AMD 3700+ 64 processor
1.0 gb ram
e-Geforce 6600 graphics 256 mb onboard ram
Sys specs:
AMD 3700+ 64 processor
1.0 gb ram
e-Geforce 6600 graphics 256 mb onboard ram
-
- Posts: 69
- Joined: Wed Mar 30, 2005 8:16 am
- Location: Keerbergen, Belgium
i think you will have to code it yourself do something like this:
- store the angles in AngleX, AngleY (you dont need Z cause you can only rotate in 2 ways :p)
- if right arrow is pressed AngleX += 0.1 (or something like that)
- if left arrow is pressed AngleX -= 0.1
- if up arrow is pressed AngleY += 0.1 (or something like that)
- if down arrow is pressed AngleY -= 0.1
then do camera->setRotation(AnbleX,AngleY,0)
good luck, maybe you will have to adjust it a bit (i dont know what you want to do whit it :p)
- store the angles in AngleX, AngleY (you dont need Z cause you can only rotate in 2 ways :p)
- if right arrow is pressed AngleX += 0.1 (or something like that)
- if left arrow is pressed AngleX -= 0.1
- if up arrow is pressed AngleY += 0.1 (or something like that)
- if down arrow is pressed AngleY -= 0.1
then do camera->setRotation(AnbleX,AngleY,0)
good luck, maybe you will have to adjust it a bit (i dont know what you want to do whit it :p)