#include <freetype/freetype.h>
#include <freetype/internal/ftobjs.h>
#include <freetype/internal/ftdebug.h>
#include <freetype/internal/ftcalc.h>
#include "pshrec.h"
#include "pshalgo.h"
#include "pshnterr.h"
#undef FT_COMPONENT
#define FT_COMPONENT …
#ifdef DEBUG_HINTER
PS_Hints ps_debug_hints = NULL;
int ps_debug_no_horz_hints = 0;
int ps_debug_no_vert_hints = 0;
#endif
static void
ps_hint_table_done( PS_Hint_Table table,
FT_Memory memory )
{ … }
static FT_Error
ps_hint_table_ensure( PS_Hint_Table table,
FT_UInt count,
FT_Memory memory )
{ … }
static FT_Error
ps_hint_table_alloc( PS_Hint_Table table,
FT_Memory memory,
PS_Hint *ahint )
{ … }
static void
ps_mask_done( PS_Mask mask,
FT_Memory memory )
{ … }
static FT_Error
ps_mask_ensure( PS_Mask mask,
FT_UInt count,
FT_Memory memory )
{ … }
static FT_Int
ps_mask_test_bit( PS_Mask mask,
FT_UInt idx )
{ … }
static FT_Error
ps_mask_set_bit( PS_Mask mask,
FT_UInt idx,
FT_Memory memory )
{ … }
static void
ps_mask_table_done( PS_Mask_Table table,
FT_Memory memory )
{ … }
static FT_Error
ps_mask_table_ensure( PS_Mask_Table table,
FT_UInt count,
FT_Memory memory )
{ … }
static FT_Error
ps_mask_table_alloc( PS_Mask_Table table,
FT_Memory memory,
PS_Mask *amask )
{ … }
static FT_Error
ps_mask_table_last( PS_Mask_Table table,
FT_Memory memory,
PS_Mask *amask )
{ … }
static FT_Error
ps_mask_table_set_bits( PS_Mask_Table table,
const FT_Byte* source,
FT_UInt bit_pos,
FT_UInt bit_count,
FT_Memory memory )
{ … }
static FT_Int
ps_mask_table_test_intersect( PS_Mask_Table table,
FT_UInt index1,
FT_UInt index2 )
{ … }
static FT_Error
ps_mask_table_merge( PS_Mask_Table table,
FT_UInt index1,
FT_UInt index2,
FT_Memory memory )
{ … }
static FT_Error
ps_mask_table_merge_all( PS_Mask_Table table,
FT_Memory memory )
{ … }
static void
ps_dimension_done( PS_Dimension dimension,
FT_Memory memory )
{ … }
static void
ps_dimension_init( PS_Dimension dimension )
{ … }
#if 0
static FT_Error
ps_dimension_set_mask_bit( PS_Dimension dim,
FT_UInt idx,
FT_Memory memory )
{
PS_Mask mask;
FT_Error error = FT_Err_Ok;
error = ps_mask_table_last( &dim->masks, memory, &mask );
if ( error )
goto Exit;
error = ps_mask_set_bit( mask, idx, memory );
Exit:
return error;
}
#endif
static void
ps_dimension_end_mask( PS_Dimension dim,
FT_UInt end_point )
{ … }
static FT_Error
ps_dimension_reset_mask( PS_Dimension dim,
FT_UInt end_point,
FT_Memory memory )
{ … }
static FT_Error
ps_dimension_set_mask_bits( PS_Dimension dim,
const FT_Byte* source,
FT_UInt source_pos,
FT_UInt source_bits,
FT_UInt end_point,
FT_Memory memory )
{ … }
static FT_Error
ps_dimension_add_t1stem( PS_Dimension dim,
FT_Int pos,
FT_Int len,
FT_Memory memory,
FT_UInt *aindex )
{ … }
static FT_Error
ps_dimension_add_counter( PS_Dimension dim,
FT_UInt hint1,
FT_UInt hint2,
FT_UInt hint3,
FT_Memory memory )
{ … }
static FT_Error
ps_dimension_end( PS_Dimension dim,
FT_UInt end_point,
FT_Memory memory )
{ … }
FT_LOCAL_DEF( void )
ps_hints_done( PS_Hints hints )
{ … }
FT_LOCAL_DEF( void )
ps_hints_init( PS_Hints hints,
FT_Memory memory )
{ … }
static void
ps_hints_open( PS_Hints hints,
PS_Hint_Type hint_type )
{ … }
static void
ps_hints_stem( PS_Hints hints,
FT_UInt dimension,
FT_Int count,
FT_Long* stems )
{ … }
static void
ps_hints_t1stem3( T1_Hints hints_,
FT_UInt dimension,
FT_Fixed* stems )
{ … }
static void
ps_hints_t1reset( T1_Hints hints_,
FT_UInt end_point )
{ … }
static void
ps_hints_t2mask( T2_Hints hints_,
FT_UInt end_point,
FT_UInt bit_count,
const FT_Byte* bytes )
{ … }
static void
ps_hints_t2counter( T2_Hints hints_,
FT_UInt bit_count,
const FT_Byte* bytes )
{ … }
static FT_Error
ps_hints_close( PS_Hints hints,
FT_UInt end_point )
{ … }
static void
t1_hints_open( T1_Hints hints )
{ … }
static FT_Error
t1_hints_close( T1_Hints hints,
FT_UInt end_point )
{ … }
static void
t1_hints_stem( T1_Hints hints,
FT_UInt dimension,
FT_Fixed* coords )
{ … }
static FT_Error
t1_hints_apply( T1_Hints hints,
FT_Outline* outline,
PSH_Globals globals,
FT_Render_Mode hint_mode )
{ … }
FT_LOCAL_DEF( void )
t1_hints_funcs_init( T1_Hints_FuncsRec* funcs )
{ … }
static void
t2_hints_open( T2_Hints hints )
{ … }
static FT_Error
t2_hints_close( T2_Hints hints,
FT_UInt end_point )
{ … }
static void
t2_hints_stems( T2_Hints hints,
FT_UInt dimension,
FT_Int count,
FT_Fixed* coords )
{ … }
static FT_Error
t2_hints_apply( T2_Hints hints,
FT_Outline* outline,
PSH_Globals globals,
FT_Render_Mode hint_mode )
{ … }
FT_LOCAL_DEF( void )
t2_hints_funcs_init( T2_Hints_FuncsRec* funcs )
{ … }