Dumb question - How to clear the screen?

I don’t know how to clear the screen in SDL after rendering an image.

In an OpenGL scene (which I don’t intend to use in this case) you use glClear(blah);

How do I do this with SDL?

Winner of the 2003 Internet Service Providers’ Association awards for Best Unmetered ISP and Best Consumer Application.

SDL_FillRect(surface, NULL, SDL_MapRGB(surface->format, RED, GREEN, BLUE));

And then, of course, update the screen with SDL_UpdateRect() or

Good luck!

-bill!On Wed, Jun 25, 2003 at 01:38:02PM +0200, gpa at fsmail.net wrote:

How do I do this with SDL?

bill at newbreedsoftware.com Got kids? Get Tux Paint!
http://newbreedsoftware.com/bill/ http://newbreedsoftware.com/tuxpaint/