[SDL] SDL_GetKeyState - I am confused

Sam Lantinga slouken at devolution.com
Mon Sep 2 10:58:00 PDT 2002

> I always called SDL_GetKeyState every frame. Now someone asked on irc should he
> call it every frame, and SoM says: no. 

It is safe (and inexpensive) to call SDL_GetKeyState() every frame.
This is the correct way of doing it.

The current implementation uses a single internal array, and will continue
to do so for all SDL 1.2.x releases.

See ya,
	-Sam Lantinga, Software Engineer, Blizzard Entertainment

More information about the SDL mailing list