Commit 515bdfef7e5e46f8a32d908ea49c28b0a867c263

anuj 2023-01-04T19:15:38

[sdf] Use 32-bit integers internally. * src/sdf/ftsdfcommon.h (FT_16D16, FT_26D6): Use 32-bit integers instead of `FT_Fixed` for internal data types. `FT_Fixed` i.e. `signed long` is 64-bit on some architectures.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
diff --git a/src/sdf/ftsdfcommon.h b/src/sdf/ftsdfcommon.h
index 3b866a1..60ca977 100644
--- a/src/sdf/ftsdfcommon.h
+++ b/src/sdf/ftsdfcommon.h
@@ -115,8 +115,8 @@ FT_BEGIN_HEADER
   typedef FT_Vector FT_26D6_Vec;   /* with 26.6 fixed-point components  */
   typedef FT_Vector FT_16D16_Vec;  /* with 16.16 fixed-point components */
 
-  typedef FT_Fixed  FT_16D16;      /* 16.16 fixed-point representation  */
-  typedef FT_Fixed  FT_26D6;       /* 26.6 fixed-point representation   */
+  typedef FT_Int32  FT_16D16;      /* 16.16 fixed-point representation  */
+  typedef FT_Int32  FT_26D6;       /* 26.6 fixed-point representation   */
   typedef FT_Byte   FT_SDFFormat;  /* format to represent SDF data      */
 
   typedef FT_BBox   FT_CBox;       /* control box of a curve            */