Rotation Quaternions

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
dankot
Posts: 9
Joined: Wed Sep 16, 2009 11:43 am

Rotation Quaternions

Post by dankot »

Hello,
I have a SceneNode that attached to it is a regular camera.
They both are created in an existing "world".

I want to rotate the Node that I created (and with it its child camera),
using quaternions which I already hold in my memory.

I'm trying to use the node->setRotation func but I get some kind of weird yaw that is zeroed on 180 DEG.

how can I use my rotated quaternion to rotate the Irrlicht node?


Thanks :) ,
Dan
dankot
Posts: 9
Joined: Wed Sep 16, 2009 11:43 am

Post by dankot »

just to add,
that previously when I was using OGRE what I did to get the result I want now was

Code: Select all

Quaternion quat = Quaternion(Degree(45),Vector3::UNIT_Y);
yourSceneNode->setOrientation(quat);

hopes this help to get my message through.
Dan
egrath
Posts: 28
Joined: Wed May 13, 2009 8:15 am
Location: Austria
Contact:

Post by egrath »

Hello,
convert the quaternion to euler angles and use them (quaternion::toEuler)
Egon
Post Reply