diff --git a/vcg/math/matrix44.h b/vcg/math/matrix44.h index 344fc937..a7ccc70f 100644 --- a/vcg/math/matrix44.h +++ b/vcg/math/matrix44.h @@ -259,7 +259,8 @@ public: Matrix44 &SetShearYZ(const T sx); ///use radiants for angle. - Matrix44 &SetRotate(T AngleRad, const Point3 & axis); + Matrix44 &SetRotateDeg(T AngleDeg, const Point3 & axis); + Matrix44 &SetRotateRad(T AngleRad, const Point3 & axis); T Determinant() const; @@ -543,7 +544,12 @@ template Matrix44 &Matrix44::SetTranslate(const T tx, const T ty ElementAt(2, 3) = tz; return *this; } -template Matrix44 &Matrix44::SetRotate(T AngleRad, const Point3 & axis) { + +template Matrix44 &Matrix44::SetRotateDeg(T AngleDeg, const Point3 & axis) { + return SetRotateRad(math::ToRad(AngleDeg),axis); +} + +template Matrix44 &Matrix44::SetRotateRad(T AngleRad, const Point3 & axis) { //angle = angle*(T)3.14159265358979323846/180; e' in radianti! T c = math::Cos(AngleRad); T s = math::Sin(AngleRad);