freetype-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[ft-devel] Problem with Type 42 incremental downloading font


From: Taek Kwan(TK) Lee
Subject: [ft-devel] Problem with Type 42 incremental downloading font
Date: Thu, 10 Nov 2005 09:56:08 -0500

In case of Type 42 Incremental downloading, 'glyf' and 'loca' table do
not present in the font data by Adobe specification. However, by
setting parameter and providing incremental interface, Freetype should
be able to print it.

T42_Face_Init( )/t42objs.c calls FT_New_Memory_Face( ) to load font
Type42 font data , and then FT_New_Memory_Face( ) calls FT_Open_Face(
). Because FT_New_Memory_Face( ) does not pass the parameter
information(specifically incremental interface information) to
FT_Open_Face( ), TT_Load_Glyph( ) / ttgload.c tried to load 'glyf'
table and cause error.

  FT_EXPORT_DEF( FT_Error )
  FT_New_Memory_Face( FT_Library      library,
                      const FT_Byte*  file_base,
                      FT_Long         file_size,
                      FT_Long         face_index,
                      FT_Face        *aface,
)
  {
    FT_Open_Args  args;


    /* test for valid `library' and `face' delayed to FT_Open_Face() */
    if ( !file_base )
      return FT_Err_Invalid_Argument;

    args.flags       = FT_OPEN_MEMORY;
    args.memory_base = file_base;
    args.memory_size = file_size;

    return FT_Open_Face( library, &args, face_index, aface );
  }




reply via email to

[Prev in Thread] Current Thread [Next in Thread]