* src/cache/ftccache.c (ftc_node_hash_unlink, ftc_node_hash_link)

[FTC_CACHE_USE_LINEAR_HASHING]: Fix returned error code.
Fix debugging messages.

* src/type42/t42error.h: New file.
* src/type42/t42drivr.c, src/type42/t42objs.c,
src/type42/t42parse.c: Use t42 error codes.
* src/type42/rules.mk: Updated.

* src/base/ftnames.c: Include FT_INTERNAL_STREAM_H.

Formatting, adding copyright messages.
This commit is contained in:
Werner Lemberg 2002-06-08 06:47:18 +00:00
parent 5a2f39e8ed
commit 8c90c22dbe
15 changed files with 411 additions and 151 deletions

114
ChangeLog
View File

@ -1,27 +1,113 @@
2002-06-08 Werner Lemberg <wl@gnu.org>
* src/cache/ftccache.c (ftc_node_hash_unlink, ftc_node_hash_link)
[FTC_CACHE_USE_LINEAR_HASHING]: Fix returned error code.
Fix debugging messages.
* src/type42/t42error.h: New file.
* src/type42/t42drivr.c, src/type42/t42objs.c,
src/type42/t42parse.c: Use t42 error codes.
* src/type42/rules.mk: Updated.
* src/base/ftnames.c: Include FT_INTERNAL_STREAM_H.
2002-06-08 David Turner <david@freetype.org>
* src/cache/ftccmap.c: GEN_CACHE_FAMILY_COMPARE,
GEN_CACHE_NODE_COMPARE, GEN_CACHE_LOOKUP) [FTC_CACHE_USE_INLINE]:
New macros.
(ftc_cmap_cache_lookup) [!FTC_CACHE_USE_INLINE]: Typedef to
ftc_cache_lookup.
(FTC_CMapCache_Lookup): Updated.
2002-06-07 Graham Asher <graham.asher@btinternet.com> 2002-06-07 Graham Asher <graham.asher@btinternet.com>
* include/freetype/cache/ftccache.h, src/cache/ftccache.c, Adding various experimental optimizations to the cache manager.
src/cache/ftccache.i, src/cache/ftcsbits.c: adding various
experimental optimisations to the cache manager
* src/type42/t42parse.c: removing duplicate function * include/freetype/cache/ftccache.h (FTC_CACHE_USE_INLINE,
FTC_CACHE_USE_LINEAR_HASHING): New options.
(FTC_CacheRec) [FTC_CACHE_USE_LINEAR_HASHING]: New elements `p',
`mask', and `slack'.
* src/base/ftobjs.c (FT_Render_Glyph_Internal): changed definition * src/cache/ftccache.c (FTC_HASH_MAX_LOAD, FTC_HASH_MIN_LOAD,
from FT_EXPORT_DEF to FT_BASE_DEF FTC_HASH_SUB_LOAD) [FTC_CACHE_USE_LINEAR_HASHING,
FTC_HASH_INITIAL_SIZE]: New macros.
(ftc_node_mru_link, ftc_node_mru_up): Optimized.
(ftc_node_hash_unlink, ftc_node_hash_link)
[FTC_CACHE_USE_LINEAR_HASHING]: New variants.
(FTC_PRIMES_MIN, FTC_PRIMES_MAX, ftc_primes, ftc_prime_closest,
FTC_CACHE_RESIZE_TEST, ftc_cache_resize)
[!FTC_CACHE_USE_LINEAR_HASHING]: Define it conditionally.
(ftc_cache_init, ftc_cache_clear) [FTC_CACHE_USE_LINEAR_HASHING]:
Updated.
(ftc_cache_lookup) [FTC_CACHE_USE_LINEAR_HASHING]: Implement it.
2002-06-07 David Turner <david@freetype.org> * src/cache/ftccache.i: New file.
* src/type42/t42drivr.c, src/type42/t42drivr.h, src/type42/t42parse.c, * src/cache/ftcsbits.c (GEN_CACHE_FAMILY_COMPARE,
src/type42/t42parse.h, src/type42/t42objs.h, src/type42/t42objs.c, GEN_CACHE_NODE_COMPARE, GEN_CACHE_LOOKUP) [FTC_CACHE_USE_INLINE]:
src/type42/type42.c: New macros.
(ftc_sbit_cache_lookup) [!FTC_CACHE_USE_INLINE]: Typedef to
ftc_cache_lookup.
(FTC_SBitCache_Lookup): Updated.
updated the Type42 driver by splitting it into several files since * src/type42/t42parse.c: Removing duplicate function.
it makes the code easier to read and maintain. Also fixed the bug
that prevented the correct display of fonts with "ftview" * src/base/ftobjs.c (FT_Render_Glyph_Internal): Changed definition
from FT_EXPORT_DEF to FT_BASE_DEF.
2002-06-07 David Turner <david@freetype.org>
Fixed the bug that prevented the correct display of fonts with
"ftview".
* src/type42/t42drivr.c: Split into...
* src/type42/t42drivr.h, src/type42/t42parse.c,
src/type42/t42parse.h, src/type42/t42objs.h, src/type42/t42objs.c,
src/type42/type42.c: New files.
(t42_get_glyph_name, t42_get_ps_name, t42_get_name_index): Use
`face->type1'.
(Get_Interface): Renamed to...
(T42_Get_Interface): This.
Updated.
(T42_Open_Face, T42_Face_Done): Updated.
(T42_Face_Init): Add new cmap support.
Updated.
(T42_Driver_Init, T42_Driver_Done, T42_Size_Init, T42_Size_Done,
T42_GlyphSlot_Init, T42_GlyphSlot_Done): Updated.
(Get_Char_Index, Get_Next_Char): Renamed to...
(T42_CMap_CharIndex, T42_CMap_CharNext): This.
Updated.
(T42_Char_Size, T42_Pixel_Size): Renamed to...
(T42_Size_SetChars, T42_Size_SetPixels): This.
(T42_Load_Glyph): Renamed to...
(T42_GlyphSlot_Load): This.
(t42_init_loader, t42_done_loader): Renamed to...
(t42_loader_init, t42_loader_done): This.
(T42_New_Parser, T42_Finalize_Parser): Renamed to...
(t42_parser_init, t42_parser_done): This.
(parse_dict): Renamed to...
(t42_parse_dict): This.
(is_alpha, is_space, hexval): Renamed to...
(t42_is_alpha, t42_is_space, t42_hexval): This.
(parse_font_name, parse_font_bbox, parse_font_matrix,
parse_encoding, parse_sfnts, parse_charstrings, parse_dict):
Renamed to...
(t42_parse_font_name, t42_parse_font_bbox, t42_parse_font_matrix,
t42_parse_encoding, t42_parse_sfnts, t42_parse_charstrings,
t42_parse_dict): This.
Updated.
(t42_keywords): Updated.
* src/type42/Jamfile, src/type42/descrip.mms: Updated.
2002-06-03 Werner Lemberg <wl@gnu.org> 2002-06-03 Werner Lemberg <wl@gnu.org>
Add 8bpp support. Add 8bpp support to BDF driver.
* src/bdf/bdflib.c (_bdf_parse_start): Handle 8bpp. * src/bdf/bdflib.c (_bdf_parse_start): Handle 8bpp.
* src/bdf/bdfdrivr.c (BDF_Glyph_Load): Ditto. * src/bdf/bdfdrivr.c (BDF_Glyph_Load): Ditto.

View File

@ -4,7 +4,7 @@
/* */ /* */
/* FreeType internal cache interface (specification). */ /* FreeType internal cache interface (specification). */
/* */ /* */
/* Copyright 2000-2001 by */ /* Copyright 2000-2001, 2002 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */ /* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */ /* */
/* This file is part of the FreeType project, and may only be used, */ /* This file is part of the FreeType project, and may only be used, */
@ -26,6 +26,7 @@
/* define to use linear hash table */ /* define to use linear hash table */
#define FTC_CACHE_USE_LINEAR_HASHING #define FTC_CACHE_USE_LINEAR_HASHING
FT_BEGIN_HEADER FT_BEGIN_HEADER
/* handle to cache object */ /* handle to cache object */

View File

@ -22,6 +22,7 @@
#include <ft2build.h> #include <ft2build.h>
#include FT_SFNT_NAMES_H #include FT_SFNT_NAMES_H
#include FT_INTERNAL_TRUETYPE_TYPES_H #include FT_INTERNAL_TRUETYPE_TYPES_H
#include FT_INTERNAL_STREAM_H
#ifdef TT_CONFIG_OPTION_SFNT_NAMES #ifdef TT_CONFIG_OPTION_SFNT_NAMES

76
src/cache/ftccache.c vendored
View File

@ -26,12 +26,12 @@
#ifdef FTC_CACHE_USE_LINEAR_HASHING #ifdef FTC_CACHE_USE_LINEAR_HASHING
#define FTC_HASH_MAX_LOAD 2 #define FTC_HASH_MAX_LOAD 2
#define FTC_HASH_MIN_LOAD 1 #define FTC_HASH_MIN_LOAD 1
#define FTC_HASH_SUB_LOAD (FTC_HASH_MAX_LOAD-FTC_HASH_MIN_LOAD) #define FTC_HASH_SUB_LOAD ( FTC_HASH_MAX_LOAD - FTC_HASH_MIN_LOAD )
/* this one _must_ be a power of 2 !! */ /* this one _must_ be a power of 2! */
#define FTC_HASH_INITIAL_SIZE 8 #define FTC_HASH_INITIAL_SIZE 8
#endif /* FTC_CACHE_USE_LINEAR_HASHING */ #endif /* FTC_CACHE_USE_LINEAR_HASHING */
@ -72,6 +72,7 @@
{ {
FTC_Node last = first->mru_prev; FTC_Node last = first->mru_prev;
FT_ASSERT( last->mru_next == first ); FT_ASSERT( last->mru_next == first );
node->mru_prev = last; node->mru_prev = last;
@ -102,6 +103,7 @@
FTC_Node prev = node->mru_prev; FTC_Node prev = node->mru_prev;
FTC_Node next = node->mru_next; FTC_Node next = node->mru_next;
FT_ASSERT( first != NULL && manager->num_nodes > 0 ); FT_ASSERT( first != NULL && manager->num_nodes > 0 );
FT_ASSERT( next->mru_prev == node ); FT_ASSERT( next->mru_prev == node );
FT_ASSERT( prev->mru_next == node ); FT_ASSERT( prev->mru_next == node );
@ -111,6 +113,7 @@
if ( node == first ) if ( node == first )
{ {
/* this is the last node in the list; update its head pointer */
if ( node == next ) if ( node == next )
manager->nodes_list = NULL; manager->nodes_list = NULL;
else else
@ -137,6 +140,7 @@
FTC_Node next = node->mru_next; FTC_Node next = node->mru_next;
FTC_Node last; FTC_Node last;
prev->mru_next = next; prev->mru_next = next;
next->mru_prev = prev; next->mru_prev = prev;
@ -162,9 +166,10 @@
FTC_Node *pnode; FTC_Node *pnode;
FT_UInt index, num_buckets; FT_UInt index, num_buckets;
index = (FT_UInt)( node->hash & cache->mask ); index = (FT_UInt)( node->hash & cache->mask );
if ( index < cache->p ) if ( index < cache->p )
index = (FT_UInt)( node->hash & (2*cache->mask+1) ); index = (FT_UInt)( node->hash & ( 2 * cache->mask + 1 ) );
pnode = cache->buckets + index; pnode = cache->buckets + index;
@ -172,8 +177,8 @@
{ {
if ( *pnode == NULL ) if ( *pnode == NULL )
{ {
FT_ERROR(( "FreeType.cache.hash_unlink: unknown node!\n" )); FT_ERROR(( "ftc_node_hash_unlink: unknown node!\n" ));
return 0; return FT_Err_Ok;
} }
if ( *pnode == node ) if ( *pnode == node )
@ -186,15 +191,16 @@
pnode = &(*pnode)->link; pnode = &(*pnode)->link;
} }
num_buckets = ( cache->p + cache->mask + 1) ; num_buckets = ( cache->p + cache->mask + 1 );
if ( ++ cache->slack > (FT_Long)num_buckets*FTC_HASH_SUB_LOAD ) if ( ++cache->slack > (FT_Long)num_buckets * FTC_HASH_SUB_LOAD )
{ {
FT_UInt p = cache->p; FT_UInt p = cache->p;
FT_UInt mask = cache->mask; FT_UInt mask = cache->mask;
FT_UInt old_index = p + mask; FT_UInt old_index = p + mask;
FTC_Node* pold; FTC_Node* pold;
FT_ASSERT( old_index >= FTC_HASH_INITIAL_SIZE ); FT_ASSERT( old_index >= FTC_HASH_INITIAL_SIZE );
if ( p == 0 ) if ( p == 0 )
@ -205,9 +211,9 @@
cache->mask >>= 1; cache->mask >>= 1;
p = cache->mask; p = cache->mask;
if ( FT_RENEW_ARRAY( cache->buckets, (mask+1)*2, (mask) ) ) if ( FT_RENEW_ARRAY( cache->buckets, ( mask + 1 ) * 2, mask ) )
{ {
FT_ERROR(( "FreeType.cache.hash_unlink: couldn't shunk buckets !\n" )); FT_ERROR(( "ftc_node_hash_unlink: couldn't shunk buckets!\n" ));
goto Exit; goto Exit;
} }
} }
@ -239,6 +245,7 @@
{ {
FTC_Node *pnode = cache->buckets + ( node->hash % cache->size ); FTC_Node *pnode = cache->buckets + ( node->hash % cache->size );
for (;;) for (;;)
{ {
if ( *pnode == NULL ) if ( *pnode == NULL )
@ -274,9 +281,10 @@
FT_UInt index; FT_UInt index;
FT_Error error = 0; FT_Error error = 0;
index = (FT_UInt)( node->hash & cache->mask ); index = (FT_UInt)( node->hash & cache->mask );
if ( index < cache->p ) if ( index < cache->p )
index = (FT_UInt)( node->hash & (2*cache->mask+1) ); index = (FT_UInt)( node->hash & (2 * cache->mask + 1 ) );
pnode = cache->buckets + index; pnode = cache->buckets + index;
@ -289,16 +297,18 @@
FT_UInt mask = cache->mask; FT_UInt mask = cache->mask;
FTC_Node new_list; FTC_Node new_list;
/* split a single bucket */ /* split a single bucket */
new_list = NULL; new_list = NULL;
pnode = cache->buckets + p; pnode = cache->buckets + p;
for (;;) for (;;)
{ {
node = *pnode; node = *pnode;
if ( node == NULL ) if ( node == NULL )
break; break;
if ( node->hash & (mask+1) ) if ( node->hash & ( mask + 1 ) )
{ {
*pnode = node->link; *pnode = node->link;
node->link = new_list; node->link = new_list;
@ -308,7 +318,7 @@
pnode = &node->link; pnode = &node->link;
} }
cache->buckets[ p + mask + 1 ] = new_list; cache->buckets[p + mask + 1] = new_list;
cache->slack += FTC_HASH_MAX_LOAD; cache->slack += FTC_HASH_MAX_LOAD;
@ -317,13 +327,14 @@
FT_Memory memory = cache->memory; FT_Memory memory = cache->memory;
if ( FT_RENEW_ARRAY( cache->buckets, (mask+1)*2, (mask+1)*4 ) ) if ( FT_RENEW_ARRAY( cache->buckets,
( mask + 1 ) * 2, ( mask + 1 ) * 4 ) )
{ {
FT_ERROR(( "FreeType.cache.hash_unlink: couldn't expand buckets !\n" )); FT_ERROR(( "ftc_node_hash_link: couldn't expand buckets!\n" ));
goto Exit; goto Exit;
} }
cache->mask = 2*mask + 1; cache->mask = 2 * mask + 1;
cache->p = 0; cache->p = 0;
} }
else else
@ -343,6 +354,7 @@
{ {
FTC_Node *pnode = cache->buckets + ( node->hash % cache->size ); FTC_Node *pnode = cache->buckets + ( node->hash % cache->size );
node->link = *pnode; node->link = *pnode;
*pnode = node; *pnode = node;
@ -466,6 +478,7 @@
#ifdef FTC_CACHE_USE_LINEAR_HASHING #ifdef FTC_CACHE_USE_LINEAR_HASHING
/* nothing */
#else /* !FTC_CACHE_USE_LINEAR_HASHING */ #else /* !FTC_CACHE_USE_LINEAR_HASHING */
@ -583,6 +596,7 @@
#endif /* !FTC_CACHE_USE_LINEAR_HASHING */ #endif /* !FTC_CACHE_USE_LINEAR_HASHING */
FT_EXPORT_DEF( FT_Error ) FT_EXPORT_DEF( FT_Error )
ftc_cache_init( FTC_Cache cache ) ftc_cache_init( FTC_Cache cache )
{ {
@ -594,13 +608,14 @@
#ifdef FTC_CACHE_USE_LINEAR_HASHING #ifdef FTC_CACHE_USE_LINEAR_HASHING
cache->p = 0; cache->p = 0;
cache->mask = FTC_HASH_INITIAL_SIZE-1; cache->mask = FTC_HASH_INITIAL_SIZE - 1;
cache->slack = FTC_HASH_INITIAL_SIZE*FTC_HASH_MAX_LOAD; cache->slack = FTC_HASH_INITIAL_SIZE * FTC_HASH_MAX_LOAD;
if ( FT_NEW_ARRAY( cache->buckets, FTC_HASH_INITIAL_SIZE*2 ) ) if ( FT_NEW_ARRAY( cache->buckets, FTC_HASH_INITIAL_SIZE * 2 ) )
goto Exit; goto Exit;
#else /* !FTC_CACHE_USE_LINEAR_HASHING */ #else /* !FTC_CACHE_USE_LINEAR_HASHING */
cache->nodes = 0; cache->nodes = 0;
cache->size = FTC_PRIMES_MIN; cache->size = FTC_PRIMES_MIN;
@ -728,7 +743,7 @@
FTC_Query query, FTC_Query query,
FTC_Node *anode ) FTC_Node *anode )
{ {
FT_Error error = 0; FT_Error error = FT_Err_Ok;
FT_LruNode lru; FT_LruNode lru;
@ -740,11 +755,12 @@
query->hash = 0; query->hash = 0;
query->family = NULL; query->family = NULL;
/* XXX: we break encapsulation for the sake of speed !! */
#if 1 #if 1
/* XXX: we break encapsulation for the sake of speed! */
{ {
/* first of all, find the relevant family */ /* first of all, find the relevant family */
FT_LruList list = cache->families; FT_LruList list = cache->families;
FT_LruNode fam, *pfam; FT_LruNode fam, *pfam;
FT_LruNode_CompareFunc compare = list->clazz->node_compare; FT_LruNode_CompareFunc compare = list->clazz->node_compare;
@ -780,27 +796,35 @@
lru = fam; lru = fam;
Skip: Skip:
;
} }
#else #else
error = FT_LruList_Lookup( cache->families, query, &lru ); error = FT_LruList_Lookup( cache->families, query, &lru );
if ( !error ) if ( !error )
#endif #endif
{ {
FTC_Family family = (FTC_Family) lru; FTC_Family family = (FTC_Family) lru;
FT_UFast hash = query->hash; FT_UFast hash = query->hash;
FTC_Node* bucket; FTC_Node* bucket;
#ifdef FTC_CACHE_USE_LINEAR_HASHING #ifdef FTC_CACHE_USE_LINEAR_HASHING
FT_UInt index; FT_UInt index;
index = hash & cache->mask; index = hash & cache->mask;
if ( index < cache->p ) if ( index < cache->p )
index = hash & (cache->mask*2+1); index = hash & ( cache->mask * 2 + 1 );
bucket = cache->buckets + index; bucket = cache->buckets + index;
#else #else
bucket = cache->buckets + (hash % cache->size); bucket = cache->buckets + (hash % cache->size);
#endif #endif

41
src/cache/ftccache.i vendored
View File

@ -1,11 +1,30 @@
/***************************************************************************/
/* */
/* ftccache.i */
/* */
/* FreeType template for generic cache. */
/* */
/* Copyright 2002 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */
/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
/* this file you indicate that you have read the license and */
/* understand and accept it fully. */
/* */
/***************************************************************************/
#ifndef GEN_CACHE_FAMILY_COMPARE #ifndef GEN_CACHE_FAMILY_COMPARE
#error "GEN_CACHE_FAMILY_COMPARE not defined in template instanciation" #error "GEN_CACHE_FAMILY_COMPARE not defined in template instantiation"
#endif #endif
#ifndef GEN_CACHE_NODE_COMPARE #ifndef GEN_CACHE_NODE_COMPARE
#error "GEN_CACHE_NODE_COMPARE not defined in template instanciation" #error "GEN_CACHE_NODE_COMPARE not defined in template instantiation"
#endif #endif
static FT_Error static FT_Error
GEN_CACHE_LOOKUP( FTC_Cache cache, GEN_CACHE_LOOKUP( FTC_Cache cache,
FTC_Query query, FTC_Query query,
@ -17,11 +36,12 @@
query->hash = 0; query->hash = 0;
query->family = NULL; query->family = NULL;
/* XXX: we break encapsulation for the sake of speed !! */ /* XXX: we break encapsulation for the sake of speed! */
{ {
/* first of all, find the relevant family */ /* first of all, find the relevant family */
FT_LruList list = cache->families; FT_LruList list = cache->families;
FT_LruNode fam, *pfam; FT_LruNode fam, *pfam;
pfam = &list->nodes; pfam = &list->nodes;
for (;;) for (;;)
@ -51,20 +71,21 @@
{ {
FTC_Family family = (FTC_Family) lru; FTC_Family family = (FTC_Family) lru;
FT_UFast hash = query->hash; FT_UFast hash = query->hash;
FTC_Node node, *pnode, *bucket; FTC_Node node, *pnode, *bucket;
#ifdef FTC_CACHE_USE_LINEAR_HASHING #ifdef FTC_CACHE_USE_LINEAR_HASHING
FT_UInt index; FT_UInt index;
index = hash & cache->mask; index = hash & cache->mask;
if ( index < cache->p ) if ( index < cache->p )
index = hash & (cache->mask*2+1); index = hash & ( cache->mask * 2 + 1 );
bucket = cache->buckets + index; bucket = cache->buckets + index;
#else #else
bucket = cache->buckets + (hash % cache->size); bucket = cache->buckets + ( hash % cache->size );
#endif #endif
#ifdef FT_DEBUG_LEVEL_ERROR #ifdef FT_DEBUG_LEVEL_ERROR
@ -119,6 +140,7 @@
FTC_Node next = node->mru_next; FTC_Node next = node->mru_next;
FTC_Node last; FTC_Node last;
prev->mru_next = next; prev->mru_next = next;
next->mru_prev = prev; next->mru_prev = prev;
@ -139,3 +161,6 @@
#undef GEN_CACHE_NODE_COMPARE #undef GEN_CACHE_NODE_COMPARE
#undef GEN_CACHE_FAMILY_COMPARE #undef GEN_CACHE_FAMILY_COMPARE
#undef GEN_CACHE_LOOKUP #undef GEN_CACHE_LOOKUP
/* END */

16
src/cache/ftccmap.c vendored
View File

@ -320,21 +320,23 @@
#ifdef FTC_CACHE_USE_INLINE #ifdef FTC_CACHE_USE_INLINE
# define GEN_CACHE_FAMILY_COMPARE(f,q,c) \ #define GEN_CACHE_FAMILY_COMPARE( f, q, c ) \
ftc_cmap_family_compare( (FTC_CMapFamily)(f), (FTC_CMapQuery)(q) ) ftc_cmap_family_compare( (FTC_CMapFamily)(f), (FTC_CMapQuery)(q) )
# define GEN_CACHE_NODE_COMPARE(n,q,c) \ #define GEN_CACHE_NODE_COMPARE( n, q, c ) \
ftc_cmap_node_compare( (FTC_CMapNode)(n), (FTC_CMapQuery)(q) ) ftc_cmap_node_compare( (FTC_CMapNode)(n), (FTC_CMapQuery)(q) )
# define GEN_CACHE_LOOKUP ftc_cmap_cache_lookup #define GEN_CACHE_LOOKUP ftc_cmap_cache_lookup
# include "ftccache.i"
#include "ftccache.i"
#else /* !FTC_CACHE_USE_INLINE */ #else /* !FTC_CACHE_USE_INLINE */
# define ftc_cmap_cache_lookup ftc_cache_lookup #define ftc_cmap_cache_lookup ftc_cache_lookup
#endif /* !FTC_CACHE_USE_INLINE */ #endif /* !FTC_CACHE_USE_INLINE */
/* documentation is in ftccmap.h */ /* documentation is in ftccmap.h */
FT_EXPORT_DEF( FT_UInt ) FT_EXPORT_DEF( FT_UInt )

14
src/cache/ftcsbits.c vendored
View File

@ -464,18 +464,18 @@
#ifdef FTC_CACHE_USE_INLINE #ifdef FTC_CACHE_USE_INLINE
# define GEN_CACHE_FAMILY_COMPARE(f,q,c) \ #define GEN_CACHE_FAMILY_COMPARE( f, q, c ) \
ftc_sbit_family_compare( (FTC_SBitFamily)(f), (FTC_SBitQuery)(q) ) ftc_sbit_family_compare( (FTC_SBitFamily)(f), (FTC_SBitQuery)(q) )
# define GEN_CACHE_NODE_COMPARE(n,q,c) \ #define GEN_CACHE_NODE_COMPARE( n, q, c ) \
ftc_sbit_node_compare( (FTC_SBitNode)(n), (FTC_SBitQuery)(q), c ) ftc_sbit_node_compare( (FTC_SBitNode)(n), (FTC_SBitQuery)(q), c )
# define GEN_CACHE_LOOKUP ftc_sbit_cache_lookup #define GEN_CACHE_LOOKUP ftc_sbit_cache_lookup
# include "ftccache.i" #include "ftccache.i"
#else /* !FTC_CACHE_USE_INLINE */ #else /* !FTC_CACHE_USE_INLINE */
# define ftc_sbit_cache_lookup ftc_cache_lookup #define ftc_sbit_cache_lookup ftc_cache_lookup
#endif /* !FTC_CACHE_USE_INLINE */ #endif /* !FTC_CACHE_USE_INLINE */

View File

@ -32,7 +32,8 @@ T42_DRV_SRC := $(T42_DIR_)t42objs.c \
# Type42 driver headers # Type42 driver headers
# #
T42_DRV_H := $(T42_DRV_SRC:%.c=%.h) T42_DRV_H := $(T42_DRV_SRC:%.c=%.h) \
$(T42_DIR_)t42error.h
# Type42 driver object(s) # Type42 driver object(s)

View File

@ -1,10 +1,30 @@
/***************************************************************************/
/* */
/* t42drivr.c */
/* */
/* High-level Type 42 driver interface (body). */
/* */
/* Copyright 2002 by Roberto Alameda. */
/* */
/* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */
/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
/* this file you indicate that you have read the license and */
/* understand and accept it fully. */
/* */
/***************************************************************************/
#include "t42drivr.h" #include "t42drivr.h"
#include "t42objs.h" #include "t42objs.h"
#include "t42error.h"
#include FT_INTERNAL_DEBUG_H #include FT_INTERNAL_DEBUG_H
#undef FT_COMPONENT #undef FT_COMPONENT
#define FT_COMPONENT trace_t42 #define FT_COMPONENT trace_t42
static FT_Error static FT_Error
t42_get_glyph_name( T42_Face face, t42_get_glyph_name( T42_Face face,
FT_UInt glyph_index, FT_UInt glyph_index,
@ -28,7 +48,7 @@
((FT_Byte*)buffer)[len] = 0; ((FT_Byte*)buffer)[len] = 0;
} }
return FT_Err_Ok; return T42_Err_Ok;
} }
@ -127,3 +147,5 @@
(FT_CharMap_CharNextFunc) T42_CMap_CharNext, (FT_CharMap_CharNextFunc) T42_CMap_CharNext,
}; };
/* END */

View File

@ -4,8 +4,7 @@
/* */ /* */
/* High-level Type 42 driver interface (specification). */ /* High-level Type 42 driver interface (specification). */
/* */ /* */
/* Copyright 1996-2001, 2002 by */ /* Copyright 2002 by Roberto Alameda. */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */ /* */
/* This file is part of the FreeType project, and may only be used, */ /* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */ /* modified, and distributed under the terms of the FreeType project */
@ -16,8 +15,8 @@
/***************************************************************************/ /***************************************************************************/
#ifndef __T42DRIVER_H__ #ifndef __T42DRIVR_H__
#define __T42DRIVER_H__ #define __T42DRIVR_H__
#include <ft2build.h> #include <ft2build.h>
@ -32,7 +31,8 @@ FT_BEGIN_HEADER
FT_END_HEADER FT_END_HEADER
#endif /* __T42DRIVER_H__ */
#endif /* __T42DRIVR_H__ */
/* END */ /* END */

View File

@ -1,9 +1,28 @@
/***************************************************************************/
/* */
/* t42objs.c */
/* */
/* Type 42 objects manager (body). */
/* */
/* Copyright 2002 by Roberto Alameda. */
/* */
/* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */
/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
/* this file you indicate that you have read the license and */
/* understand and accept it fully. */
/* */
/***************************************************************************/
#include "t42objs.h" #include "t42objs.h"
#include "t42parse.h" #include "t42parse.h"
#include "t42error.h"
#include FT_INTERNAL_DEBUG_H #include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_STREAM_H #include FT_INTERNAL_STREAM_H
#include FT_LIST_H #include FT_LIST_H
#undef FT_COMPONENT #undef FT_COMPONENT
#define FT_COMPONENT trace_t42 #define FT_COMPONENT trace_t42
@ -38,7 +57,7 @@
if ( type1->font_type != 42 ) if ( type1->font_type != 42 )
{ {
error = FT_Err_Unknown_File_Format; error = T42_Err_Unknown_File_Format;
goto Exit; goto Exit;
} }
@ -48,18 +67,18 @@
if ( !loader.charstrings.init ) { if ( !loader.charstrings.init ) {
FT_ERROR(( "T42_Open_Face: no charstrings array in face!\n" )); FT_ERROR(( "T42_Open_Face: no charstrings array in face!\n" ));
error = FT_Err_Invalid_File_Format; error = T42_Err_Invalid_File_Format;
} }
loader.charstrings.init = 0; loader.charstrings.init = 0;
type1->charstrings_block = loader.charstrings.block; type1->charstrings_block = loader.charstrings.block;
type1->charstrings = loader.charstrings.elements; type1->charstrings = loader.charstrings.elements;
type1->charstrings_len = loader.charstrings.lengths; type1->charstrings_len = loader.charstrings.lengths;
/* we copy the glyph names `block' and `elements' fields; */ /* we copy the glyph names `block' and `elements' fields; */
/* the `lengths' field must be released later */ /* the `lengths' field must be released later */
type1->glyph_names_block = loader.glyph_names.block; type1->glyph_names_block = loader.glyph_names.block;
type1->glyph_names = (FT_String**)loader.glyph_names.elements; type1->glyph_names = (FT_String**)loader.glyph_names.elements;
loader.glyph_names.block = 0; loader.glyph_names.block = 0;
loader.glyph_names.elements = 0; loader.glyph_names.elements = 0;
@ -165,7 +184,7 @@
if ( face_index != 0 ) if ( face_index != 0 )
{ {
FT_ERROR(( "T42_Face_Init: invalid face index\n" )); FT_ERROR(( "T42_Face_Init: invalid face index\n" ));
error = FT_Err_Invalid_Argument; error = T42_Err_Invalid_Argument;
goto Exit; goto Exit;
} }
@ -176,7 +195,7 @@
root->num_glyphs = face->type1.num_glyphs; root->num_glyphs = face->type1.num_glyphs;
root->num_charmaps = 0; root->num_charmaps = 0;
root->face_index = face_index; root->face_index = face_index;
root->face_flags = FT_FACE_FLAG_SCALABLE; root->face_flags = FT_FACE_FLAG_SCALABLE;
root->face_flags |= FT_FACE_FLAG_HORIZONTAL; root->face_flags |= FT_FACE_FLAG_HORIZONTAL;
@ -242,7 +261,7 @@
root->descender = face->ttf_face->descender; root->descender = face->ttf_face->descender;
root->height = face->ttf_face->height; root->height = face->ttf_face->height;
root->max_advance_width = face->ttf_face->max_advance_width; root->max_advance_width = face->ttf_face->max_advance_width;
root->max_advance_height = face->ttf_face->max_advance_height; root->max_advance_height = face->ttf_face->max_advance_height;
root->underline_position = face->type1.font_info.underline_position; root->underline_position = face->type1.font_info.underline_position;
@ -318,9 +337,9 @@
if ( clazz ) if ( clazz )
FT_CMap_New( clazz, NULL, &charmap, NULL ); FT_CMap_New( clazz, NULL, &charmap, NULL );
/* Select default charmap */ /* Select default charmap */
if (root->num_charmaps) if (root->num_charmaps)
root->charmap = root->charmaps[0]; root->charmap = root->charmaps[0];
} }
} }
@ -328,31 +347,32 @@
/* charmap support -- synthetize unicode charmap if possible */ /* charmap support -- synthetize unicode charmap if possible */
{ {
FT_CharMap charmap = face->charmaprecs; FT_CharMap charmap = face->charmaprecs;
/* synthesize a Unicode charmap if there is support in the `PSNames' */ /* synthesize a Unicode charmap if there is support in the `PSNames' */
/* module */ /* module */
if ( psnames && psnames->unicode_value ) if ( psnames && psnames->unicode_value )
{ {
error = psnames->build_unicodes( root->memory, error = psnames->build_unicodes( root->memory,
face->type1.num_glyphs, face->type1.num_glyphs,
(const char**)face->type1.glyph_names, (const char**)face->type1.glyph_names,
&face->unicode_map ); &face->unicode_map );
if ( !error ) if ( !error )
{ {
root->charmap = charmap; root->charmap = charmap;
charmap->face = (FT_Face)face; charmap->face = (FT_Face)face;
charmap->encoding = ft_encoding_unicode; charmap->encoding = ft_encoding_unicode;
charmap->platform_id = 3; charmap->platform_id = 3;
charmap->encoding_id = 1; charmap->encoding_id = 1;
charmap++; charmap++;
} }
/* XXX: Is the following code correct? It is used in t1objs.c */ /* XXX: Is the following code correct? It is used in t1objs.c */
/* simply clear the error in case of failure (which really) */ /* simply clear the error in case of failure (which really) */
/* means that out of memory or no unicode glyph names */ /* means that out of memory or no unicode glyph names */
error = FT_Err_Ok; error = T42_Err_Ok;
} }
/* now, support either the standard, expert, or custom encoding */ /* now, support either the standard, expert, or custom encoding */
@ -362,29 +382,29 @@
switch ( face->type1.encoding_type ) switch ( face->type1.encoding_type )
{ {
case T1_ENCODING_TYPE_STANDARD: case T1_ENCODING_TYPE_STANDARD:
charmap->encoding = ft_encoding_adobe_standard; charmap->encoding = ft_encoding_adobe_standard;
charmap->encoding_id = 0; charmap->encoding_id = 0;
break; break;
case T1_ENCODING_TYPE_EXPERT: case T1_ENCODING_TYPE_EXPERT:
charmap->encoding = ft_encoding_adobe_expert; charmap->encoding = ft_encoding_adobe_expert;
charmap->encoding_id = 1; charmap->encoding_id = 1;
break; break;
case T1_ENCODING_TYPE_ARRAY: case T1_ENCODING_TYPE_ARRAY:
charmap->encoding = ft_encoding_adobe_custom; charmap->encoding = ft_encoding_adobe_custom;
charmap->encoding_id = 2; charmap->encoding_id = 2;
break; break;
case T1_ENCODING_TYPE_ISOLATIN1: case T1_ENCODING_TYPE_ISOLATIN1:
charmap->encoding = ft_encoding_latin_1; charmap->encoding = ft_encoding_latin_1;
charmap->encoding_id = 3; charmap->encoding_id = 3;
break; break;
default: default:
FT_ERROR(( "T42_Face_Init: invalid encoding\n" )); FT_ERROR(( "T42_Face_Init: invalid encoding\n" ));
error = FT_Err_Invalid_File_Format; error = T42_Err_Invalid_File_Format;
goto Exit; goto Exit;
} }
root->charmaps = face->charmaps; root->charmaps = face->charmaps;
@ -410,7 +430,7 @@
if ( face ) if ( face )
{ {
type1 = &face->type1; type1 = &face->type1;
info = &type1->font_info; info = &type1->font_info;
memory = face->root.memory; memory = face->root.memory;
@ -454,6 +474,7 @@
} }
} }
/*************************************************************************/ /*************************************************************************/
/* */ /* */
/* <Function> */ /* <Function> */
@ -477,7 +498,7 @@
ttmodule = FT_Get_Module( FT_MODULE(driver)->library, "truetype" ); ttmodule = FT_Get_Module( FT_MODULE(driver)->library, "truetype" );
driver->ttclazz = (FT_Driver_Class)ttmodule->clazz; driver->ttclazz = (FT_Driver_Class)ttmodule->clazz;
return FT_Err_Ok; return T42_Err_Ok;
} }
@ -608,7 +629,7 @@
FT_Face face = size->root.face; FT_Face face = size->root.face;
T42_Face t42face = (T42_Face)face; T42_Face t42face = (T42_Face)face;
FT_Size ttsize; FT_Size ttsize;
FT_Error error = FT_Err_Ok; FT_Error error = T42_Err_Ok;
error = FT_New_Size( t42face->ttf_face, &ttsize ); error = FT_New_Size( t42face->ttf_face, &ttsize );
@ -641,7 +662,7 @@
FT_Face face = slot->root.face; FT_Face face = slot->root.face;
T42_Face t42face = (T42_Face)face; T42_Face t42face = (T42_Face)face;
FT_GlyphSlot ttslot; FT_GlyphSlot ttslot;
FT_Error error = FT_Err_Ok; FT_Error error = T42_Err_Ok;
if ( face->glyph == NULL ) if ( face->glyph == NULL )
@ -879,3 +900,5 @@
return 0; return 0;
} }
/* END */

