freetype
[Top][All Lists]
Advanced

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

Re: [Freetype] More Info On Direct Rendering?


From: Peter Montgomery
Subject: Re: [Freetype] More Info On Direct Rendering?
Date: Tue, 14 May 2002 16:00:51 -0700

Chris,

> So far things have gone well using the demo applications code you
provide
> to guide us, specifically ftview and ftstring, but I now need to
> investigate producing coloured AA text.

Someone else just answered another question earlier with the same answer
I'm about to give you: Take the AA bitmap you get from FreeType and use
it as an alpha channel.  If your application uses a planar
configuration, then simply providing FreeType a pointer to the start of
the alpha channel as the location to build the AA bitmap will solve your
problem simply.  If your app uses non-multiplied values, then you're
done.  If it needs pre-multiplied values, then you have to step through
the RGB value and multiply them by the value of alpha at each pixel.
If your app uses a contiguous memory format, then you'll have to take
the AA bitmap and copy it pixel by pixel into the alpha channel.

    Thanks,
    PeterM




reply via email to

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