X-Git-Url: https://git.reactos.org/?p=reactos.git;a=blobdiff_plain;f=lib%2F3rdparty%2Ffreetype%2Finclude%2Ffreetype%2Fftcache.h;h=6af53062283b7232a063de6ae81ce593688d261c;hp=0916d70a37efd62e39876d34b1e5de317edd90b0;hb=b726d7355f0aa394852fa8c56e59cfc9bbc4293c;hpb=9ab4e6808d239977bcba0066e3ca3a64bec5d64b diff --git a/lib/3rdparty/freetype/include/freetype/ftcache.h b/lib/3rdparty/freetype/include/freetype/ftcache.h index 0916d70a37e..6af53062283 100644 --- a/lib/3rdparty/freetype/include/freetype/ftcache.h +++ b/lib/3rdparty/freetype/include/freetype/ftcache.h @@ -4,7 +4,7 @@ /* */ /* FreeType Cache subsystem (specification). */ /* */ -/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 by */ +/* Copyright 1996-2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2010 by */ /* David Turner, Robert Wilhelm, and Werner Lemberg. */ /* */ /* This file is part of the FreeType project, and may only be used, */ @@ -56,9 +56,12 @@ FT_BEGIN_HEADER * interpret them in any way. * * Second, the cache calls, only when needed, a client-provided function - * to convert a @FTC_FaceID into a new @FT_Face object. The latter is + * to convert an @FTC_FaceID into a new @FT_Face object. The latter is * then completely managed by the cache, including its termination - * through @FT_Done_Face. + * through @FT_Done_Face. To monitor termination of face objects, the + * finalizer callback in the `generic' field of the @FT_Face object can + * be used, which might also be used to store the @FTC_FaceID of the + * face. * * Clients are free to map face IDs to anything else. The most simple * usage is to associate them to a (pathname,face_index) pair that is @@ -211,12 +214,17 @@ FT_BEGIN_HEADER /* */ +#ifdef FT_CONFIG_OPTION_OLD_INTERNALS + + /* these macros are incompatible with LLP64, should not be used */ + #define FT_POINTER_TO_ULONG( p ) ( (FT_ULong)(FT_Pointer)(p) ) #define FTC_FACE_ID_HASH( i ) \ ((FT_UInt32)(( FT_POINTER_TO_ULONG( i ) >> 3 ) ^ \ ( FT_POINTER_TO_ULONG( i ) << 7 ) ) ) +#endif /* FT_CONFIG_OPTION_OLD_INTERNALS */ /*************************************************************************/ /*************************************************************************/ @@ -263,10 +271,10 @@ FT_BEGIN_HEADER /* reference-counted. A node with a count of~0 might be flushed */ /* out of a full cache whenever a lookup request is performed. */ /* */ - /* If you lookup nodes, you have the ability to `acquire' them, i.e., */ - /* to increment their reference count. This will prevent the node */ - /* from being flushed out of the cache until you explicitly `release' */ - /* it (see @FTC_Node_Unref). */ + /* If you look up nodes, you have the ability to `acquire' them, */ + /* i.e., to increment their reference count. This will prevent the */ + /* node from being flushed out of the cache until you explicitly */ + /* `release' it (see @FTC_Node_Unref). */ /* */ /* See also @FTC_SBitCache_Lookup and @FTC_ImageCache_Lookup. */ /* */ @@ -697,11 +705,17 @@ FT_BEGIN_HEADER (d1)->width == (d2)->width && \ (d1)->flags == (d2)->flags ) +#ifdef FT_CONFIG_OPTION_OLD_INTERNALS + + /* this macro is incompatible with LLP64, should not be used */ + #define FTC_IMAGE_TYPE_HASH( d ) \ (FT_UFast)( FTC_FACE_ID_HASH( (d)->face_id ) ^ \ ( (d)->width << 8 ) ^ (d)->height ^ \ ( (d)->flags << 4 ) ) +#endif /* FT_CONFIG_OPTION_OLD_INTERNALS */ + /*************************************************************************/ /* */ @@ -1093,6 +1107,7 @@ FT_BEGIN_HEADER (f1)->pix_width == (f2)->pix_width && \ (f1)->pix_height == (f2)->pix_height ) + /* this macro is incompatible with LLP64, should not be used */ #define FTC_FONT_HASH( f ) \ (FT_UInt32)( FTC_FACE_ID_HASH((f)->face_id) ^ \ ((f)->pix_width << 8) ^ \