46 {
57
59
60#ifdef FT_CONFIG_OPTION_INCREMENTAL
62 face->root.internal->incremental_interface;
63#endif
64
65
66 FT_TRACE1((
"cid_load_glyph: glyph index %d\n", glyph_index ));
67
68#ifdef FT_CONFIG_OPTION_INCREMENTAL
69
70
71
72 if ( inc )
73 {
75
76
78 glyph_index, &glyph_data );
81
84
85 if ( glyph_data.
length != 0 )
86 {
91 glyph_length );
92 }
93
95
98 }
99
100 else
101
102#endif
103
104
105
106 {
109
110
112 glyph_index * entry_len ) ||
115
122
125 off1 > off2 )
126 {
127 FT_TRACE0((
"cid_load_glyph: invalid glyph stream offsets\n" ));
130 }
131
132 glyph_length = off2 - off1;
133 if ( glyph_length == 0 )
135 if (
FT_ALLOC( charstring, glyph_length ) )
138 charstring, glyph_length ) )
140 }
141
142
143 {
147
148
149
154
155
156 dict =
cid->font_dicts + fd_select;
157
161
162
163
164
166 if ( cs_offset > glyph_length )
167 {
168 FT_TRACE0((
"cid_load_glyph: invalid glyph stream offsets\n" ));
171 }
172
173
175 psaux->t1_decrypt( charstring, glyph_length, 4330 );
176
177
178#ifdef T1_CONFIG_OPTION_OLD_ENGINE
181 decoder->builder.metrics_only )
182 error = psaux->t1_decoder_funcs->parse_charstrings_old(
184 charstring + cs_offset,
185 glyph_length - cs_offset );
186#else
187 if (
decoder->builder.metrics_only )
188 error = psaux->t1_decoder_funcs->parse_metrics(
190 charstring + cs_offset,
191 glyph_length - cs_offset );
192#endif
193 else
194 {
197
198
199 psaux->ps_decoder_init( &psdecoder,
decoder,
TRUE );
200
203 &subfont );
205
206 error = psaux->t1_decoder_funcs->parse_charstrings(
207 &psdecoder,
208 charstring + cs_offset,
209 glyph_length - cs_offset );
210
211
212
214 {
215
216
217
219
220 force_scaling =
TRUE;
221
222 error = psaux->t1_decoder_funcs->parse_charstrings(
223 &psdecoder,
224 charstring + cs_offset,
225 glyph_length - cs_offset );
226 }
227 }
228 }
229
230#ifdef FT_CONFIG_OPTION_INCREMENTAL
231
232
234 {
236
237
242
245
249 }
250
251#endif
252
255
257
259 }
cid_get_offset(FT_Byte **start, FT_Byte offsize)
struct CID_GlyphSlotRec_ * CID_GlyphSlot
#define FT_TRACE0(varformat)
#define FT_TRACE1(varformat)
#define FT_HINTING_FREETYPE
#define FT_ALLOC(ptr, size)
#define FT_FACE_DRIVER(x)
#define FT_FRAME_ENTER(size)
#define FT_STREAM_SEEK(position)
#define FT_STREAM_READ_AT(position, buffer, count)
typedefFT_BEGIN_HEADER struct FT_MemoryRec_ * FT_Memory
FT_BEGIN_HEADER typedef unsigned char FT_Bool
GLenum GLuint GLint GLenum face
GLsizei GLenum const GLvoid GLuint GLsizei GLfloat * metrics
static char memory[1024 *256]
FT_BEGIN_HEADER struct PS_DriverRec_ * PS_Driver
PS_PrivateRec private_dict
FT_Incremental_FreeGlyphDataFunc free_glyph_data
FT_Incremental_GetGlyphDataFunc get_glyph_data
FT_Incremental_GetGlyphMetricsFunc get_glyph_metrics
const FT_Incremental_FuncsRec * funcs
CFF_SubFont current_subfont
struct CID_FaceRec_ * CID_Face