* src/base/fttrigon.c (ft_trig_prenorm): fixed a bug that created
invalid computations, resulting in very weird bugs in TrueType bytecode hinted fonts * src/truetype/ttinterp.c: redefined FT_UNUSED_EXEC to not perform a structure copy each time. Wooot. !
This commit is contained in:
parent
d829ff768b
commit
f7cc181425
11
ChangeLog
11
ChangeLog
|
@ -1,9 +1,18 @@
|
||||||
|
2005-11-15 David Turner <david@freetype.org>
|
||||||
|
|
||||||
|
* src/base/fttrigon.c (ft_trig_prenorm): fixed a bug that created
|
||||||
|
invalid computations, resulting in very weird bugs in TrueType
|
||||||
|
bytecode hinted fonts
|
||||||
|
|
||||||
|
* src/truetype/ttinterp.c: redefined FT_UNUSED_EXEC to not perform
|
||||||
|
a structure copy each time. Wooot. !
|
||||||
|
|
||||||
2005-11-11 Werner Lemberg <wl@gnu.org>
|
2005-11-11 Werner Lemberg <wl@gnu.org>
|
||||||
|
|
||||||
* src/cache/ftccache.c (FTC_Cache_Clear), src/cache/ftcmanag.c
|
* src/cache/ftccache.c (FTC_Cache_Clear), src/cache/ftcmanag.c
|
||||||
(FTC_Manager_Check): Remove FT_EXPORT_DEF tag.
|
(FTC_Manager_Check): Remove FT_EXPORT_DEF tag.
|
||||||
|
|
||||||
* src/base/ftcalc.c (FT_Add64): Remove FT_EXPORT_DEF tag.
|
* src/base/ftcalc.c (FT_Add64): Remove FT_EXPORT_DEF tag.
|
||||||
(FT_Div64by32, FT_Sqrt32): Commented out. Unused.
|
(FT_Div64by32, FT_Sqrt32): Commented out. Unused.
|
||||||
|
|
||||||
* include/freetype/internal/ftcalc.h (SQRT_32): Removed. Unused.
|
* include/freetype/internal/ftcalc.h (SQRT_32): Removed. Unused.
|
||||||
|
|
|
@ -110,7 +110,6 @@
|
||||||
shift = 0;
|
shift = 0;
|
||||||
|
|
||||||
#if 1
|
#if 1
|
||||||
|
|
||||||
/* determine msb bit index in `shift' */
|
/* determine msb bit index in `shift' */
|
||||||
if ( z >= ( 1L << 16 ) )
|
if ( z >= ( 1L << 16 ) )
|
||||||
{
|
{
|
||||||
|
@ -132,18 +131,21 @@
|
||||||
z >>= 2;
|
z >>= 2;
|
||||||
shift += 2;
|
shift += 2;
|
||||||
}
|
}
|
||||||
if ( z >= 1 )
|
if ( z >= ( 1L << 1 ) )
|
||||||
shift += 1;
|
|
||||||
|
|
||||||
if ( shift < 28 )
|
|
||||||
{
|
{
|
||||||
shift = 28 - shift;
|
z >>= 1;
|
||||||
|
shift += 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ( shift <= 27 )
|
||||||
|
{
|
||||||
|
shift = 27 - shift;
|
||||||
vec->x = x << shift;
|
vec->x = x << shift;
|
||||||
vec->y = y << shift;
|
vec->y = y << shift;
|
||||||
}
|
}
|
||||||
else if ( shift > 28 )
|
else
|
||||||
{
|
{
|
||||||
shift -= 28;
|
shift -= 27;
|
||||||
vec->x = x >> shift;
|
vec->x = x >> shift;
|
||||||
vec->y = y >> shift;
|
vec->y = y >> shift;
|
||||||
shift = -shift;
|
shift = -shift;
|
||||||
|
|
|
@ -94,10 +94,14 @@
|
||||||
|
|
||||||
#define CUR (*exc) /* see ttobjs.h */
|
#define CUR (*exc) /* see ttobjs.h */
|
||||||
|
|
||||||
|
#define FT_UNUSED_EXEC FT_UNUSED(exc)
|
||||||
|
|
||||||
#else /* static implementation */
|
#else /* static implementation */
|
||||||
|
|
||||||
#define CUR cur
|
#define CUR cur
|
||||||
|
|
||||||
|
#define FT_UNUSED_EXEC int __dummy=__dummy
|
||||||
|
|
||||||
static
|
static
|
||||||
TT_ExecContextRec cur; /* static exec. context variable */
|
TT_ExecContextRec cur; /* static exec. context variable */
|
||||||
|
|
||||||
|
@ -120,7 +124,7 @@
|
||||||
/* This macro is used whenever `exec' is unused in a function, to avoid */
|
/* This macro is used whenever `exec' is unused in a function, to avoid */
|
||||||
/* stupid warnings from pedantic compilers. */
|
/* stupid warnings from pedantic compilers. */
|
||||||
/* */
|
/* */
|
||||||
#define FT_UNUSED_EXEC FT_UNUSED( CUR )
|
/* #define FT_UNUSED_EXEC FT_UNUSED( CUR ) */
|
||||||
|
|
||||||
|
|
||||||
/*************************************************************************/
|
/*************************************************************************/
|
||||||
|
|
Loading…
Reference in New Issue