Hey,
From my experience as a game programmer, if you are designing a game that's fullscreen, you shouldn't ever worry about the CPU usage, considering there won't be any other programs in use while it's running. If you really feel you need a delay, use SDL_Delay( 1 ) which will give up the smallest timeslice available, while still giving your program the most attention. Again, I can never stress enough that if you are making a fullscreen game, you should never
need a delay
Alex
On Feb 8, 2008 5:22 PM, Solra Bizna <
sbizna@...> wrote:
On Feb 8, 2008 10:55 AM, Alvin <
alvinbeach@...> wrote:
> Have a look at SDL_WaitEvent() and see if it fits into your program. If you
> aren't sure, can you post an example of how you read/poll the events?
IMO, there's a pretty major gap in functionality between WaitEvent and
PollEvent. Carbon's WaitNextEvent has a timeout that you can set
appropriately, what we need is something like that for SDL. (Aside
from Edward's use case, events may not be the only thing the app wants
to block on.)
-:sigma.SB
_______________________________________________
SDL mailing list
SDL@...
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org