diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2021-11-19 00:22:31 +0300 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2021-11-19 15:42:03 +0100 |
commit | bc0ab08634f59e1a1814e575fe6ad5e50bf1aee1 (patch) | |
tree | 8691eec1adefd9e4def8245898e8a3e5c5542037 /tools | |
parent | 168ae4c00a86b7534dedd303f9ef008e19822b99 (diff) |
Drop F_PI1800/F_PI18000, and unify deg2rad/rad2deg conversions
Change-Id: Ib89b00c3dc8cd440e8a88906eea133becd1cef64
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/125509
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Tested-by: Jenkins
Diffstat (limited to 'tools')
-rw-r--r-- | tools/source/generic/point.cxx | 2 | ||||
-rw-r--r-- | tools/source/generic/poly.cxx | 2 | ||||
-rw-r--r-- | tools/source/generic/poly2.cxx | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/tools/source/generic/point.cxx b/tools/source/generic/point.cxx index 7308d25f7878..e9c3bd842a15 100644 --- a/tools/source/generic/point.cxx +++ b/tools/source/generic/point.cxx @@ -70,7 +70,7 @@ void Point::RotateAround( tools::Long& rX, tools::Long& rY, } else { - double nRealOrientation = nOrientation.get() * F_PI1800; + double nRealOrientation = toRadians(nOrientation); double nCos = cos( nRealOrientation ); double nSin = sin( nRealOrientation ); diff --git a/tools/source/generic/poly.cxx b/tools/source/generic/poly.cxx index 6a9aff2be250..13d2df0e47ef 100644 --- a/tools/source/generic/poly.cxx +++ b/tools/source/generic/poly.cxx @@ -1404,7 +1404,7 @@ void Polygon::Rotate( const Point& rCenter, Degree10 nAngle10 ) if( nAngle10 ) { - const double fAngle = F_PI1800 * nAngle10.get(); + const double fAngle = toRadians(nAngle10); Rotate( rCenter, sin( fAngle ), cos( fAngle ) ); } } diff --git a/tools/source/generic/poly2.cxx b/tools/source/generic/poly2.cxx index 631e88caf401..c6d0a46032c8 100644 --- a/tools/source/generic/poly2.cxx +++ b/tools/source/generic/poly2.cxx @@ -261,7 +261,7 @@ void PolyPolygon::Rotate( const Point& rCenter, Degree10 nAngle10 ) if( nAngle10 ) { - const double fAngle = F_PI1800 * nAngle10.get(); + const double fAngle = toRadians(nAngle10); Rotate( rCenter, sin( fAngle ), cos( fAngle ) ); } } |