This project is read-only.


Support Quaternion rotation instead of Forward,Up


Would be possible to have support for Quaternion rotation instead of Forward, Up?
Closed Nov 23, 2012 at 1:36 PM by TomLooman
This feature was added a while ago, closing issue.


TomLooman wrote Jun 6, 2011 at 12:12 PM


I know people might be more used to Quaternions and/or Matrices, while using Vector's can sometimes be much easier to use once you get the hang of it.

I will see if I can add an Quaternion function to the gizmo, it will not replace the Forward/Up - but instead wrap around it, keeping the original structure in tact...thanks for letting me know.

TomLooman wrote Jun 8, 2011 at 9:57 PM


I've added support for both Matrices and Quaterions to the SceneEntity. Forward and Up are still supported and are used by default. You can uncomment the #define USE_QUATERNIONS at the top of the source files that use rotations. (GizmoComponent, SceneEntity and ITransformable) Let me know if this is was you are looking for and if it all works correctly :)

amerthebest wrote Jun 9, 2011 at 8:43 AM

I've just tested everything, rotation mode does not work in none mode, neither your Vector mode nor Quaternion.

Could you check it please?


TomLooman wrote Jun 9, 2011 at 9:16 AM

Thanks for letting me know. The bug was caused a value that I localized by accident and was not part of the new quaternion support... rotation should now be working again.

amerthebest wrote Jun 9, 2011 at 12:29 PM

I've tested it again,
seams that when pivot is on center and you rotate both of the cubes, some strange issue happens when in Quaternion mode, but not in Vector mode, one of the cube rotates in opposite direction.


TomLooman wrote Jun 9, 2011 at 4:59 PM

I could not directly re-produce your issue, but I do believe to have fixed the issue where quaternions would blow-up by adding a normalization inside the property field, this could have been related to your issue as the results are very unexpected when not normalizing.

If you still have the same issue after updating the source, please provide me with any additional info that might help me track this down, thanks :)

amerthebest wrote Jun 9, 2011 at 8:48 PM

Tested and approved, now works everything.

You can add this features in main page.

Thanks you for adding this feature.

TomLooman wrote Jun 9, 2011 at 9:59 PM

Thanks for helping me test the new code :)

wrote Nov 23, 2012 at 1:36 PM

wrote Feb 14, 2013 at 2:36 AM

wrote May 16, 2013 at 7:50 AM