summaryrefslogtreecommitdiff
path: root/src/freetype2/base/ftbbox.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/freetype2/base/ftbbox.c')
-rw-r--r--src/freetype2/base/ftbbox.c21
1 files changed, 12 insertions, 9 deletions
diff --git a/src/freetype2/base/ftbbox.c b/src/freetype2/base/ftbbox.c
index 532ab13..8136ccc 100644
--- a/src/freetype2/base/ftbbox.c
+++ b/src/freetype2/base/ftbbox.c
@@ -29,6 +29,7 @@
#include FT_IMAGE_H
#include FT_OUTLINE_H
#include FT_INTERNAL_CALC_H
+#include FT_INTERNAL_OBJECTS_H
typedef struct TBBox_Rec_
@@ -559,6 +560,13 @@
return 0;
}
+FT_DEFINE_OUTLINE_FUNCS(bbox_interface,
+ (FT_Outline_MoveTo_Func) BBox_Move_To,
+ (FT_Outline_LineTo_Func) BBox_Move_To,
+ (FT_Outline_ConicTo_Func)BBox_Conic_To,
+ (FT_Outline_CubicTo_Func)BBox_Cubic_To,
+ 0, 0
+ )
/* documentation is in ftbbox.h */
@@ -628,18 +636,13 @@
/* the two boxes are different, now walk over the outline to */
/* get the Bezier arc extrema. */
- static const FT_Outline_Funcs bbox_interface =
- {
- (FT_Outline_MoveTo_Func) BBox_Move_To,
- (FT_Outline_LineTo_Func) BBox_Move_To,
- (FT_Outline_ConicTo_Func)BBox_Conic_To,
- (FT_Outline_CubicTo_Func)BBox_Cubic_To,
- 0, 0
- };
-
FT_Error error;
TBBox_Rec user;
+#ifdef FT_CONFIG_OPTION_PIC
+ FT_Outline_Funcs bbox_interface;
+ Init_Class_bbox_interface(&bbox_interface);
+#endif
user.bbox = bbox;