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

Re: [pygame] pygame.error: SDL_ttf render failed



On Tue, 2006-07-25 at 08:04 -0600, Joseph Quigley wrote:
>     orig = font.render(message, 0, fontcolor)
> pygame.error: SDL_ttf render failed
> 
> When text is displayed on the hud it is supposed to fade out but the
> game crashes and displays this error instead. I have no idea how this
> happened because the game used to work fine one day and the next it
> began to crash.

Try turning on the antialiasing? I've seen cases where the smoothed font
rendering works but the simple fails. This is some problem with SDL_ttf
or freetype.

> One other issue I have noticed is that pygame.init() takes forever to
> load (whether solar wolf or some of the pygame demos).

This is probably from SDL trying to probe the different sound and video
backends. It's usually fast, but it is finding some sort of partial
match that slows it down. Try setting the environment vars
SDL_VIDEODRIVER and SDL_AUDIODRIVER to the modes you are using. 
http://www.libsdl.org/cgi/docwiki.cgi/SDL_5fenvvars