freetype-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Devel] Getting accurate advances


From: Rogier van Dalen
Subject: Re: [Devel] Getting accurate advances
Date: Tue, 25 Nov 2003 00:26:39 +0100

> > The undocumented behaviour for the MSIRP instruction is fixed, as
> > well as (documented!) behaviour for rounding zero and the DIV
> > instruction.
>
> Hmm, it is not clear to me why you replace
>
>   args[0] = TT_MULDIV( args[0], 64L, args[1] );
>
> with
>
>   args[0] = ( args[0] * 64L ) / args[1];

Because, as the MS spec states rather clearly,
"[The DIV instruction] truncates rather than rounds the value."

> Since FT_Int64 can be either a structure or a data type we have to
> provide some code in case TT_MULDIV really can't be used here to avoid
> overflow.

Then, I'm afraid, that code will have to be provided. (I don't quite feel up
to this myself.)

>
> I've now applied everything, together with my fixes for improved
> computation of linearHoriAdvance and linearVertAdvance.  Please test.
>
> A big hurray to Rogier!

Thanks :-)

Rogier






reply via email to

[Prev in Thread] Current Thread [Next in Thread]