View File

@ -1,5 +1,22 @@
#ifndef __TYPE42_OBJS_H__ /***************************************************************************/
#define __TYPE42_OBJS_H__ /* */
/* t42objs.h */
/* */
/* Type 42 objects manager (specification). */
/* */
/* Copyright 2002 by Roberto Alameda. */
/* */
/* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */
/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
/* this file you indicate that you have read the license and */
/* understand and accept it fully. */
/* */
/***************************************************************************/
#ifndef __T42OBJS_H__
#define __T42OBJS_H__
#include <ft2build.h> #include <ft2build.h>
#include FT_FREETYPE_H #include FT_FREETYPE_H
@ -10,9 +27,10 @@
#include FT_INTERNAL_POSTSCRIPT_NAMES_H #include FT_INTERNAL_POSTSCRIPT_NAMES_H
#include FT_INTERNAL_POSTSCRIPT_HINTS_H #include FT_INTERNAL_POSTSCRIPT_HINTS_H
FT_BEGIN_HEADER FT_BEGIN_HEADER
/* Type42 face */ /* Type42 face */
typedef struct T42_FaceRec_ typedef struct T42_FaceRec_
{ {
FT_FaceRec root; FT_FaceRec root;
@ -32,8 +50,7 @@ FT_BEGIN_HEADER
} T42_FaceRec, *T42_Face; } T42_FaceRec, *T42_Face;
/* Type42 size */
/* Type42 size */
typedef struct T42_SizeRec_ typedef struct T42_SizeRec_
{ {
FT_SizeRec root; FT_SizeRec root;
@ -42,7 +59,7 @@ FT_BEGIN_HEADER
} T42_SizeRec, *T42_Size; } T42_SizeRec, *T42_Size;
/* Type42 slot */ /* Type42 slot */
typedef struct T42_GlyphSlotRec_ typedef struct T42_GlyphSlotRec_
{ {
FT_GlyphSlotRec root; FT_GlyphSlotRec root;
@ -51,7 +68,7 @@ FT_BEGIN_HEADER
} T42_GlyphSlotRec, *T42_GlyphSlot; } T42_GlyphSlotRec, *T42_GlyphSlot;
/* Type 42 driver */ /* Type 42 driver */
typedef struct T42_DriverRec_ typedef struct T42_DriverRec_
{ {
FT_DriverRec root; FT_DriverRec root;
@ -60,7 +77,9 @@ FT_BEGIN_HEADER
} T42_DriverRec, *T42_Driver; } T42_DriverRec, *T42_Driver;
/* */
/* */
FT_LOCAL( FT_Error ) FT_LOCAL( FT_Error )
T42_Face_Init( FT_Stream stream, T42_Face_Init( FT_Stream stream,
@ -127,4 +146,8 @@ FT_BEGIN_HEADER
FT_END_HEADER FT_END_HEADER
#endif /* __TYPE42_OBJS_H__ */
#endif /* __T42OBJS_H__ */
/* END */

View File

@ -1,9 +1,28 @@
/***************************************************************************/
/* */
/* t42parse.c */
/* */
/* Type 42 font parser (body). */
/* */
/* Copyright 2002 by Roberto Alameda. */
/* */
/* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */
/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
/* this file you indicate that you have read the license and */
/* understand and accept it fully. */
/* */
/***************************************************************************/
#include "t42parse.h" #include "t42parse.h"
#include "t42error.h"
#include FT_INTERNAL_DEBUG_H #include FT_INTERNAL_DEBUG_H
#include FT_INTERNAL_STREAM_H #include FT_INTERNAL_STREAM_H
#include FT_LIST_H #include FT_LIST_H
#include FT_INTERNAL_POSTSCRIPT_AUX_H #include FT_INTERNAL_POSTSCRIPT_AUX_H
/*************************************************************************/ /*************************************************************************/
/* */ /* */
/* The macro FT_COMPONENT is used in trace mode. It is an implicit */ /* The macro FT_COMPONENT is used in trace mode. It is an implicit */
@ -13,6 +32,7 @@
#undef FT_COMPONENT #undef FT_COMPONENT
#define FT_COMPONENT trace_t42 #define FT_COMPONENT trace_t42
static void static void
t42_parse_font_name( T42_Face face, t42_parse_font_name( T42_Face face,
T42_Loader loader ); T42_Loader loader );
@ -118,7 +138,7 @@
FT_Memory memory, FT_Memory memory,
PSAux_Service psaux ) PSAux_Service psaux )
{ {
FT_Error error = FT_Err_Ok; FT_Error error = T42_Err_Ok;
FT_Long size; FT_Long size;
@ -165,8 +185,8 @@
else else
{ {
/* read segment in memory */ /* read segment in memory */
if ( FT_ALLOC( parser->base_dict, size ) || if ( FT_ALLOC( parser->base_dict, size ) ||
FT_STREAM_READ( parser->base_dict, size ) ) FT_STREAM_READ( parser->base_dict, size ) )
goto Exit; goto Exit;
parser->base_len = size; parser->base_len = size;
@ -176,7 +196,7 @@
if (size <= 17 || if (size <= 17 ||
( ft_strncmp( (const char*)parser->base_dict, ( ft_strncmp( (const char*)parser->base_dict,
"%!PS-TrueTypeFont", 17) ) ) "%!PS-TrueTypeFont", 17) ) )
error = FT_Err_Unknown_File_Format; error = T42_Err_Unknown_File_Format;
else else
{ {
parser->root.base = parser->base_dict; parser->root.base = parser->base_dict;
@ -346,7 +366,7 @@
if ( cur >= limit ) if ( cur >= limit )
{ {
FT_ERROR(( "t42_parse_encoding: out of bounds!\n" )); FT_ERROR(( "t42_parse_encoding: out of bounds!\n" ));
parser->root.error = FT_Err_Invalid_File_Format; parser->root.error = T42_Err_Invalid_File_Format;
return; return;
} }
} }
@ -485,7 +505,7 @@
else { else {
FT_ERROR(( "t42_parse_encoding: invalid token!\n" )); FT_ERROR(( "t42_parse_encoding: invalid token!\n" ));
parser->root.error = FT_Err_Invalid_File_Format; parser->root.error = T42_Err_Invalid_File_Format;
} }
} }
} }
@ -549,7 +569,7 @@
else else
{ {
FT_ERROR(( "t42_parse_sfnts: can't find begin of sfnts vector!\n" )); FT_ERROR(( "t42_parse_sfnts: can't find begin of sfnts vector!\n" ));
error = FT_Err_Invalid_File_Format; error = T42_Err_Invalid_File_Format;
goto Fail; goto Fail;
} }
@ -574,7 +594,7 @@
if ( !in_string ) if ( !in_string )
{ {
FT_ERROR(( "t42_parse_sfnts: found unpaired `>'!\n" )); FT_ERROR(( "t42_parse_sfnts: found unpaired `>'!\n" ));
error = FT_Err_Invalid_File_Format; error = T42_Err_Invalid_File_Format;
goto Fail; goto Fail;
} }
@ -597,7 +617,7 @@
else else
{ {
FT_ERROR(( "t42_parse_sfnts: found `%' in string!\n" )); FT_ERROR(( "t42_parse_sfnts: found `%' in string!\n" ));
error = FT_Err_Invalid_File_Format; error = T42_Err_Invalid_File_Format;
goto Fail; goto Fail;
} }
@ -605,7 +625,7 @@
if ( !ft_xdigit( *cur ) || !ft_xdigit( *(cur + 1) ) ) if ( !ft_xdigit( *cur ) || !ft_xdigit( *(cur + 1) ) )
{ {
FT_ERROR(( "t42_parse_sfnts: found non-hex characters in string" )); FT_ERROR(( "t42_parse_sfnts: found non-hex characters in string" ));
error = FT_Err_Invalid_File_Format; error = T42_Err_Invalid_File_Format;
goto Fail; goto Fail;
} }
@ -670,7 +690,7 @@
} }
/* If control reaches this point, the format was not valid */ /* If control reaches this point, the format was not valid */
error = FT_Err_Invalid_File_Format; error = T42_Err_Invalid_File_Format;
Fail: Fail:
parser->root.error = error; parser->root.error = error;
@ -780,7 +800,7 @@
if ( ft_strcmp( (char *)name_table->elements[0], ".notdef" ) ) if ( ft_strcmp( (char *)name_table->elements[0], ".notdef" ) )
{ {
FT_ERROR(( "t42_parse_charstrings: Index 0 is not `.notdef'!\n" )); FT_ERROR(( "t42_parse_charstrings: Index 0 is not `.notdef'!\n" ));
error = FT_Err_Invalid_File_Format; error = T42_Err_Invalid_File_Format;
goto Fail; goto Fail;
} }
@ -970,3 +990,4 @@
} }
/* END */

