pygame2.sdl.cdrom
The pygame2.sdl.cdrom C API contains objects and functions for
accessing the physical CD- and DVD-ROMS of the computer.
Import
Include headers:
-
int import_pygame2_sdl_cdrom(void)
- Imports the pygame2.sdl.cdrom module. This returns 0 on success
and -1 on failure.
Macros
-
ASSERT_CDROM_INIT(retval)
- Checks, whether the cdrom subsystem was properly initialised. If not,
this will set a PyExc_PyGameError and return retval.
-
ASSERT_CDROM_OPEN(obj, retval)
- Checks, whether the passed PyCD is open for access. If not,
this will set a PyExc_PyGameError and return retval.
PyCD
-
PyCD
-
PyCD_Type
The PyCD object is used for gaining access and working with physical CD
drives and CDs using SDL.
Members
-
int PyCD.index
- The drive index as reported by the SDL library.
-
SDL_CD* PyCD.cd
- The SDL_CD pointer to access the CD drive.
Functions
-
int PyCD_Check(PyObject *obj)
- Returns true, if the argument is a PyCD or a subclass of
PyCD.
-
PyObject* PyCD_New(int index)
- Creates a new PyCD object from the passed CD drive index. On
failure, this returns NULL.
-
SDL_CD* PyCD_AsCD(PyObject *obj)
- Macro for accessing the cd member of the PyCD. This does
not perform any type or argument checks.
PyCDTrack
-
PyCDTrack
-
PyCDTrack_Type
The PyCDTrack object contains information about a single CD track on a
loaded CD.
Members
-
SDL_CDtrack PyCD.track
- The track information of a CD track as reported by the SDL library.
Functions
-
int PyCDTrack_Check(PyObject *obj)
- Returns true, if the argument is a PyCDTrack or a subclass of
PyCDTrack.
-
PyObject* PyCDTrack_New(SDL_CDtrack track)
- Creates a new PyCDTrack object from the passed CD track
information. On failure, this returns NULL.
-
SDL_CDtrack* PyCDTrack_AsCDTrack(PyObject *obj)
- Macro for accessing the track member of the PyCDTrack. This
does not perform any type or argument checks.