How could keyboard or some other event generated by the hardware device go to SDL_EventQ and thus these events can be received by SDL_PeepEvent functions?
I have look through SDL source code, but can’t find the code!
How could keyboard or some other event generated by the hardware device go to SDL_EventQ and thus these events can be received by SDL_PeepEvent functions?
I have look through SDL source code, but can’t find the code!
Take a look at SDL_PumpEvents(). Work out from there.
The outline of an answer is that the operating system handles the
hardware event and passes it off to the windowing system. SDL talk to
the windowing system to get the event and converts it to its own format
and puts it in the SDL event queue. All told the event may sit in
several different queues in several different formats before it gets put
in the SDL event queue.
Bob PendletonOn Thu, 2004-05-27 at 06:10, higsn wrote: