freetype
[Top][All Lists]
Advanced

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

回复: Question about zero render issue


From: Yi tiger
Subject: 回复: Question about zero render issue
Date: Thu, 22 Apr 2021 01:13:53 +0000

Alexei & Werner,

Your comments really solved my question, thank you very much.

Thanks,
Tiger

发送自 Windows 10 版邮件<https://go.microsoft.com/fwlink/?LinkId=550986>应用

发件人: Alexei Podtelezhnikov<mailto:apodtele@gmail.com>
发送时间: 2021年4月21日 23:35
收件人: freetype@nongnu.org<mailto:freetype@nongnu.org>; 
yitiger@hotmail.com<mailto:yitiger@hotmail.com>
主题: Re: Question about zero render issue

You can add this to mimic Adobe for this glyph

> error = FT_Load_Glyph(pFTFace, 3, FT_LOAD_DEFAULT);

   pFTFace->glyph->outline.flags |= FT_OUTLINE_EVEN_ODD_FILL;

> error = FT_Get_Glyph(pFTFace->glyph, &glyph);
> FT_Glyph_To_Bitmap(&glyph, FT_RENDER_MODE_NORMAL, 0, 1);

As Werner said, this is a matter of wrong contour orientation. Adobe
likely utilizes the even-odd winding rule at this size whereas
FreeType always defaults to the non-zero rule. Note that the even-odd
rule might have been expected in the old PostScript fonts, but
presently it will cause a lot of pain with modern variation fonts, and
TrueType in general.

Alexei


reply via email to

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