Initialization routines
init() simply calls SDL_Init() to initialize only the video
subsystem. If the call fails, SDLError is raised. See
pygame for a comparison between this function and
pygame.init().
API
- exception sdl2.ext.SDLError(msg=None)[source]
An SDL2 specific
Exceptionclass. if no msg is provided, the message will be set to the value ofsdl2.error.SDL_GetError()
- sdl2.ext.init() None[source]
Initialises the underlying SDL2 video subsystem. Raises a
SDLError, if the SDL2 video subsystem could not be initialised.
- sdl2.ext.quit() None[source]
Quits the underlying SDL2 video subysystem. If no other SDL2 subsystems are active, this will also call
quit(),sdl2.sdlttf.TTF_Quit()andsdl2.sdlimage.IMG_Quit().