|
Size: 196
Comment: create page, add content
|
Size: 1439
Comment: update formatting - categories
|
| Deletions are marked like this. | Additions are marked like this. |
| Line 5: | Line 5: |
| ||<tablewidth="100%" style="color: #FF0000;" :> DRAFT|| | |
| Line 6: | Line 7: |
| == Event Handling (SDL_events.h) == | = Event Handling = |
| Line 8: | Line 9: |
| <<FullSearch(category:CategoryEvents)>> | '''Include File(s):''' [[http://hg.libsdl.org/SDL/file/68dfd6df47da/include/SDL_events.h|SDL_events.h]] <<TableOfContents()>> == Introduction == 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. == Enumerations == <<FullSearch(category:CategoryEnum CategoryEvents)>> == Structures == <<FullSearch(category:CategoryStruct CategoryEvents)>> == Functions == <<FullSearch(category:CategoryEvents -CategoryEnum -CategoryStruct)>> |
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:
SDL_Init(SDL_INIT_VIDEO);
(see 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.
Enumerations
Structures
- SDL_AudioDeviceEvent
- SDL_ControllerAxisEvent
- SDL_ControllerButtonEvent
- SDL_ControllerDeviceEvent
- SDL_DollarGestureEvent
- SDL_DropEvent
- SDL_Event
- SDL_Finger
- SDL_JoyAxisEvent
- SDL_JoyBallEvent
- SDL_JoyButtonEvent
- SDL_JoyDeviceEvent
- SDL_JoyHatEvent
- SDL_KeyboardEvent
- SDL_MouseButtonEvent
- SDL_MouseMotionEvent
- SDL_MouseWheelEvent
- SDL_MultiGestureEvent
- SDL_QuitEvent
- SDL_SensorEvent
- SDL_SysWMEvent
- SDL_TextEditingEvent
- SDL_TextInputEvent
- SDL_TouchFingerEvent
- SDL_UserEvent
- SDL_WindowEvent
- SGStructures
Functions
- SDL_AddEventWatch
- SDL_DelEventWatch
- SDL_EventState
- SDL_FilterEvents
- SDL_FlushEvent
- SDL_FlushEvents
- SDL_GetEventFilter
- SDL_GetEventState
- SDL_GetNumTouchDevices
- SDL_GetNumTouchFingers
- SDL_GetTouchDevice
- SDL_GetTouchFinger
- SDL_HasEvent
- SDL_HasEvents
- SDL_LoadDollarTemplates
- SDL_PeepEvents
- SDL_PollEvent
- SDL_PumpEvents
- SDL_PushEvent
- SDL_QuitRequested
- SDL_RecordGesture
- SDL_RegisterEvents
- SDL_SaveAllDollarTemplates
- SDL_SaveDollarTemplate
- SDL_SetEventFilter
- SDL_WaitEvent
- SDL_WaitEventTimeout
