From f8220925c970faf6d0e71a8f89b0aa81b1111656 Mon Sep 17 00:00:00 2001 From: Tom Kacvinsky Date: Sat, 10 Mar 2001 19:01:21 +0000 Subject: [PATCH] Added prototypes and notes for three new functions: FT_RoundFix, FT_CeilFix, and FT_FloorFix. --- include/freetype/freetype.h | 68 +++++++++++++++++++++++++++++++++++++ 1 file changed, 68 insertions(+) diff --git a/include/freetype/freetype.h b/include/freetype/freetype.h index d0fb8559f..1d075907e 100644 --- a/include/freetype/freetype.h +++ b/include/freetype/freetype.h @@ -2227,6 +2227,9 @@ FT_BEGIN_HEADER /* FT_MulDiv */ /* FT_MulFix */ /* FT_DivFix */ + /* FT_RoundFix */ + /* FT_CeilFix */ + /* FT_FloorFix */ /* FT_Vector_Transform */ /* FT_Matrix_Multiply */ /* FT_Matrix_Invert */ @@ -2322,6 +2325,71 @@ FT_BEGIN_HEADER FT_Long b ); + /*************************************************************************/ + /* */ + /* */ + /* FT_RoundFix */ + /* */ + /* */ + /* A very simple function used to round a 16.16 fixed number */ + /* */ + /* */ + /* a :: The number to be rounded. */ + /* */ + /* */ + /* The result of `(a + 0x8000) & -0x10000'. */ + /* */ + /* */ + /* This function assumes that the target platform supports 32 bit */ + /* signed integers. */ + /* */ + FT_EXPORT( FT_Fixed ) FT_RoundFix( FT_Fixed a ); + + + /*************************************************************************/ + /* */ + /* */ + /* FT_CeilFix */ + /* */ + /* */ + /* A very simple function used to compute the ceiling function of a */ + /* 16.16 fixed number */ + /* */ + /* */ + /* a :: The number for which the ceiling function is to be computed. */ + /* */ + /* */ + /* The result of `(a + 0x10000 - 1) & -0x10000'. */ + /* */ + /* */ + /* This function assumes that the target platform supports 32 bit */ + /* signed integers. */ + /* */ + FT_EXPORT( FT_Fixed ) FT_CeilFix( FT_Fixed a ); + + + /*************************************************************************/ + /* */ + /* */ + /* FT_FloorFix */ + /* */ + /* */ + /* A very simple function used to compute the floor function of a */ + /* 16.16 fixed number */ + /* */ + /* */ + /* a :: The number for which the floor function is to be computed. */ + /* */ + /* */ + /* The result of `a & -0x10000'. */ + /* */ + /* */ + /* This function assumes that the target platform supports 32 bit */ + /* signed integers. */ + /* */ + FT_EXPORT( FT_Fixed ) FT_FloorFix( FT_Fixed a ); + + /*************************************************************************/ /* */ /* */