We are using a camera system that will rotate with respect a fixed target. The camera is transformed (rotated) only when the mouse button is pressed and moved. An object (say a cylinder) is oriented in a particular direction (using setRotation function, given an angle). The object is aligned with camera in its initial position. The object(cylinder) is moved by mapping it with the mouse movement i.e., when the mouse is moved, the object gets translated in the scene.
When the camera is rotated in the scene by pressing the mouse button, we would like to orient the object along with camera, so as to preserve its initial alignment. Could any one help me on how to achieve it.
Object orientation(rotation) with respect to camera
-
saransiva_ps
- Posts: 3
- Joined: Thu Jun 19, 2008 6:52 am