freetype
[Top][All Lists]
Advanced

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

Re: [ft] FT_Outline_Get_Orientation vs FT_OUTLINE_REVERSE_FILL


From: Werner LEMBERG
Subject: Re: [ft] FT_Outline_Get_Orientation vs FT_OUTLINE_REVERSE_FILL
Date: Thu, 08 Mar 2007 07:25:52 +0100 (CET)

> [...] the FT_OUTLINE_REVERSE_FILL which IS supported in 2.1.4. Then
> I started debugging my program, and I found that
> FT_Outline_Get_Orientation is returning 0 for both Truetype and Type
> 1 fonts, but FT_OUTLINE_REVERSE_FILL is set to 0 for Truetype and 1
> for Type 1.

Today, the importance of this flag has diminished.  FreeType no longer
uses it, as far as I can see in the code.  It's thus basically an
information for the user which orientation the font is *supposed* to
use, depending on the font format.

> So my question is, what is the relationship between the outline
> winding direction, FT_Outline_Get_Orientation, and
> FT_OUTLINE_REVERSE_FILL? Any information most appreciated.  I
> probably won't end up supporting older versions of Freetype, but I
> would like to know exactly how these things interact.

It has been shown that some fonts don't use the correct orientation as
specified in the specs (probably due to broken font creation tools).
For this reason, FreeType has started to check for the orientation of
each outline separately.  The current version of FreeType implements
an algorithm which uses the nonzero winding rule to find the inner and
outer part of an outline -- this works independently of the outline's
orientation.


    Werner




reply via email to

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