[HOpenGL] Re: rendering fonts with OpenGL

Felix Breuer felix at fbreuer.de
Fri Jul 15 05:21:47 EDT 2005


On Thu, 14 Jul 2005 19:56:47 +0200
Sven Panne <Sven.Panne at aedion.de> wrote:

> AFAIK, there is no Haskell binding for loading fonts and/or a FreeType 
> binding. Any volunteers?

Looking at the page you mentioned, FTGL might be the library one would want
to create bindings for: it handles font loading as well as rendering in all
its variants.

I have no experience whatsoever with creating bindings, but I might have a 
go at it, if you think it is a reasonably easy task. And if you are ready
for a flurry of questions regarding the HOpenGL bindings... I would start
working on it in about a month.

> If you are looking for high performance font rendering with current graphic 
> cards, by all means use texturing. This is what all mainstream cards that I 
> know of are optimized for, and it has a few nice benefits like scalability 
> and anti-aliasing. Using other techniques you easily end up waiting for the 
> loooong graphic pipelines to be flushed before you can "simply" do some 
> manipulations of the frame buffer. It can be very surprising if a simple 
> frames-per-second counter displayed in some corner of the screen drastically 
> reduces the FPS of your home-grown Quake-clone. Of course this has *never* 
> happened to me... ;-)

:)

So if performance does matter you recommend avoiding framebuffer
operations in general? I am thinking about how to display a clickable UI
in front of a 3D scene and, naively, I would have drawn pixmaps on top
of the scene using the framebuffer. If I try to do the same using texture
mapped polygons, what is the best setup/projection to make it look like
a flat window like UI? How to avoid perspective and blurring effects?

(Excuse my many OT questions, I am just curious. Feel free to ignore them.)


Thanks,
Felix


More information about the HOpenGL mailing list