diff --git a/SDL2pp/SDL.cc b/SDL2pp/SDL.cc index 7ed8815..d63f0a8 100644 --- a/SDL2pp/SDL.cc +++ b/SDL2pp/SDL.cc @@ -35,4 +35,17 @@ SDL::~SDL() { SDL_Quit(); } +Uint32 WasInit(Uint32 flags) { + return SDL_WasInit(flags); +} + +void InitSubsystem(Uint32 flags) { + if (SDL_InitSubSystem(flags) != 0) + throw Exception("SDL_InitSubsystem failed"); +} + +void QuitSubSystem(Uint32 flags) { + SDL_QuitSubSystem(flags); +} + } diff --git a/SDL2pp/SDL.hh b/SDL2pp/SDL.hh index cb5edb0..cd63bb6 100644 --- a/SDL2pp/SDL.hh +++ b/SDL2pp/SDL.hh @@ -35,6 +35,10 @@ public: SDL(SDL&& other) = delete; SDL& operator=(const SDL& other) = delete; SDL& operator=(SDL&& other) = delete; + + Uint32 WasInit(Uint32 flags); + void InitSubSystem(Uint32 flags); + void QuitSubSystem(Uint32 flags); }; }