Wiki Page Content

Differences between revisions 3 and 4
Revision 3 as of 2010-06-24 22:19:41
Size: 410
Editor: SheenaSmith
Comment: update formatting
Revision 4 as of 2010-06-28 23:43:17
Size: 1382
Editor: SheenaSmith
Comment: add content from old wiki
Deletions are marked like this. Additions are marked like this.
Line 14: Line 14:
Event handling allows your application to receive input from the user. Event handling is initialized (along with video) with a call to:

 {{{
SDL_Init(SDL_INIT_VIDEO);
}}}
 (''see'' [[http://wiki.libsdl.org/moin.cgi/CategoryInit|Initialization & Shutdown]] and [[SDL_Init]]() ''for details'')

Internally, SDL stores all the events waiting to be handled in an event queue. Using functions like [[SDL_PollEvent]](), [[SDL_PeepEvents]]() and [[SDL_WaitEvent]]() you can observe and handle waiting input events.

The key to event handling in SDL is the SDL_Event union. The event queue itself is composed of a series of SDL_Event unions, one for each waiting event. SDL_Event unions are read from the queue with the [[SDL_PollEvent]]() function and it is then up to the application to process the information stored with them.

<<Color2(green,There is currently no page for SDL_Event. Should one be created or should additional information be included here?)>>

DRAFT

Event Handling

Include File(s): SDL_events.h

Introduction

Event handling allows your application to receive input from the user. Event handling is initialized (along with video) with a call to:

Internally, SDL stores all the events waiting to be handled in an event queue. Using functions like SDL_PollEvent(), SDL_PeepEvents() and SDL_WaitEvent() you can observe and handle waiting input events.

The key to event handling in SDL is the SDL_Event union. The event queue itself is composed of a series of SDL_Event unions, one for each waiting event. SDL_Event unions are read from the queue with the SDL_PollEvent() function and it is then up to the application to process the information stored with them.

green

Functions


CategoryCategory

None: CategoryEvents (last edited 2014-03-10 18:53:46 by nairou)

(Page Info.)
Feedback
Please include your contact information if you'd like to receive a reply.
Submit