|
From: | Zhuyie |
Subject: | Re: A few questions about the new SDF render |
Date: | Tue, 6 Jul 2021 22:43:42 +0800 |
Hello Zhuyie,> 1. From the comments in ftsdf.c, [...]The implementation only supports single channel SDF. So the documentationfor ` FT_RENDER_MODE_SDF ` is correct. Thanks though, the comment mightneed some editing.> 2. Are there any tutorials about [...]The output is a pretty basic SDF, there is a comment on how to convert the outputvalues to unsigned pixel values (https://gitlab.freedesktop.org/freetype/freetype/-/blob/master/include/freetype/freetype.h#L3324).As for tutorial, you can use the `ftsdf` demo program implementation in the shaders.It should work exactly the same. https://gitlab.freedesktop.org/freetype/freetype-demos/-/blob/master/src/ftsdf.c#L598Thanks,Anuj
[Prev in Thread] | Current Thread | [Next in Thread] |