From: Johnathan G. <da...@us...> - 2002-04-06 23:29:51
|
daren 2002/04/06 14:25:34 PST Modified files: gamekernel/drivers/sdl SdlDriver.cpp SdlDriver.h Log: At long last, the SDL driver is now functional. There have been a few noteworthy changes... 1) The SDL driver DOES support repeating keyboard events. This works a lot better if a user tries to hold down a movement key to move forward, etc. 2) The SDL driver no longer sits and waits idly for messages. It will Poll devices for new events, and will continue to poll until all events have been handled. Pretty much it will loop doing this PollEvent, handle the event by changing the state of the kernel's input devices, call kernel->getInput()->update(), and then loop again until all queued events have been handled. Applications should be aware that more than one input device can change states before their onUpdate() function is called. 3) The flipside to no longer waiting idly for messages is that an applications onUpdate() and onDraw() functions can be called without any of the input devices changing states; ie, the user has not entered any input. These methods seem to work really well with aster; check it out! Revision Changes Path 1.10 +31 -19 lib/gamekernel/drivers/sdl/SdlDriver.cpp 1.8 +4 -4 lib/gamekernel/drivers/sdl/SdlDriver.h http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/isugamedev/lib/gamekernel/drivers/sdl/SdlDriver.cpp.diff?r1=1.9&r2=1.10&diff_format=h http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/isugamedev/lib/gamekernel/drivers/sdl/SdlDriver.h.diff?r1=1.7&r2=1.8&diff_format=h |