freetype-devel
[Top][All Lists]
Advanced

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

Re: [ft-devel] Turning off stem darkening by default until all drivers s


From: Nikolaus Waxweiler
Subject: Re: [ft-devel] Turning off stem darkening by default until all drivers support it?
Date: Tue, 10 Nov 2015 09:24:33 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0

I'm also running Jan's patch and have disabled stem darkening. And I think this approach is actually a good idea.

1. Fontconfig's hintslight is translated to FT_LOAD_TARGET_LIGHT by cairo and probably also Qt. And so far, hintslight meant the autohinter regardless of the "autohint" property. Changing the meaning of FT_LOAD_TARGET_LIGHT to "Use native Y-only-snapping with linear advances if driver and font supports it and Y-only autohinter with linear advances otherwise" would restore orthogonality to the hintstyle property. This also means that no code has to be changed or ripped out to support the above meaning while still delivering consistent rendering across fonts and font formats. Medium/Full then wouldn't change anything for CFF fonts but would trigger ClearType rendering without linear advances or with backwards-compatible X-and-Y-snapping.

I noticed that Liberation Sans/Serif/Mono and Open Sans looked pretty ClearType-y with hintfull but I wasn't sure about the advance widths. Is there any way to detect this from within FT_Load_Glyph or something so that native ClearType fonts with linear advance widths can be send to the native hinter?

2. I think it might be best to disable stem darkening for now when including Jan's patch (my suggestion) for the sake of consistent rendering. My planned blog post would still stand, I'd just call them experimental features and work on refactoring stem darkening support in the future.

Ideally, could this be controlled by an optional FT_LOAD_STEM_DARKENING flag to FT_Load_Glyph? So when Qt5/Skia/etc. decide to ship with LAB+GC, they can just look for the flag in FreeType and enable it, otherwise proceed like before. This would lessen the need to coordinate a FreeType release, a toolkit/rendering library release and the packaging of them...


Conclusion: Let's change FT_LOAD_TARGET_LIGHT and disable stem darkening for now!



reply via email to

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