ReactOS 0.4.16-dev-2384-gff6bd79
pshrec.h
Go to the documentation of this file.
1/****************************************************************************
2 *
3 * pshrec.h
4 *
5 * Postscript (Type1/Type2) hints recorder (specification).
6 *
7 * Copyright (C) 2001-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 *
21 * The functions defined here are called from the Type 1, CID and CFF
22 * font drivers to record the hints of a given character/glyph.
23 *
24 * The hints are recorded in a unified format, and are later processed
25 * by the `optimizer' and `fitter' to adjust the outlines to the pixel
26 * grid.
27 *
28 */
29
30
31#ifndef PSHREC_H_
32#define PSHREC_H_
33
34
36#include "pshglob.h"
37
38
40
41
42 /*************************************************************************/
43 /*************************************************************************/
44 /***** *****/
45 /***** GLYPH HINTS RECORDER INTERNALS *****/
46 /***** *****/
47 /*************************************************************************/
48 /*************************************************************************/
49
50 /* handle to hint record */
51 typedef struct PS_HintRec_* PS_Hint;
52
53 /* hint types */
54 typedef enum PS_Hint_Type_
55 {
58
60
61
62 /* hint flags */
63#define PS_HINT_FLAG_GHOST 1U
64#define PS_HINT_FLAG_BOTTOM 2U
65
66
67 /* hint descriptor */
68 typedef struct PS_HintRec_
69 {
73
75
76
77#define ps_hint_is_active( x ) ( (x)->flags & PS_HINT_FLAG_ACTIVE )
78#define ps_hint_is_ghost( x ) ( (x)->flags & PS_HINT_FLAG_GHOST )
79#define ps_hint_is_bottom( x ) ( (x)->flags & PS_HINT_FLAG_BOTTOM )
80
81
82 /* hints table descriptor */
83 typedef struct PS_Hint_TableRec_
84 {
88
90
91
92 /* hint and counter mask descriptor */
93 typedef struct PS_MaskRec_
94 {
99
101
102
103 /* masks and counters table descriptor */
104 typedef struct PS_Mask_TableRec_
105 {
109
111
112
113 /* dimension-specific hints descriptor */
114 typedef struct PS_DimensionRec_
115 {
119
121
122
123 /* glyph hints descriptor */
124 /* dimension 0 => X coordinates + vertical hints/stems */
125 /* dimension 1 => Y coordinates + horizontal hints/stems */
126 typedef struct PS_HintsRec_
127 {
130 FT_UInt32 magic;
133
135
136 /* */
137
138 /* initialize hints recorder */
139 FT_LOCAL( void )
142
143 /* finalize hints recorder */
144 FT_LOCAL( void )
146
147 /* initialize Type1 hints recorder interface */
148 FT_LOCAL( void )
150
151 /* initialize Type2 hints recorder interface */
152 FT_LOCAL( void )
154
155
156#ifdef DEBUG_HINTER
157 extern PS_Hints ps_debug_hints;
158 extern int ps_debug_no_horz_hints;
159 extern int ps_debug_no_vert_hints;
160#endif
161
162 /* */
163
164
166
167
168#endif /* PSHREC_H_ */
169
170
171/* END */
#define FT_LOCAL(x)
#define FT_END_HEADER
Definition: ftheader.h:57
#define FT_BEGIN_HEADER
Definition: ftheader.h:37
typedefFT_BEGIN_HEADER struct FT_MemoryRec_ * FT_Memory
Definition: ftsystem.h:64
unsigned char FT_Byte
Definition: fttypes.h:154
int FT_Error
Definition: fttypes.h:299
unsigned int FT_UInt
Definition: fttypes.h:231
signed int FT_Int
Definition: fttypes.h:220
static char memory[1024 *256]
Definition: process.c:122
struct PS_DimensionRec_ * PS_Dimension
enum PS_Hint_Type_ PS_Hint_Type
struct PS_DimensionRec_ PS_DimensionRec
t1_hints_funcs_init(T1_Hints_FuncsRec *funcs)
Definition: pshrec.c:1140
ps_hints_init(PS_Hints hints, FT_Memory memory)
Definition: pshrec.c:817
PS_Hint_Type_
Definition: pshrec.h:55
@ PS_HINT_TYPE_1
Definition: pshrec.h:56
@ PS_HINT_TYPE_2
Definition: pshrec.h:57
struct PS_Hint_TableRec_ PS_Hint_TableRec
ps_hints_done(PS_Hints hints)
Definition: pshrec.c:803
struct PS_Hint_TableRec_ * PS_Hint_Table
t2_hints_funcs_init(T2_Hints_FuncsRec *funcs)
Definition: pshrec.c:1206
struct PS_Mask_TableRec_ * PS_Mask_Table
struct PS_HintsRec_ * PS_Hints
struct PS_MaskRec_ * PS_Mask
typedefFT_BEGIN_HEADER struct PS_HintRec_ * PS_Hint
Definition: pshrec.h:51
struct PS_MaskRec_ PS_MaskRec
struct PS_Mask_TableRec_ PS_Mask_TableRec
struct PS_HintRec_ PS_HintRec
struct PS_HintsRec_ PS_HintsRec
static struct __wine_debug_functions funcs
Definition: debug.c:48
namespace GUID const ADDRINFOEXW * hints
Definition: sock.c:80
PS_Mask_TableRec masks
Definition: pshrec.h:117
PS_Mask_TableRec counters
Definition: pshrec.h:118
PS_Hint_TableRec hints
Definition: pshrec.h:116
FT_Int len
Definition: pshrec.h:71
FT_UInt flags
Definition: pshrec.h:72
FT_Int pos
Definition: pshrec.h:70
PS_Hint hints
Definition: pshrec.h:87
FT_UInt num_hints
Definition: pshrec.h:85
FT_UInt max_hints
Definition: pshrec.h:86
FT_Memory memory
Definition: pshrec.h:128
FT_Error error
Definition: pshrec.h:129
PS_Hint_Type hint_type
Definition: pshrec.h:131
FT_UInt32 magic
Definition: pshrec.h:130
PS_DimensionRec dimension[2]
Definition: pshrec.h:132
FT_UInt end_point
Definition: pshrec.h:98
FT_UInt max_bits
Definition: pshrec.h:96
FT_UInt num_bits
Definition: pshrec.h:95
FT_Byte * bytes
Definition: pshrec.h:97
PS_Mask masks
Definition: pshrec.h:108
FT_UInt num_masks
Definition: pshrec.h:106
FT_UInt max_masks
Definition: pshrec.h:107