Prepare source code for amalgamation (2/6).

* src/smooth/ftgrays.c, src/raster/ftraster.c: Undefine FLOOR,
CEILING, TRUNC, and SCALED before defining it.
This commit is contained in:
Vinnie Falco 2012-02-21 08:54:55 +01:00 committed by Werner Lemberg
parent 126405adde
commit 5ccebc4e1e
3 changed files with 16 additions and 0 deletions

View File

@ -1,3 +1,10 @@
2012-02-20  Vinnie Falco <vinnie.falco@gmail.com>
Prepare source code for amalgamation (2/6).
* src/smooth/ftgrays.c, src/raster/ftraster.c: Undefine FLOOR,
CEILING, TRUNC, and SCALED before defining it.
2012-02-20  Vinnie Falco <vinnie.falco@gmail.com>
Prepare source code for amalgamation (1/6).

View File

@ -428,6 +428,10 @@
/* NOTE: These operations are only valid on 2's complement processors */
#undef FLOOR
#undef CEILING
#undef TRUNC
#undef SCALED
#define FLOOR( x ) ( (x) & -ras.precision )
#define CEILING( x ) ( ( (x) + ras.precision - 1 ) & -ras.precision )

View File

@ -253,6 +253,11 @@ typedef ptrdiff_t FT_PtrDist;
/* must be at least 6 bits! */
#define PIXEL_BITS 8
#undef FLOOR
#undef CEILING
#undef TRUNC
#undef SCALED
#define ONE_PIXEL ( 1L << PIXEL_BITS )
#define PIXEL_MASK ( -1L << PIXEL_BITS )
#define TRUNC( x ) ( (TCoord)( (x) >> PIXEL_BITS ) )