fontations icon indicating copy to clipboard operation
fontations copied to clipboard

missing pixels in truetype non antialiased fonts

Open fanoush opened this issue 5 months ago • 6 comments

Hello, since Chrome moved to fontations in version 136 truetype fonts are broken when font antialiasing is turned off. Here is screenshot how it looks now

Image

tab title font is Tahoma and monotype font is Courier New. This basically happens in all fonts installed by ttf-mscorefonts-installer package in ubuntu/debian (Courier New, TimesNew Roman, Arial, ...)

related chromium bug is tracked here https://issues.chromium.org/issues/404881585

the original gentoo topic is here https://forums.gentoo.org/viewtopic-p-8862929.html?sid=99f37ed89d19ea4e9b96c2fa90ddd461

fanoush avatar Aug 03 '25 12:08 fanoush

It seems like TrueType dropout control is not implemented?

jenskutilek avatar Aug 05 '25 09:08 jenskutilek

It seems like TrueType dropout control is not implemented?

Fontations doesn't have a rasterizer itself. Dropout control is a technique implemented in a scanline mono rasterizer. A relic of the far past I would say... But that's just me.

behdad avatar Aug 05 '25 20:08 behdad

Fontations doesn't have a rasterizer itself. Dropout control is a technique implemented in a scanline mono rasterizer.

Sorry, I don't understand technical details but the readme https://github.com/googlefonts/fontations?tab=readme-ov-file#structure says

skrifa is a mid level library that provides access to various types of metadata contained in a font as well as support for loading glyph outlines. It's primary purpose is to replace FreeType in Google applications.

So does it belong to skrifa? It worked with FreeType before it was replaced by it.

fanoush avatar Aug 08 '25 12:08 fanoush

I have checked freetype and something is described here https://freetype.org/freetype2/docs/reference/ft2-outline_processing.html#ft_outline_xxx "By default, the scan converter will try to detect drop-outs in an outline and correct the glyph bitmap to ensure consistent shape continuity."

So which " scan converter" component does this "Outline Processing" part with Fontations?

fanoush avatar Aug 08 '25 12:08 fanoush

Perhaps, one could come up with a clever technique for gray to mono conversion without the legacy dropout control, something a little more clever than just thresholding at an arbitrary coverage, something based on local extrema.

apodtele avatar Aug 12 '25 17:08 apodtele

It seems like TrueType dropout control is not implemented?

Fontations doesn't have a rasterizer itself. Dropout control is a technique implemented in a scanline mono rasterizer. A relic of the far past I would say... But that's just me.

It may seem a relic of the past to you, it's a highly appreciated choice for many FullHD laptop screen owners.

I, too, configure my Desktop fonts for a perfectly hinted ms-ttcore font without anti-aliasing (monochrome rendering) for my daily driver fonts. I was hoping to have this reflected in Chrome for the time to come, also after fontations.

As of Chrome 142.0.7444.59, the hinted non-anti-aliased monochrome setting of my desktop is now completely ignored by fontations, so fonts are rendered aliased and therefor look blurry to my taste (yes, it's also about taste).

Please make FreeType an option again.

mrvanes avatar Nov 01 '25 14:11 mrvanes

Could be related to this https://issues.chromium.org/issues/415705460

magist3r avatar Nov 19 '25 14:11 magist3r