freetype
[Top][All Lists]
Advanced

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

Re: Issue rendering fonts with fixed sizes


From: Lawrence D'Oliveiro
Subject: Re: Issue rendering fonts with fixed sizes
Date: Thu, 26 Nov 2020 14:22:44 +1300

On Wed, 25 Nov 2020 17:05:38 -0800, stephan@unity3d.com wrote:

> I am currently testing with the NotoColorEmoji.ttf font.

I just did some rendering with this exact same font.

> // Setting the pixel size returns no error since 109 is a size
> supported by this font.
> 
> m_Error = FT_Set_Pixel_Sizes(m_Face, 109, 109);

Try FT_Select_Size with an index into the available-sizes table
instead. Since Noto Color Emoji only comes in one size, an index of 0
should work.

In my example
<https://github.com/ldo/harfpy_examples/blob/master/region-flags>, I
found it easier to use a graphics engine like Cairo to take care of the
font-sizing headaches for me.

The output from that program can be seen here
<https://www.deviantart.com/default-cube/art/Region-Flags-861126407>.



reply via email to

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