freetype-devel
[Top][All Lists]
Advanced

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

Re: [ft-devel] glyph metrics don't match bitmap size (2.8.1)


From: Alexei Podtelezhnikov
Subject: Re: [ft-devel] glyph metrics don't match bitmap size (2.8.1)
Date: Tue, 19 Sep 2017 09:48:09 -0400

On Tue, Sep 19, 2017 at 2:44 AM, Nicolas Jinchereau
<address@hidden> wrote:
> I scraped some code from ft_smooth_render_generic in ftsmooth.c.
>...
> Aside from those two things, it seems to work, and the example below gives
> matching results for precalculated and final size of the bitmap.

I hope you realize that text layout is more complex than just stacking
bitmaps side by side. There could be gaps and overlaps between
bitmaps. For example, the padded LCD bitmaps do overlap more often.

Skia is also doing the bitmap preallocation and borrows the code from
FreeType to calculate the size. Just like you, they now need to fix
this API-non-compliant interface with FreeType when FreeType's
technology has evolved. Do you see the problem? On my side, I don't
quite understand why this preallocation is beneficial. Can you please
explain the advantages? Perhaps we might consider some tweaks to
FreeType API if it is indeed compelling.

Thank you,
Alexei



reply via email to

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