cocos.audio.SDL package

Module contents

Main module for importing SDL-ctypes.

This module defines the intialization and cleanup functions:
  • SDL_Init

  • SDL_InitSubSystem

  • SDL_WasInit

  • SDL_QuitSubSystem

  • SDL_Quit

It also imports all functions, constants and classes from the package submodules. Typical usage, then, is to just import this module directly into your namespace:

from SDL import *

This gives you access to all SDL names exactly as they appear in the C header files.

group Non-core modules

ttf, mixer, image, sound

SDL_Init(flags)

Initialise the SDL library.

This function loads the SDL dynamically linked library and initializes the subsystems specified by flags (and those satisfying dependencies) Unless the SDL_INIT_NOPARACHUTE flag is set, it will install cleanup signal handlers for some commonly ignored fatal signals (like SIGSEGV).

The following flags are recognised:

  • SDL_INIT_TIMER

  • SDL_INIT_AUDIO

  • SDL_INIT_VIDEO

  • SDL_INIT_CDROM

  • SDL_INIT_JOYSTICK

  • SDL_INIT_NOPARACHUTE

  • SDL_INIT_EVENTTHREAD

  • SDL_INIT_EVERYTHING

Parameters
  • flags: int

Return type

int

Returns

undocumented (FIXME)

See

SDL_Quit

SDL_InitSubSystem(flags)

Initialize specific SDL subsystems.

Parameters
  • flags: int

Return type

int

Returns

undocumented (FIXME)

See

SDL_Init, SDL_QuitSubSystem