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

Re: [pygame] win32ui?



On 9/14/06, Alex Holkner <aholkner@xxxxxxxxxxxxxx> wrote:
Certainly not by getting the OS to draw font bitmaps.  The standard
technique is to render the characters you need to a texture (using
pygame.font or SDL_ttf, for example), and rendering screen-aligned quads
of the textures.  pyglyph
(http://www.partiallydisassembled.net/pyglyph/) is a module that does
exactly this.

There is also the approach of drawing font outlines, basically as
polygons. It doesn't usually turn out as well as caching bitmaps of
fonts, but glut does have a routine that can do that (for a fixed
font, not a ttf, but it's interesting nonetheless & fairly simple to
use)

glutStrokeCharacter