47 {
58
60
61#ifdef FT_CONFIG_OPTION_INCREMENTAL
63 face->root.internal->incremental_interface;
64#endif
65
66
67 FT_TRACE1((
"cid_load_glyph: glyph index %d\n", glyph_index ));
68
69#ifdef FT_CONFIG_OPTION_INCREMENTAL
70
71
72
73 if ( inc )
74 {
76
77
79 glyph_index, &glyph_data );
82
85
86 if ( glyph_data.
length != 0 )
87 {
92 glyph_length );
93 }
94
96
99 }
100
101 else
102
103#endif
104
105
106
107 {
110
111
113 glyph_index * entry_len ) ||
116
123
126 off1 > off2 )
127 {
128 FT_TRACE0((
"cid_load_glyph: invalid glyph stream offsets\n" ));
131 }
132
133 glyph_length = off2 - off1;
134 if ( glyph_length == 0 )
136 if (
FT_ALLOC( charstring, glyph_length ) )
139 charstring, glyph_length ) )
141 }
142
143
144 {
148
149
150
155
156
157 dict =
cid->font_dicts + fd_select;
158
162
163
164
165
167 if ( cs_offset > glyph_length )
168 {
169 FT_TRACE0((
"cid_load_glyph: invalid glyph stream offsets\n" ));
172 }
173
174
176 psaux->t1_decrypt( charstring, glyph_length, 4330 );
177
178
179#ifdef T1_CONFIG_OPTION_OLD_ENGINE
182 decoder->builder.metrics_only )
183 error = psaux->t1_decoder_funcs->parse_charstrings_old(
185 charstring + cs_offset,
186 glyph_length - cs_offset );
187#else
188 if (
decoder->builder.metrics_only )
189 error = psaux->t1_decoder_funcs->parse_metrics(
191 charstring + cs_offset,
192 glyph_length - cs_offset );
193#endif
194 else
195 {
198
199
200 psaux->ps_decoder_init( &psdecoder,
decoder,
TRUE );
201
204 &subfont );
206
207 error = psaux->t1_decoder_funcs->parse_charstrings(
208 &psdecoder,
209 charstring + cs_offset,
210 glyph_length - cs_offset );
211
212
213
215 {
216
217
218
220
221 force_scaling =
TRUE;
222
223 error = psaux->t1_decoder_funcs->parse_charstrings(
224 &psdecoder,
225 charstring + cs_offset,
226 glyph_length - cs_offset );
227 }
228 }
229 }
230
231#ifdef FT_CONFIG_OPTION_INCREMENTAL
232
233
235 {
237
238
243
246
250 }
251
252#endif
253
256
258
260 }
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