From a4a39d32ff4da978a99c357fd741c84187b2c412 Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Wed, 27 Feb 2008 11:46:05 +0000 Subject: [PATCH] From Paul Martz, "Per the discussion in osg-users, this change adds code comments to the Matrix* headers to document assumptions in the getRotate() method." --- include/osg/Matrixd | 4 ++++ include/osg/Matrixf | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/include/osg/Matrixd b/include/osg/Matrixd index aa4dafb90..03ef6aa2f 100644 --- a/include/osg/Matrixd +++ b/include/osg/Matrixd @@ -311,6 +311,10 @@ class OSG_EXPORT Matrixd #endif void setRotate(const Quat& q); + /** Get the matrix rotation as a Quat. Note that this function + * assumes a non-scaled matrix and will return incorrect results + * for scaled matrixces. Consider decompose() instead. + */ Quat getRotate() const; void setTrans( value_type tx, value_type ty, value_type tz ); diff --git a/include/osg/Matrixf b/include/osg/Matrixf index 5bcf65059..b7a20c9fc 100644 --- a/include/osg/Matrixf +++ b/include/osg/Matrixf @@ -312,6 +312,10 @@ class OSG_EXPORT Matrixf #endif void setRotate(const Quat& q); + /** Get the matrix rotation as a Quat. Note that this function + * assumes a non-scaled matrix and will return incorrect results + * for scaled matrixces. Consider decompose() instead. + */ Quat getRotate() const;