freetype-devel
[Top][All Lists]
Advanced

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

[ft-devel] Autohinter: stem darkening, first rough prototype


From: Nikolaus Waxweiler
Subject: [ft-devel] Autohinter: stem darkening, first rough prototype
Date: Sun, 23 Aug 2015 18:00:00 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.1.0

Hi list,
so I just finished a very rough prototype for stem darkening for the autohinter. This is not meant for inclusion into master but rather as a starting point for discussion. Apply patch against master.

The code has numerous problems:
1. The function to compute how much darkening to apply is a crude copy-pasta of the real thing in cff/cf2font.c 2. I haven't tried to suppress all code paths that deal with emboldening when no-stem-darkening is set. 3. Getting at the necessary stdVW proved tricky, since there isn't just one number somewhere that I can use. Each time a glyph is to be displayed, a different writing system/script analyzer could run producing different widths. The first few glyph-indices in SourceSansPro-R for example prompt the CJK-analyzer for whatever reason. I worked around this by simply using the biggest width any analyzer produces, because in my limited testing, that value usually wasn't far off the mark. 4. There is a definitive performance hit. Using 'ftview 16 VL-Gothic-Regular.ttf' and keeping the down-key pressed to eventually render all of its' 16713 glyphs is quite smooth without hinting but very sluggish with the emboldening autohinter. Much less so without emboldening. 5. The results look crappy without gamma correction ;) Use the pixman patch in the other thread if you want to give it a test drive in real-world-apps like Firefox.

Please have a look and tell me what you think :)

Best regards,
Nikolaus



reply via email to

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