 codemastermike Registered User |
Quote
|
| 2011-10-07 13:36:41 |
|
is there a way to manually set the Rotation matrix for a 3d object?
I need to be able to set the Rotation matrix manually. Because
Im using a physics lib, and the only way to get the rotation from the physics is through a rotation matrix. The physics lib returns a 4x4 glmatrix.
|
 niko Moderator |
Quote
|
| 2011-10-07 15:54:03 |
|
There are multiple ways of doing this. An idea would be to set the matrix values you get from the library into a CL3D.Matrix4 object (for example by calling setByIndex()) and then calling getRotationDegrees() of the matrix. Use this as rotation then.
|
 codemastermike Registered User |
Quote
|
| 2011-10-10 08:28:16 |
|
Yes, that works really nicely, thanks again Niko!
|