* src/autohint/ahglyph.c (ah_test_extrema): Renamed to...

(ah_test_extremum): This.
This commit is contained in:
Werner Lemberg 2003-05-02 15:16:13 +00:00
parent a3f4da8e99
commit a547a532a1
4 changed files with 31 additions and 22 deletions

View File

@ -1,3 +1,8 @@
2003-05-01 Werner Lemberg <wl@gnu.org>
* src/autohint/ahglyph.c (ah_test_extrema): Renamed to...
(ah_test_extremum): This.
2003-04-28 Werner Lemberg <wl@gnu.org>
* builds/unix/configure.ac: Generate `freetype.pc' from

View File

@ -235,8 +235,8 @@
AH_LOG(( "\n" ));
/* we have computed the contents of the `rounds' and `flats' tables, */
/* now determine the reference and overshoot position of the blue; */
/* we simply take the median value after a simple short */
/* now determine the reference and overshoot position of the blue -- */
/* we simply take the median value after a simple sort */
sort_values( num_rounds, rounds );
sort_values( num_flats, flats );
@ -312,7 +312,7 @@
/* stem height of the "-", but it wasn't too good. Moreover, we now */
/* have a single character that gives us standard width and height. */
{
FT_UInt glyph_index;
FT_UInt glyph_index;
glyph_index = FT_Get_Char_Index( hinter->face, 'o' );
@ -376,7 +376,7 @@
}
/* Now, compute the edge distance threshold as a fraction of the */
/* smallest width in the font. Set it in `hinter.glyph' too! */
/* smallest width in the font. Set it in `hinter->glyph' too! */
if ( edge_distance_threshold == 32000 )
edge_distance_threshold = 50;

View File

@ -120,8 +120,8 @@
: ( seg->dir == AH_DIR_RIGHT
? "right"
: "none" ) ) ),
seg->link ? (seg->link-segments) : -1,
seg->serif ? (seg->serif-segments) : -1,
seg->link ? ( seg->link - segments ) : -1,
seg->serif ? ( seg->serif - segments ) : -1,
(int)seg->num_linked,
seg->first - points,
seg->last - points );
@ -135,7 +135,7 @@
#endif /* AH_DEBUG */
/* compute the direction value of a given vector.. */
/* compute the direction value of a given vector */
static AH_Direction
ah_compute_direction( FT_Pos dx,
FT_Pos dy )
@ -147,6 +147,8 @@
dir = AH_DIR_NONE;
/* atan(1/12) == 4.7 degrees */
/* test for vertical direction */
if ( ax * 12 < ay )
{
@ -163,10 +165,10 @@
/* this function is used by ah_get_orientation (see below) to test */
/* the fill direction of a given bbox extrema */
/* the fill direction of given bbox extremum */
static FT_Int
ah_test_extrema( FT_Outline* outline,
FT_Int n )
ah_test_extremum( FT_Outline* outline,
FT_Int n )
{
FT_Vector *prev, *cur, *next;
FT_Pos product;
@ -175,7 +177,9 @@
/* we need to compute the `previous' and `next' point */
/* for these extrema */
/* for this extremum; we check whether the extremum */
/* is start or end of a contour and providing */
/* appropriate values if so */
cur = outline->points + n;
prev = cur - 1;
next = cur + 1;
@ -183,7 +187,7 @@
first = 0;
for ( c = 0; c < outline->n_contours; c++ )
{
last = outline->contours[c];
last = outline->contours[c];
if ( n == first )
prev = outline->points + last;
@ -218,7 +222,7 @@
/* We do this by computing bounding box points, and computing their */
/* curvature. */
/* */
/* The function returns either 1 or -1. */
/* The function returns either 1 or 2. */
/* */
static FT_Int
ah_get_orientation( FT_Outline* outline )
@ -272,20 +276,20 @@
}
}
/* test orientation of the xmin */
n = ah_test_extrema( outline, indices_xMin );
/* test orientation of the extrema */
n = ah_test_extremum( outline, indices_xMin );
if ( n )
goto Exit;
n = ah_test_extrema( outline, indices_yMin );
n = ah_test_extremum( outline, indices_yMin );
if ( n )
goto Exit;
n = ah_test_extrema( outline, indices_xMax );
n = ah_test_extremum( outline, indices_xMax );
if ( n )
goto Exit;
n = ah_test_extrema( outline, indices_yMax );
n = ah_test_extremum( outline, indices_yMax );
if ( !n )
n = 1;
@ -306,14 +310,14 @@
ah_outline_new( FT_Memory memory,
AH_Outline* aoutline )
{
FT_Error error;
AH_Outline outline;
FT_Error error;
AH_Outline outline;
if ( !FT_NEW( outline ) )
{
outline->memory = memory;
*aoutline = outline;
*aoutline = outline;
}
return error;

View File

@ -121,7 +121,7 @@ FT_BEGIN_HEADER
/*************************************************************************/
/* see agangles.h */
/* see ahangles.h */
typedef FT_Int AH_Angle;