freetype
[Top][All Lists]
Advanced

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

Re: [Freetype] using a Stroker to make a glyph border pixmap


From: George Ogata
Subject: Re: [Freetype] using a Stroker to make a glyph border pixmap
Date: Sat, 10 Jul 2004 18:22:01 +1000
User-agent: Gnus/5.1006 (Gnus v5.10.6) XEmacs/21.4 (Reasonable Discussion, linux)

Werner LEMBERG <address@hidden> writes:

>> if my understanding is correct, the Stroker functions should enable me
>> to obtain a border of a glyph.  I've only found a couple of stroker
>> examples, and documentation seems rather scant.  It seems using
>> FT_Glyph_Stroke is the simplest way, but I can't understand why this
>> simple test program doesn't print out the border; it just prints the
>> normal glyph instead.  Can someone tell me what I'm doing wrong?
>
> Comparing with the stroker code in the ftview.c demo program, you are
> using FT_Get_Glyph before FT_Stroker_Set which means that the glyph
> outline has already been loaded before any stroking has been done.

So you suggest moving the FT_Stroker_Set call to before the
FT_Get_Glyph call?  Same result. :(

But as far as I can tell from the freetype source, FT_Stroker_Set
doesn't look at any glyphs, it just fills in the stroker struct and
does some associated housekeeping.  Further, FT_Glyph_Stroke needs a
glyph with an outline otherwise it wouldn't know what to stroke.  It
then copies the given glyph, swaps its outline with the stroked
outline, then substitutes the glyph you gave with the new glyph (hence
the argument is a `FT_Glyph *', not just `FT_Glyph').

Or am I misunderstanding something?





reply via email to

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