345 {
350
352 {
353#undef FT_STRUCTURE
354#define FT_STRUCTURE SFNT_HeaderRec
355
362 };
363
364
366
367
368
370
374
375
376#if 0
377 if (
sfnt.search_range != 1 << (
sfnt.entry_selector + 4 ) ||
378 sfnt.search_range +
sfnt.range_shift !=
sfnt.num_tables << 4 )
379 return FT_THROW( Unknown_File_Format );
380#endif
381
382
383
384 FT_TRACE2((
"-- Number of tables: %10u\n",
sfnt.num_tables ));
385 FT_TRACE2((
"-- Format version: 0x%08lx\n",
sfnt.format_tag ));
386
388 {
389
392 {
394 " invalid table directory for TrueType\n" ));
396 }
397 }
398 else
399 {
400 valid_entries =
sfnt.num_tables;
401 if ( !valid_entries )
402 {
403 FT_TRACE2((
"tt_face_load_font_dir: no valid tables found\n" ));
406 }
407 }
408
409 face->num_tables = valid_entries;
411
414
418
420 " tag offset length checksum\n"
421 " ----------------------------------\n" ));
422
423 valid_entries = 0;
424 for ( nn = 0; nn <
sfnt.num_tables; nn++ )
425 {
429
430
435
436
437
439 continue;
441 {
444 {
445#ifdef FT_DEBUG_LEVEL_TRACE
447#endif
448
449
450
452
453 FT_TRACE2((
" %c%c%c%c %08lx %08lx %08lx"
454 " (sanitized; original length %08lx)",
462 old_length ));
463 }
464 else
465 continue;
466 }
467#ifdef FT_DEBUG_LEVEL_TRACE
468 else
469 FT_TRACE2((
" %c%c%c%c %08lx %08lx %08lx",
477#endif
478
479
480 duplicate = 0;
481 for (
i = 0;
i < valid_entries;
i++ )
482 {
484 {
485 duplicate = 1;
486 break;
487 }
488 }
489 if ( duplicate )
490 {
491 FT_TRACE2((
" (duplicate, ignored)\n" ));
492 continue;
493 }
494 else
495 {
497
498
499 face->dir_tables[valid_entries++] =
entry;
500 }
501 }
502
503
504 face->num_tables = valid_entries;
505
507
508 FT_TRACE2((
"table directory loaded\n\n" ));
509
512 }
#define FT_TRACE2(varformat)
#define FT_QNEW_ARRAY(ptr, count)
#define FT_FRAME_ENTER(size)
#define FT_READ_ULONG(var)
#define FT_STREAM_READ_FIELDS(fields, object)
#define FT_FRAME_START(size)
#define FT_FRAME_USHORT(f)
FT_BEGIN_HEADER typedef unsigned char FT_Bool
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
static FT_Error check_table_dir(SFNT_Header sfnt, FT_Stream stream, FT_UShort *valid)