General interface for SDL to read and write data sources.
For files, use SDL_RWFromFile. Other Python file-type objects can be used with SDL_RWFromObject. If another library provides a constant void pointer to a contiguous region of memory, SDL_RWFromMem and SDL_RWFromConstMem can be used.
Bases: _ctypes.Structure
Read/write operations structure.
Ivariables: |
|
---|
Structure/Union member
Structure/Union member
Structure/Union member
Structure/Union member
Structure/Union member
These functions shouldn’t be useful to Pythoners. SDL_AllocRW = dll.function(‘SDL_AllocRW’,
‘’‘Allocate a blank SDL_Rwops structure.
rtype: SDL_RWops ‘’’ args=[], arg_types=[], return_type=POINTER(SDL_RWops), dereference_return=True, require_return=True)
‘’‘Free a SDL_RWops structure.
param area: | SDL_RWops |
---|
‘’’ args=[‘area’], arg_types=[POINTER(SDL_RWops)], return_type=None)
Construct an SDL_RWops structure from a Python file-like object.
The object must support the following methods in the same fashion as the builtin file object:
- read(len) -> data
- write(data)
- seek(offset, whence)
- close()
Parameters: |
|
---|---|
Return type: | SDL_RWops |