GFX: Use degree conversion common math funcs
This commit is contained in:
parent
8e1f712327
commit
e00881804f
2 changed files with 5 additions and 3 deletions
|
@ -22,12 +22,13 @@
|
|||
|
||||
|
||||
#include "graphics/transform_tools.h"
|
||||
#include "common/math.h"
|
||||
#include <math.h>
|
||||
|
||||
namespace Graphics {
|
||||
|
||||
FloatPoint TransformTools::transformPoint(FloatPoint point, const float rotate, const Common::Point &zoom, const bool mirrorX, const bool mirrorY) {
|
||||
float rotateRad = rotate * M_PI / 180.0f;
|
||||
float rotateRad = Common::deg2rad<float>(rotate);
|
||||
float x = point.x;
|
||||
float y = point.y;
|
||||
x = (x * zoom.x) / kDefaultZoomX;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue