1
/***************************************************************************/
5
/* FreeType Generic Image cache (specification) */
7
/* Copyright 2000-2001, 2002, 2003, 2006 by */
8
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
10
/* This file is part of the FreeType project, and may only be used, */
11
/* modified, and distributed under the terms of the FreeType project */
12
/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
13
/* this file you indicate that you have read the license and */
14
/* understand and accept it fully. */
16
/***************************************************************************/
20
* FTC_ICache is an _abstract_ cache used to store a single FT_Glyph
21
* image per cache node.
23
* FTC_ICache extends FTC_GCache. For an implementation example,
24
* see FTC_ImageCache in `src/cache/ftbasic.c'.
28
/*************************************************************************/
30
/* Each image cache really manages FT_Glyph objects. */
32
/*************************************************************************/
35
#ifndef __FTCIMAGE_H__
36
#define __FTCIMAGE_H__
46
/* the FT_Glyph image node type - we store only 1 glyph per node */
47
typedef struct FTC_INodeRec_
52
} FTC_INodeRec, *FTC_INode;
54
#define FTC_INODE( x ) ( (FTC_INode)( x ) )
55
#define FTC_INODE_GINDEX( x ) FTC_GNODE(x)->gindex
56
#define FTC_INODE_FAMILY( x ) FTC_GNODE(x)->family
59
(*FTC_IFamily_LoadGlyphFunc)( FTC_Family family,
64
typedef struct FTC_IFamilyClassRec_
66
FTC_MruListClassRec clazz;
67
FTC_IFamily_LoadGlyphFunc family_load_glyph;
69
} FTC_IFamilyClassRec;
71
typedef const FTC_IFamilyClassRec* FTC_IFamilyClass;
73
#define FTC_IFAMILY_CLASS( x ) ((FTC_IFamilyClass)(x))
75
#define FTC_CACHE__IFAMILY_CLASS( x ) \
76
FTC_IFAMILY_CLASS( FTC_CACHE__GCACHE_CLASS(x)->family_class )
79
/* can be used as a @FTC_Node_FreeFunc */
81
FTC_INode_Free( FTC_INode inode,
84
/* Can be used as @FTC_Node_NewFunc. `gquery.index' and `gquery.family'
85
* must be set correctly. This function will call the `family_load_glyph'
86
* method to load the FT_Glyph into the cache node.
89
FTC_INode_New( FTC_INode *pinode,
94
/* can be used as @FTC_Node_WeightFunc */
96
FTC_INode_Weight( FTC_INode inode );
104
#endif /* __FTCIMAGE_H__ */