[haiku-development] Re: Haiku Font Rendering

  • From: Ryan Leavengood <leavengood@xxxxxxxxx>
  • To: "haiku-development@xxxxxxxxxxxxx" <haiku-development@xxxxxxxxxxxxx>
  • Date: Sat, 10 Aug 2019 11:20:40 -0400

On Sat, Aug 10, 2019 at 9:24 AM Axel Dörfler <axeld@xxxxxxxxxxxxxxxx> wrote:


I can show you a screenshot of Windows 10 with a lot more color fringes.
If you have to zoom in to see the fringes, there is no problem -- that's
how they are supposed work :-)

Subpixel will always do color fringing, I agree, but the alpha
correction can make it blend better. The font I picked seemed to be a
particularly bad case for the m because it is so narrow.

From the screenshot above, I think the Haiku rendering looks a lot
clearer and sharper.

Using MacBooks for many years has moved my taste into the "slightly
blurry" camp I suppose, and I recognize that this is all very much up
to the tastes of the user, and what they are accustomed to. But I
think we can probably make some better defaults and generally improve
the Haiku font rendering and also provide users the ability to tweak
things a bit for their taste.

The Ubuntu one doesn't seem to use hinting, only
sub-pixel rendering -- that's not a good comparison.

I opened up gnome-tweak tool and start changing some font settings and
got some interesting results, but mostly ugly ones. I am on my Mac at
the moment but I believe the default Ubuntu settings for 16.04 LTS
(which is what I am using) is slight hinting and subpixel rendering.
For many years Ubuntu was one of the only distros that enabled the
"patented" FreeType subpixel rendering which is why they always had
better looking fonts than other distros (and Haiku IMO.)

I am also very spoiled from years of using high DPI screens on my
laptops, tablets and phone. I will probably always view lower DPI
screens as looking bad, but I still think we can do some things to
make them look as good as they can. But even High DPI screens still
can use some subpixel rendering, and I believe macOS does based on
looking at text zoomed in.

I am reading the FreeType docs now and emailed Stephan for some
advice. I can also see what other libraries like Cairo do. I plan to
experiment with using FreeType directly in an app until I get a good
result then can figure out how to do that in app_server. Stephan
implied in an old mailing list post that it is certainly possible for
Haiku to do the subpixel positioning like in that old AGG font article
[1]. Getting something like that working is my goal. Obviously if
anyone reading this has suggestions or advice I appreciate it. But I
know everyone is pretty busy these days.

1. Sadly this is only on archive.org at the moment:
https://web.archive.org/web/20190114135327/http://antigrain.com/research/font_rasterization/

-- 
Regards,
Ryan

Other related posts: