Registered Member
|
Hello,
Currently i represent a orientation in R³ through a quaternion q. I want to set q through a front and up vector. They are both unit vectors and perpendicular. A orientation with a identity quaternion (no rotation) should be front = Vector3f::UnitX(); up = Vector3f::UnitZ(); Iam searching for a function (without trigo stuff..) who does somethink like this: Quaternion q; set_quaternion(&q, front_vec, up_vec); I would appreciate some help very much! greetings Benni |
Moderator
|
you need to assemble the complete basis and assign it to the quaternion:
|
Registered Member
|
Registered users: Bing [Bot], Google [Bot], Yahoo [Bot]