Move proscene camera witouht mouse
in
Contributed Library Questions
•
5 months ago
I'm trying to mimic proscene's camera movements without using the mouse but it seems I'm not undestanding it quite well. I want to rotate the camera to mimic look up, down, left and right.
From this
interesting thread I got this example to rotate the camera
- scene.camera().frame().rotate(new Quaternion(new PVector(0,0,1), PApplet.QUARTER_PI));
It seemed intuitive that for a "look up" rotation I should rotate using the camera's upVector as axis like this
- scene.camera().frame().rotate(new Quaternion(scene.camera().upVector(), radians(1)));
But it doesn´t work as I expected. What am I doing wrong?
Thanks.
1