freetype-devel
[Top][All Lists]
Advanced

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

Re: [ft-devel] Weird behaviour in FT_Glyph_StrokeBorder


From: Foaly
Subject: Re: [ft-devel] Weird behaviour in FT_Glyph_StrokeBorder
Date: Wed, 24 Jan 2018 14:43:58 +0100
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.11; rv:52.0) Gecko/20100101 Thunderbird/52.5.2

Hello and thank you for your response!

SFML offers drawing outlines around texts. The current implementation
uses FT_Glyph_Stroke. As you can see in the picture (Hello #4) a glyph
with a transarent color the outline is not only outside the glyph, but
also inside the glyph bounds. Some users complained about it, so we
thought about fixing it by using FT_Glyph_StrokeBorder with inside =
false. According to the documentation this should give us an outline
along the outside on the glyph only. From the pictures you can see that
the FT_Glyph_StrokeBorder creates outside outline AND also fills the
complete glyph (compare the red tones between the first and third hello).

Now my question was if this is intended or a bug.

Thank you,
Foaly

P.S: I attached a (bad) GIMP picture of what I would expect the result
to look like.


Am 23.01.18 um 21:29 schrieb Alexei Podtelezhnikov:
> On Tue, Jan 23, 2018 at 12:21 PM, Foaly <address@hidden> wrote:
>> This is Foaly and I am contributor to the SFML library. We want to change
>> our implementation of outlines from using FT_Glyph_Stroke to
>> FT_Glyph_StrokeBorder, which according to the documentation allows to get an
>> outline only outside the glyph.
> FT_Glyph_StrokeBorder is not tested regularly, so there could be bugs.
> The inside border is trickier than than the outside one: there is
> limited space inside to perform the operation gracefully. You might be
> seeing this effect, which is very hard to fix. Most of your pictures
> are beautiful though. Please explain your goals in more detail.

Attachment: desired_result.png
Description: PNG image


reply via email to

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