View File

@ -1,9 +1,28 @@
#ifndef __TYPE42_PARSE_H__ /***************************************************************************/
#define __TYPE42_PARSE_H__ /* */
/* t42parse.h */
/* */
/* Type 42 font parser (specification). */
/* */
/* Copyright 2002 by Roberto Alameda. */
/* */
/* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */
/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
/* this file you indicate that you have read the license and */
/* understand and accept it fully. */
/* */
/***************************************************************************/
#ifndef __T42PARSE_H__
#define __T42PARSE_H__
#include "t42objs.h" #include "t42objs.h"
#include FT_INTERNAL_POSTSCRIPT_AUX_H #include FT_INTERNAL_POSTSCRIPT_AUX_H
FT_BEGIN_HEADER FT_BEGIN_HEADER
typedef struct T42_ParserRec_ typedef struct T42_ParserRec_
@ -63,4 +82,8 @@ FT_BEGIN_HEADER
FT_END_HEADER FT_END_HEADER
#endif /* __TYPE42_PARSE_H__ */
#endif /* __T42PARSE_H__ */
/* END */

View File

@ -1,12 +1,20 @@
/***************************************************************************/ /***************************************************************************/
/* */ /* */
/* type42c */ /* type42.c */
/* */ /* */
/* FreeType Type 42 driver component */ /* FreeType Type 42 driver component. */
/* */
/* Copyright 2002 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
/* modified, and distributed under the terms of the FreeType project */
/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
/* this file you indicate that you have read the license and */
/* understand and accept it fully. */
/* */ /* */
/***************************************************************************/ /***************************************************************************/
#define FT_MAKE_OPTION_SINGLE_OBJECT #define FT_MAKE_OPTION_SINGLE_OBJECT
#include <ft2build.h> #include <ft2build.h>