Re: Canvas change in gnome 1.2 (helix)



>  Because of font brokenness.   I'm halfway through making a freetype based
>  gnome-canvas-aa widget.  You've welcome to my partial code.  

Wow, this is awesome!  Where can we look at your code?

>  Incidently, is there a recommended way to do pure antialiased pixmaps?  I
>  want to render a single channel alpha only buffer with a given rgb colour
>  onto the back buffer.  Currently I'm cheating and filling a gdk-pixbuf
>  (rgba) with a flat colour and copying the alpha into the bpixbuf's alpha
>  channel.  This is slow because I have to write to a pure 1 channel
>  buffer(because freetype prefers that), copy that to the gdk-pixbuf, fill
>  in the rgb components, which then get copied to the gnome-canvas back
>  buffer, which then gets copied to the X screen buffer.  Clearly the middle
>  stages are superfluous.

Just render the mask with Freetype and then composite it to the
GnomeCanvasBuf by hand.  The libart code has an example of how to do
fast pixel-by-pixel compositing of a solid color.  Please tell us if
you need help with this.

Can Freetype give you horizontal spans of where the pixels for a
rendered font are turned on?  We could then use horizontal lines to
draw nice scaled fonts on the Gdk canvas.

Having a Freetype-based text item would be awesome.  Thanks a *lot*
for doing this work!

  Federico




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