Function wasInit
Wraps SDL_WasInit which checks whether particular subsystem(s) is already initialized
bool wasInit
(
bool timer = false,
bool audio = false,
bool video = false,
bool joystick = false,
bool haptic = false,
bool gameController = false,
bool events = false,
bool everything = false,
bool noParachute = false,
bool sensor = false
) @trusted;
Parameters
| Name | Description |
|---|---|
| timer | selects the SDL_INIT_TIMER subsystem |
| audio | selects the SDL_INIT_AUDIO subsystem |
| video | selects the SDL_INIT_VIDEO subsystem |
| joystick | selects the SDL_INIT_JOYSTICK subsystem |
| haptic | selects the SDL_INIT_HAPTIC subsystem |
| gameController | selects the SDL_INIT_GAMECONTROLLER subsystem |
| events | selects the SDL_INIT_EVENTS subsystem |
| everything | selects the SDL_INIT_EVERYTHING subsystem |
| noParachute | selects the SDL_INIT_NOPARACHUTE subsystem |
| sensor | selects the SDL_INIT_SENSOR subsystem (from SDL 2.0.9) |
Returns
true if the selected subsystem(s) is initialized, otherwise false
Example
dsdl .init();
assert(dsdl .wasInit(video : true) == true);