freetype-devel
[Top][All Lists]
Advanced

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

[ft-devel] Fw: [OpenType] Re: TrueType adv.width scaling


From: Werner LEMBERG
Subject: [ft-devel] Fw: [OpenType] Re: TrueType adv.width scaling
Date: Sat, 04 Mar 2006 16:25:57 +0100 (CET)

Similar reasons as outlined in this mail from a Microsoft guy might be
the causes of the rendering differences between FreeType and the
Windows rasterizer...


    Werner

--- Begin Message --- Subject: [OpenType] Re: TrueType adv.width scaling Date: Sat, 4 Mar 2006 06:31:00 -0800
OpenType list address: address@hidden

Not consistently, unfortunately... or not as pedantic as I would prefer it 
to... The root of the problem appears to be a plurality of numerical formats 
(16.16, 26.6, and 32.0), combined with innocent conversions (notice the plural 
here) between those formats, entailing a plurality of conversion code paths: 
16.16 -> 26.6 -> 32.0 vs 16.16 -> 32.0 vs ...
 
To cut a long story short: I tend to call this the "double rounding jeopardy." 
First round a 16.16 to 26.6, then round the 26.6 to 32.0---as opposed to 
rounding the 16.16 to 32.0 in a single step---and finally marvel at the 
surprising deviations between the two code paths... I'll assume the legacy 
thereof is that at the turn of the 1990s processor speed was at a premium, 
while in the 21st century total cost of code maintenance is probably the more 
dominant premium.
 
Yuri, if there's any combination of font/ppem size/Unicode # you're 
particularly interested in, please don't hesitate to let me know and I'll try 
to do my best (within what legal constraints I might be under) to answer the 
question in excruciating detail.
 
All, 26.6 is a 32bit number with 26 binary digits (decimal numbers in range 
-33,554,432 through 33,554,431) and 6 binary places (decimal fractions in range 
1/2 through 1/64). These numbers can be represented and processed efficiently 
by a computer of early 90ies vintage. Other formats are defined similarly, 
according to the requirements of fractional precision, and any of these formats 
may be perfectly valid in their respective context. The problem arises from the 
repeated innocent conversion between one format and another; a bit like the 
conversion from just about any European currency to Euros and *back*; someone's 
going to loose in the process, and I bet it's not the banks...
 
Hope this helps
 
Beat

________________________________

From: address@hidden on behalf of Yuri Yarmola
Sent: Thu 2006-03-02 10:29
To: Multiple recipients of opentype
Subject: [OpenType] TrueType adv.width scaling



OpenType list address: address@hidden

I have one simple question: how TT machine scales advanced width when value
falls on the middle of the pixel at some PPM? It seems that it will produce
7 for 7.5 while CacheTT will produce 8.

No hinting is applied to right sidebearing at this PPM.

Best regards,
Yuri


Subscribe: address@hidden
Unsubscribe: address@hidden
Set list to inactive: address@hidden
Set list to active: address@hidden
Message mode: address@hidden
Digest mode: address@hidden





Subscribe: address@hidden
Unsubscribe: address@hidden
Set list to inactive: address@hidden
Set list to active: address@hidden
Message mode: address@hidden
Digest mode: address@hidden

 

--- End Message ---

reply via email to

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