aboutsummaryrefslogtreecommitdiff
path: root/freetype/src/cache/ftccache.h
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2011-01-16 17:43:39 +0000
committermarha <marha@users.sourceforge.net>2011-01-16 17:43:39 +0000
commit2177eb8fad173f2b0fe04f188c4d6dadaa8f4441 (patch)
tree862ef4b348586f932593a7d2b599913230059cdd /freetype/src/cache/ftccache.h
parent367c91bebcdc1f5ba4278b68eb8715218d9640ad (diff)
downloadvcxsrv-2177eb8fad173f2b0fe04f188c4d6dadaa8f4441.tar.gz
vcxsrv-2177eb8fad173f2b0fe04f188c4d6dadaa8f4441.tar.bz2
vcxsrv-2177eb8fad173f2b0fe04f188c4d6dadaa8f4441.zip
freetype 2.4.4
Diffstat (limited to 'freetype/src/cache/ftccache.h')
-rw-r--r--freetype/src/cache/ftccache.h11
1 files changed, 7 insertions, 4 deletions
diff --git a/freetype/src/cache/ftccache.h b/freetype/src/cache/ftccache.h
index 1b695849c..10830a9f8 100644
--- a/freetype/src/cache/ftccache.h
+++ b/freetype/src/cache/ftccache.h
@@ -24,6 +24,9 @@
FT_BEGIN_HEADER
+#define _FTC_FACE_ID_HASH( i ) \
+ ((FT_PtrDist)(( (FT_PtrDist)(i) >> 3 ) ^ ( (FT_PtrDist)(i) << 7 )))
+
/* handle to cache object */
typedef struct FTC_CacheRec_* FTC_Cache;
@@ -56,7 +59,7 @@ FT_BEGIN_HEADER
{
FTC_MruNodeRec mru; /* circular mru list pointer */
FTC_Node link; /* used for hashing */
- FT_UInt32 hash; /* used for hashing too */
+ FT_PtrDist hash; /* used for hashing too */
FT_UShort cache_index; /* index of cache the node belongs to */
FT_Short ref_count; /* reference count for this node */
@@ -168,14 +171,14 @@ FT_BEGIN_HEADER
#ifndef FTC_INLINE
FT_LOCAL( FT_Error )
FTC_Cache_Lookup( FTC_Cache cache,
- FT_UInt32 hash,
+ FT_PtrDist hash,
FT_Pointer query,
FTC_Node *anode );
#endif
FT_LOCAL( FT_Error )
FTC_Cache_NewNode( FTC_Cache cache,
- FT_UInt32 hash,
+ FT_PtrDist hash,
FT_Pointer query,
FTC_Node *anode );
@@ -200,7 +203,7 @@ FT_BEGIN_HEADER
FT_BEGIN_STMNT \
FTC_Node *_bucket, *_pnode, _node; \
FTC_Cache _cache = FTC_CACHE(cache); \
- FT_UInt32 _hash = (FT_UInt32)(hash); \
+ FT_PtrDist _hash = (FT_PtrDist)(hash); \
FTC_Node_CompareFunc _nodcomp = (FTC_Node_CompareFunc)(nodecmp); \
FT_UFast _idx; \
\