22#include FT_INTERNAL_OBJECTS_H
23#include FT_INTERNAL_CALC_H
67 dist =
w - stand->
cur;
154 for ( ; read_count > 1; read_count -= 2 )
164 if (
first || is_others )
169 zones = bot_table->
zones;
178 zones = top_table->
zones;
187 if ( reference < zone->org_ref )
199 if ( delta < delta0 )
200 zone->org_delta = delta;
204 if ( delta > delta0 )
205 zone->org_delta = delta;
215 zone->org_delta = delta;
226 top_table->
count = count_top;
227 bot_table->
count = count_bot;
249 top_table = &
target->family_top;
250 bot_table = &
target->family_bottom;
254 top_table = &
target->normal_top;
255 bot_table = &
target->normal_bottom;
260 top_table->
count = 0;
261 bot_table->
count = 0;
265 count, blues, top_table, bot_table );
267 count_others, other_blues, top_table, bot_table );
269 count_top = top_table->
count;
270 count_bot = bot_table->
count;
285 delta =
zone[1].org_ref -
zone[0].org_ref;
286 if (
zone->org_delta > delta )
287 zone->org_delta = delta;
308 delta =
zone[0].org_ref -
zone[1].org_ref;
309 if (
zone->org_delta < delta )
310 zone->org_delta = delta;
327 for ( dim = 1; dim >= 0; dim-- )
332 zone->org_bottom -= fuzz;
340 bot =
zone[1].org_bottom;
343 if ( delta / 2 < fuzz )
344 zone[0].org_top =
zone[1].org_bottom =
top + delta / 2;
348 zone[1].org_bottom = bot - fuzz;
406 if (
scale >= 0x20C49BAL )
464 if (
zone->cur_ref >
zone->cur_top )
466 else if (
zone->cur_ref <
zone->cur_bottom )
496 for ( ; count1 > 0; count1--, zone1++ )
500 zone2 = family->
zones;
501 count2 = family->
count;
503 for ( ; count2 > 0; count2--, zone2++ )
540 if ( cur_height > cur_max )
541 cur_max = cur_height;
563 no_shoots = blues->no_overshoots;
566 table = &blues->normal_top;
573 if ( delta < -blues->blue_fuzz )
576 if ( stem_top <= zone->org_top + blues->blue_fuzz )
578 if ( no_shoots || delta <= blues->blue_threshold )
588 table = &blues->normal_bottom;
595 if ( delta < -blues->blue_fuzz )
598 if ( stem_bot >=
zone->org_bottom - blues->blue_fuzz )
600 if ( no_shoots || delta < blues->blue_threshold )
628 globals->dimension[0].stdw.count = 0;
629 globals->dimension[1].stdw.count = 0;
631 globals->blues.normal_top.count = 0;
632 globals->blues.normal_bottom.count = 0;
633 globals->blues.family_top.count = 0;
634 globals->blues.family_bottom.count = 0;
639 ps_debug_globals =
NULL;
730 max_scale =
FT_DivFix( 1000, max_height );
731 globals->blues.blue_scale = priv->
blue_scale < max_scale
737 globals->blues.blue_fuzz = priv->
blue_fuzz;
739 globals->dimension[0].scale_mult = 0;
740 globals->dimension[0].scale_delta = 0;
741 globals->dimension[1].scale_mult = 0;
742 globals->dimension[1].scale_delta = 0;
745 ps_debug_globals = globals;
764 dim = &globals->dimension[0];
774 dim = &globals->dimension[1];
_Check_return_ _Ret_maybenull_ _In_ size_t alignment
FT_DivFix(FT_Long a, FT_Long b)
FT_MulFix(FT_Long a, FT_Long b)
FT_BEGIN_HEADER typedef signed long FT_Pos
typedefFT_BEGIN_HEADER struct FT_MemoryRec_ * FT_Memory
FT_BEGIN_HEADER typedef unsigned char FT_Bool
GLuint GLuint GLsizei count
GLint GLint GLsizei width
GLenum GLenum GLenum GLenum GLenum scale
GLdouble GLdouble GLdouble GLdouble top
GLboolean GLenum GLenum GLvoid * values
GLubyte GLubyte GLubyte GLubyte w
typedefFT_BEGIN_HEADER struct PSH_GlobalsRec_ * PSH_Globals
static char memory[1024 *256]
static void psh_blues_set_zones_0(PSH_Blues target, FT_Bool is_others, FT_UInt read_count, FT_Short *read, PSH_Blue_Table top_table, PSH_Blue_Table bot_table)
static void psh_blues_set_zones(PSH_Blues target, FT_UInt count, FT_Short *blues, FT_UInt count_others, FT_Short *other_blues, FT_Int fuzz, FT_Int family)
psh_globals_funcs_init(PSH_Globals_FuncsRec *funcs)
static void psh_globals_scale_widths(PSH_Globals globals, FT_UInt direction)
static FT_Short psh_calc_max_height(FT_UInt num, const FT_Short *values, FT_Short cur_max)
static void psh_globals_destroy(PSH_Globals globals)
psh_blues_snap_stem(PSH_Blues blues, FT_Int stem_top, FT_Int stem_bot, PSH_Alignment alignment)
static FT_Error psh_globals_new(FT_Memory memory, T1_Private *priv, PSH_Globals *aglobals)
static void psh_blues_scale_zones(PSH_Blues blues, FT_Fixed scale, FT_Pos delta)
psh_globals_set_scale(PSH_Globals globals, FT_Fixed x_scale, FT_Fixed y_scale, FT_Fixed x_delta, FT_Fixed y_delta)
#define PSH_BLUE_ALIGN_BOT
#define PSH_BLUE_ALIGN_NONE
#define PSH_BLUE_ALIGN_TOP
static struct __wine_debug_functions funcs
STDMETHOD() Skip(THIS_ ULONG celt) PURE
PSH_Blue_ZoneRec zones[PS_GLOBALS_MAX_BLUE_ZONES]
PSH_Blue_TableRec family_bottom
PSH_Blue_TableRec normal_top
PSH_Blue_TableRec normal_bottom
PSH_Blue_TableRec family_top
PSH_WidthRec widths[PS_GLOBALS_MAX_STD_WIDTHS]
FT_UShort standard_width[1]
FT_Short snap_heights[13]
FT_Byte num_family_other_blues
FT_UShort standard_height[1]
FT_Short family_blues[14]
FT_Short family_other_blues[10]