SDL
2.0
|
Go to the source code of this file.
Macros | |
#define | _LARGEFILE64_SOURCE |
#define _LARGEFILE64_SOURCE |
Definition at line 28 of file SDL_rwops.c.
|
static |
Definition at line 517 of file SDL_rwops.c.
References context, and SDL_FreeRW().
Referenced by SDL_RWFromConstMem(), and SDL_RWFromMem().
Definition at line 476 of file SDL_rwops.c.
References context, ptr, and SDL_memcpy.
Referenced by SDL_RWFromConstMem(), and SDL_RWFromMem().
Definition at line 448 of file SDL_rwops.c.
References context, RW_SEEK_CUR, RW_SEEK_END, RW_SEEK_SET, and SDL_SetError.
Referenced by SDL_RWFromConstMem(), and SDL_RWFromMem().
Definition at line 442 of file SDL_rwops.c.
References context.
Referenced by SDL_RWFromConstMem(), and SDL_RWFromMem().
Definition at line 499 of file SDL_rwops.c.
References context, ptr, and SDL_memcpy.
Referenced by SDL_RWFromMem().
|
static |
Definition at line 510 of file SDL_rwops.c.
References SDL_SetError.
Referenced by SDL_RWFromConstMem().
Definition at line 701 of file SDL_rwops.c.
References NULL, SDL_malloc, SDL_OutOfMemory, SDL_RWOPS_UNKNOWN, and SDL_RWops::type.
Referenced by SDL_RWFromConstMem(), SDL_RWFromFile(), and SDL_RWFromMem().
Definition at line 715 of file SDL_rwops.c.
References SDL_free.
Referenced by mem_close(), and SDL_RWFromFile().
Load an entire file.
The data is allocated with a zero byte at the end (null terminated)
If datasize
is not NULL, it is filled with the size of the data read.
If freesrc
is non-zero, the stream will be closed after being read.
The data should be freed with SDL_free().
Definition at line 774 of file SDL_rwops.c.
References SDL_LoadFile_RW(), and SDL_RWFromFile().
Load all the data from an SDL data stream.
The data is allocated with a zero byte at the end (null terminated)
If datasize
is not NULL, it is filled with the size of the data read.
If freesrc
is non-zero, the stream will be closed after being read.
The data should be freed with SDL_free().
Definition at line 722 of file SDL_rwops.c.
References done, NULL, SDL_free, SDL_InvalidParamError, SDL_malloc, SDL_OutOfMemory, SDL_realloc, SDL_RWclose(), SDL_RWread(), and SDL_RWsize().
Referenced by SDL_LoadFile().
int SDL_RWclose | ( | SDL_RWops * | context | ) |
Close and free an allocated SDL_RWops structure.
Definition at line 810 of file SDL_rwops.c.
References context.
Referenced by SDL_LoadFile_RW().
Definition at line 673 of file SDL_rwops.c.
References SDL_RWops::close, SDL_RWops::hidden, SDL_RWops::mem, mem_close(), mem_read(), mem_seek(), mem_size(), mem_writeconst(), NULL, SDL_RWops::read, SDL_AllocRW(), SDL_InvalidParamError, SDL_RWOPS_MEMORY_RO, SDL_RWops::seek, SDL_RWops::size, SDL_RWops::type, and SDL_RWops::write.
SDL_RWops* SDL_RWFromFile | ( | const char * | file, |
const char * | mode | ||
) |
Definition at line 529 of file SDL_rwops.c.
References Android_JNI_FileClose(), Android_JNI_FileOpen(), Android_JNI_FileRead(), Android_JNI_FileSeek(), Android_JNI_FileSize(), Android_JNI_FileWrite(), SDL_RWops::close, NULL, SDL_RWops::read, SDL_AllocRW(), SDL_AndroidGetInternalStoragePath, SDL_FreeRW(), SDL_RWFromFP(), SDL_RWOPS_JNIFILE, SDL_RWOPS_WINFILE, SDL_SetError, SDL_snprintf, SDL_stack_alloc, SDL_stack_free, SDL_TRUE, SDL_RWops::seek, SDL_RWops::size, SDL_RWops::type, and SDL_RWops::write.
Referenced by SDL_LoadFile().
Definition at line 637 of file SDL_rwops.c.
References NULL, and SDL_SetError.
Referenced by SDL_RWFromFile().
Definition at line 645 of file SDL_rwops.c.
References SDL_RWops::close, SDL_RWops::hidden, SDL_RWops::mem, mem_close(), mem_read(), mem_seek(), mem_size(), mem_write(), NULL, SDL_RWops::read, SDL_AllocRW(), SDL_InvalidParamError, SDL_RWOPS_MEMORY, SDL_RWops::seek, SDL_RWops::size, SDL_RWops::type, and SDL_RWops::write.
Read up to maxnum
objects each of size size
from the data stream to the area pointed at by ptr
.
Definition at line 798 of file SDL_rwops.c.
Referenced by SDL_LoadFile_RW(), SDL_ReadBE16(), SDL_ReadBE32(), SDL_ReadBE64(), SDL_ReadLE16(), SDL_ReadLE32(), SDL_ReadLE64(), and SDL_ReadU8().
Return the size of the file in this rwops, or -1 if unknown
Definition at line 780 of file SDL_rwops.c.
References context.
Referenced by SDL_LoadFile_RW().
Return the current offset in the data stream, or -1 on error.
Definition at line 792 of file SDL_rwops.c.
References context, and RW_SEEK_CUR.
Write exactly num
objects each of size size
from the area pointed at by ptr
to data stream.
Definition at line 804 of file SDL_rwops.c.
Referenced by SDL_WriteBE16(), SDL_WriteBE32(), SDL_WriteBE64(), SDL_WriteLE16(), SDL_WriteLE32(), SDL_WriteLE64(), and SDL_WriteU8().
Definition at line 881 of file SDL_rwops.c.
References SDL_RWwrite().