Browse Source

* fix operator order in earlier sincos commit. What was I thinking? Thanks Alexey

marcoonthegit 1 year ago
parent
commit
3f73b6b918
1 changed files with 5 additions and 11 deletions
  1. 5 11
      packages/fcl-image/src/freetype.pp

+ 5 - 11
packages/fcl-image/src/freetype.pp

@@ -554,20 +554,14 @@ begin
 end;
 end;
 
 
 procedure TFontManager.MakeTransformation (angle:real; out Transformation:FT_Matrix);
 procedure TFontManager.MakeTransformation (angle:real; out Transformation:FT_Matrix);
-var ScaledAngle,asin,acos : Real;
+var asin,acos : Real;
 begin
 begin
-  ScaledAngle :=Angle*$10000;
   with Transformation do
   with Transformation do
     begin
     begin
-    sincos(ScaledAngle,asin,acos);
-    yx:=round(asin);
-    xx:=round(acos);
-    xy:=-yx; yy:=xx;
-{   xx := round( cos(angle)*$10000);
-    xy := round(-sin(angle)*$10000);
-    yx := round( sin(angle)*$10000);
-    yy := round( cos(angle)*$10000);
-}
+      sincos(Angle,asin,acos);
+      yx:=round(asin)*$10000;
+      xx:=round(acos)*$10000;
+      xy:=-yx; yy:=xx;
     end;
     end;
 end;
 end;