freetype-devel
[Top][All Lists]
Advanced

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

Re: [ft-devel] contour orientation


From: Hin-Tak Leung
Subject: Re: [ft-devel] contour orientation
Date: Tue, 1 Nov 2016 21:21:00 +0000 (UTC)

Hi Alexei,

Thanks for the notes on gulim.ttc . Indeed there are piles of mis-oriented 
contours.
Obviously Microsoft didn't bother fixing issues flagged by their own tool :-).

Yes, FontVal checks for mis-oriented contours. It is the first listed error code
within the glyf table tests (E1110).

All the errors codes which FontVal emits are, with the exception of glyf-tests 
related ones:
(there are about 800 - organized by table: {EWIP}nnmm, nn for one of the 
tables, 60 for hinting)
https://github.com/HinTak/Font-Validator/blob/embedding-ironpython/GenerateFValData/OurData.xml

Those of the glyf tests, are in
https://github.com/HinTak/Font-Validator/blob/embedding-ironpython/Glyph/NS_Glyph.GErrStrings.resx

The hinting related ones are {EWIP}60nn in the main. There are E6001-E6059, 
W6000-6012, 72 of them.
(and I6059 for 'not checking cff hinting' and P6000 for 'pass', i.e lacking any 
of E/W/I's).
The glyf tables test contains about 25(?) but AFAIK one of them, A1113, is 
historical and not used by current code.

Oh, the contour/glyf table test is entirely in C#, and outside, and independent 
of FreeType; and it is also open-sourcced, unlike the hinting part.

Out of the 72 from the hinting/rasterization tests, I have only seen about 40 
error codes with a real font file; so I have no idea how many of them are 
historical.
With FontVal 2.0's FreeType backend, I used 54 of those; my current dev code 
uses 64 plus another 9 new FreeType-specific ones. There are 8 error codes
which I haven't used, either because the description is too vague, or would 
take a lot of modification in FreeType (such as Maths overflow in 
ADD/SUB/MUL/DIV  - FreeType seems to either clamp to max/min or let downstream 
deal with wrong values).

Incidentally, I am about 1/3 way through throwing about 14000 fonts from the 
early 90's from one of those dodgy font sites at the old backend to see if I 
can clarify what that 8 means. So far I have only managed to get a few more 
cases of broken fonts for a few error codes I implemented without test files, 
so it is still good to do, though it has taken a whole day to run 1/3 of it.

I wish there is a font-fuzzing tool :-).  

Hin-Tak

--------------------------------------------
On Tue, 1/11/16, Alexei Podtelezhnikov <address@hidden> wrote:

 Hi Hin-Tak,
 
 Does Font Validator check the contour orientations? If you
 are looking
 a font with plenty of contours with wrong orientations,
 there is
 gulim.ttc of Windows.
 
 Thank you,
 Alexei
 
 -- 
 Alexei A. Podtelezhnikov, PhD
 


reply via email to

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