Since angles are stored in radians, we need to add on PI, not 0.5 to rotate by 180...
authordooglus <dooglus@1f10aa63-cdf2-0310-b900-c93c546f37ac>
Fri, 28 Sep 2007 02:07:20 +0000 (02:07 +0000)
committerdooglus <dooglus@1f10aa63-cdf2-0310-b900-c93c546f37ac>
Fri, 28 Sep 2007 02:07:20 +0000 (02:07 +0000)
git-svn-id: http://svn.voria.com/code@783 1f10aa63-cdf2-0310-b900-c93c546f37ac

ETL/trunk/ETL/_angle.h

index 3868b3e..ae3b157 100644 (file)
@@ -122,8 +122,8 @@ public:
        operator~()const
        {
                angle ret;
-               ret.v=(value_type)std::floor(v+0.5f);
-               return ret;
+               ret.v = v+PI;
+               return ret.mod();
        }
 
        /*! Returns true if the shortest