ReactOS 0.4.16-dev-2354-g16de117
ftcimage.h
Go to the documentation of this file.
1/****************************************************************************
2 *
3 * ftcimage.h
4 *
5 * FreeType Generic Image cache (specification)
6 *
7 * Copyright (C) 2000-2020 by
8 * David Turner, Robert Wilhelm, and Werner Lemberg.
9 *
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.
15 *
16 */
17
18
19 /*
20 * FTC_ICache is an _abstract_ cache used to store a single FT_Glyph
21 * image per cache node.
22 *
23 * FTC_ICache extends FTC_GCache. For an implementation example,
24 * see FTC_ImageCache in `src/cache/ftbasic.c'.
25 */
26
27
28 /**************************************************************************
29 *
30 * Each image cache really manages FT_Glyph objects.
31 *
32 */
33
34
35#ifndef FTCIMAGE_H_
36#define FTCIMAGE_H_
37
38
39#include <freetype/ftcache.h>
40#include "ftcglyph.h"
41
43
44
45 /* the FT_Glyph image node type - we store only 1 glyph per node */
46 typedef struct FTC_INodeRec_
47 {
50
52
53#define FTC_INODE( x ) ( (FTC_INode)( x ) )
54#define FTC_INODE_GINDEX( x ) FTC_GNODE(x)->gindex
55#define FTC_INODE_FAMILY( x ) FTC_GNODE(x)->family
56
57 typedef FT_Error
59 FT_UInt gindex,
61 FT_Glyph *aglyph );
62
63 typedef struct FTC_IFamilyClassRec_
64 {
67
69
71
72#define FTC_IFAMILY_CLASS( x ) ((FTC_IFamilyClass)(x))
73
74#define FTC_CACHE_IFAMILY_CLASS( x ) \
75 FTC_IFAMILY_CLASS( FTC_CACHE_GCACHE_CLASS(x)->family_class )
76
77
78 /* can be used as a @FTC_Node_FreeFunc */
79 FT_LOCAL( void )
82
83 /* Can be used as @FTC_Node_NewFunc. `gquery.index' and `gquery.family'
84 * must be set correctly. This function will call the `family_load_glyph'
85 * method to load the FT_Glyph into the cache node.
86 */
88 FTC_INode_New( FTC_INode *pinode,
89 FTC_GQuery gquery,
91
92#if 0
93 /* can be used as @FTC_Node_WeightFunc */
95 FTC_INode_Weight( FTC_INode inode );
96#endif
97
98
99 /* */
100
102
103#endif /* FTCIMAGE_H_ */
104
105
106/* END */
#define FT_LOCAL(x)
FT_BEGIN_HEADER struct FTC_FamilyRec_ * FTC_Family
FT_BEGIN_HEADER struct FTC_INodeRec_ FTC_INodeRec
struct FTC_IFamilyClassRec_ FTC_IFamilyClassRec
const FTC_IFamilyClassRec * FTC_IFamilyClass
Definition: ftcimage.h:70
FTC_INode_Free(FTC_INode inode, FTC_Cache cache)
Definition: ftcimage.c:49
FT_Error(* FTC_IFamily_LoadGlyphFunc)(FTC_Family family, FT_UInt gindex, FTC_Cache cache, FT_Glyph *aglyph)
Definition: ftcimage.h:58
FTC_INode_New(FTC_INode *pinode, FTC_GQuery gquery, FTC_Cache cache)
Definition: ftcimage.c:58
FT_BEGIN_HEADER struct FTC_INodeRec_ * FTC_INode
#define FT_END_HEADER
Definition: ftheader.h:57
#define FT_BEGIN_HEADER
Definition: ftheader.h:37
unsigned long FT_ULong
Definition: fttypes.h:253
int FT_Error
Definition: fttypes.h:299
unsigned int FT_UInt
Definition: fttypes.h:231
FTC_MruListClassRec clazz
Definition: ftcimage.h:65
FTC_IFamily_LoadGlyphFunc family_load_glyph
Definition: ftcimage.h:66
FTC_GNodeRec gnode
Definition: ftcimage.h:48
FT_Glyph glyph
Definition: ftcimage.h:49
Definition: cache.c:49
Definition: fs.h:78