[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [ft-devel] [patch] emboldening rework v1
From: |
Behdad Esfahbod |
Subject: |
Re: [ft-devel] [patch] emboldening rework v1 |
Date: |
Tue, 10 Apr 2012 11:54:12 -0400 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686 (x86_64); en-US; rv:1.9.2.28) Gecko/20120306 Thunderbird/3.1.20 |
On 04/09/2012 09:23 PM, Alexei Podtelezhnikov wrote:
> In memory of Paul Alexi
>
> As a way of ping, I going to throw in a much simpler
> FT_Outline_Get_Orientation patch. So the whole collection of three
> patches now looks like the attached. Comments, suggestions?
I like the area-based algorithm. I had to implement outline orientation code
recently and I wish I had remembered that algorithm!
What I found in testing my implementation was that fonts don't have consistent
contour orientation. From what I understand:
- TrueType fonts have even-odd fill rule and fill-right orientation,
- Type1 fonts have zero-winding fill rule and fill-left orientation.
Now *if* TrueType outlines are really fill-right, then even-odd and
zero-winding rules are the same. But I've came across many fonts where
TrueType outlines are even-odd, not fill-right. I'm guessing that you want to
return ORIENTATION_NONE in those cases. But finding them is not easy with
your algorithm.
Maybe we don't care really.
What I ended up doing was implement both even-odd rule and winding rule and
compare the results. I was doing this on arc splines though, not Beziers.
behdad
- Re: [ft-devel] [patch] emboldening rework v1, (continued)
- Re: [ft-devel] [patch] emboldening rework v1, Alexei Podtelezhnikov, 2012/04/10
- Re: [ft-devel] [patch] emboldening rework v1, Alexei Podtelezhnikov, 2012/04/18
- Re: [ft-devel] [patch] emboldening rework v1, Behdad Esfahbod, 2012/04/18
- Re: [ft-devel] [patch] emboldening rework v1, Werner LEMBERG, 2012/04/18
- Re: [ft-devel] [patch] emboldening rework v1, Alexei Podtelezhnikov, 2012/04/19
- Re: [ft-devel] [patch] emboldening rework v1, Behdad Esfahbod, 2012/04/19
- Re: [ft-devel] [patch] emboldening rework v1, Alexei Podtelezhnikov, 2012/04/20
- Re: [ft-devel] [patch] emboldening rework v1, Behdad Esfahbod, 2012/04/24
- Re: [ft-devel] [patch] emboldening rework v1, Alexei Podtelezhnikov, 2012/04/24
- Re: [ft-devel] [patch] emboldening rework v1, Behdad Esfahbod, 2012/04/24
Re: [ft-devel] [patch] emboldening rework v1,
Behdad Esfahbod <=
- Re: [ft-devel] [patch] emboldening rework v1, Alexei Podtelezhnikov, 2012/04/10
- Re: [ft-devel] [patch] emboldening rework v1, Behdad Esfahbod, 2012/04/10
- Re: [ft-devel] [patch] emboldening rework v1, Alexei Podtelezhnikov, 2012/04/12
- [ft-devel] On contour directions and fill rules (was Re: [patch] emboldening rework v1), Behdad Esfahbod, 2012/04/19
- Re: [ft-devel] On contour directions and fill rules, Werner LEMBERG, 2012/04/19
- Re: [ft-devel] On contour directions and fill rules, Behdad Esfahbod, 2012/04/19
- Re: [ft-devel] On contour directions and fill rules, Werner LEMBERG, 2012/04/20
- Re: [ft-devel] On contour directions and fill rules, Behdad Esfahbod, 2012/04/20
- Re: [ft-devel] On contour directions and fill rules, Werner LEMBERG, 2012/04/23