From 6c745890142600be0d5c782a27f389c8af5633bc Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Wed, 9 May 2007 09:26:33 +0000 Subject: [PATCH] Added signOrZero template method, and to Matrix_implementation.cpp usage of this method in the get(Quat&) code. --- examples/osgunittests/osgunittests.cpp | 13 +++++++++++++ include/osg/Math | 3 +++ src/osg/Matrix_implementation.cpp | 6 +++--- 3 files changed, 19 insertions(+), 3 deletions(-) diff --git a/examples/osgunittests/osgunittests.cpp b/examples/osgunittests/osgunittests.cpp index 35af6743d..258123b66 100644 --- a/examples/osgunittests/osgunittests.cpp +++ b/examples/osgunittests/osgunittests.cpp @@ -314,8 +314,21 @@ void testQuat() testQuatRotate(osg::Vec3d(0.0,0.0,-1.0),osg::Vec3d(0.0,0.0,1.0)); testGetQuatFromMatrix(); + + + osg::Matrix matrix(0.5, 0.0, 0.0, 0.0, + 0.0, 0.5, 0.0, 0.0, + 0.0, 0.0, 0.5, 0.0, + 1.0, 1.0, 1.0, 1.0); + + osg::Quat quat; + matrix.get(quat); + + osg::notify(osg::NOTICE)<<"Matrix = "<