From ec62c527eb34ee4481a0153ceb42dfd35d7e1d26 Mon Sep 17 00:00:00 2001 From: Makoto Onuki Date: Tue, 9 Jun 2015 16:35:08 -0700 Subject: Update to freetype 2.6.0 Bug 18751561 Change-Id: I871cc2925dc5908ec48073e11ecffad1924bbf50 --- src/autofit/afangles.c | 64 ++------------------------------------------------ 1 file changed, 2 insertions(+), 62 deletions(-) (limited to 'src/autofit/afangles.c') diff --git a/src/autofit/afangles.c b/src/autofit/afangles.c index b44a5ba..1b1eb31 100644 --- a/src/autofit/afangles.c +++ b/src/autofit/afangles.c @@ -5,7 +5,7 @@ /* Routines used to compute vector angles with limited accuracy */ /* and very high speed. It also contains sorting routines (body). */ /* */ -/* Copyright 2003-2006, 2011-2012 by */ +/* Copyright 2003-2015 by */ /* David Turner, Robert Wilhelm, and Werner Lemberg. */ /* */ /* This file is part of the FreeType project, and may only be used, */ @@ -20,66 +20,6 @@ #include "aftypes.h" -#if 0 - - FT_LOCAL_DEF( FT_Int ) - af_corner_is_flat( FT_Pos x_in, - FT_Pos y_in, - FT_Pos x_out, - FT_Pos y_out ) - { - FT_Pos ax = x_in; - FT_Pos ay = y_in; - - FT_Pos d_in, d_out, d_corner; - - - if ( ax < 0 ) - ax = -ax; - if ( ay < 0 ) - ay = -ay; - d_in = ax + ay; - - ax = x_out; - if ( ax < 0 ) - ax = -ax; - ay = y_out; - if ( ay < 0 ) - ay = -ay; - d_out = ax + ay; - - ax = x_out + x_in; - if ( ax < 0 ) - ax = -ax; - ay = y_out + y_in; - if ( ay < 0 ) - ay = -ay; - d_corner = ax + ay; - - return ( d_in + d_out - d_corner ) < ( d_corner >> 4 ); - } - - - FT_LOCAL_DEF( FT_Int ) - af_corner_orientation( FT_Pos x_in, - FT_Pos y_in, - FT_Pos x_out, - FT_Pos y_out ) - { - FT_Pos delta; - - - delta = x_in * y_out - y_in * x_out; - - if ( delta == 0 ) - return 0; - else - return 1 - 2 * ( delta < 0 ); - } - -#endif /* 0 */ - - /* * We are not using `af_angle_atan' anymore, but we keep the source * code below just in case... @@ -319,7 +259,7 @@ sum += table[j].org; table[j].org = 0; } - table[cur_idx].org = sum / j; + table[cur_idx].org = sum / (FT_Pos)j; if ( i < *count - 1 ) { -- cgit v1.2.3