This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Is there any implementation of Rotation3D?

Tags: None
(comma "," separated)
coolcat
Registered Member
Posts
20
Karma
0
OS
Hi~
I need a three-dimensional matrix representation of rotation.
Is there any implementation of the so-called Rotation3D having internal representation of Matrix3d (or Matrix 3f) available?

Please help.

~jh
User avatar
ggael
Moderator
Posts
3447
Karma
19
OS
for 3D rotations look at Quaternion and AngleAxis. They both can be converted from/to each other, and from/to 3x3 rotation matrices.
coolcat
Registered Member
Posts
20
Karma
0
OS
Can I expect no performance penalty?
Rather I'd like to deal with rotation per se, rather than with quaternion or angle-axis vector, because the rotation matrix itself is referenced regularly more often. Computing the rotation matrix in terms of quaternion of angle-axis vector seems to incur performance penalty.

One doable solution might be add a matrix representation to quaternion of angle-axis. Rather than this, I'd like to have Eigen::Rotation3D having matrix representation, which may be constructed by quaternion of angle-axis vector.
User avatar
ggael
Moderator
Posts
3447
Karma
19
OS
Just use a 3x3 matrix, I don't see any good advantage of warping it inside a Rotation3D class, and you want a Rotation3D type, then do a typedef.
coolcat
Registered Member
Posts
20
Karma
0
OS
Ok. Thanks. I'll try.


Bookmarks



Who is online

Registered users: Bing [Bot], claydoh, Google [Bot], rblackwell, Yahoo [Bot]