/Users/hercules/trunk/SDL/include/SDL_rwops.h File Reference

#include "SDL_stdinc.h"
#include "SDL_error.h"
#include "begin_code.h"
#include "close_code.h"

Go to the source code of this file.

Data Structures

struct  SDL_RWops

Defines

#define RW_SEEK_SET   0
#define RW_SEEK_CUR   1
#define RW_SEEK_END   2
#define SDL_RWseek(ctx, offset, whence)   (ctx)->seek(ctx, offset, whence)
#define SDL_RWtell(ctx)   (ctx)->seek(ctx, 0, RW_SEEK_CUR)
#define SDL_RWread(ctx, ptr, size, n)   (ctx)->read(ctx, ptr, size, n)
#define SDL_RWwrite(ctx, ptr, size, n)   (ctx)->write(ctx, ptr, size, n)
#define SDL_RWclose(ctx)   (ctx)->close(ctx)

Functions

DECLSPEC SDL_RWops *SDLCALL SDL_RWFromFile (const char *file, const char *mode)
DECLSPEC SDL_RWops *SDLCALL SDL_RWFromFP (FILE *fp, SDL_bool autoclose)
DECLSPEC SDL_RWops *SDLCALL SDL_RWFromMem (void *mem, int size)
DECLSPEC SDL_RWops *SDLCALL SDL_RWFromConstMem (const void *mem, int size)
DECLSPEC SDL_RWops *SDLCALL SDL_AllocRW (void)
DECLSPEC void SDLCALL SDL_FreeRW (SDL_RWops *area)
DECLSPEC Uint16 SDLCALL SDL_ReadLE16 (SDL_RWops *src)
DECLSPEC Uint16 SDLCALL SDL_ReadBE16 (SDL_RWops *src)
DECLSPEC Uint32 SDLCALL SDL_ReadLE32 (SDL_RWops *src)
DECLSPEC Uint32 SDLCALL SDL_ReadBE32 (SDL_RWops *src)
DECLSPEC Uint64 SDLCALL SDL_ReadLE64 (SDL_RWops *src)
DECLSPEC Uint64 SDLCALL SDL_ReadBE64 (SDL_RWops *src)
DECLSPEC size_t SDLCALL SDL_WriteLE16 (SDL_RWops *dst, Uint16 value)
DECLSPEC size_t SDLCALL SDL_WriteBE16 (SDL_RWops *dst, Uint16 value)
DECLSPEC size_t SDLCALL SDL_WriteLE32 (SDL_RWops *dst, Uint32 value)
DECLSPEC size_t SDLCALL SDL_WriteBE32 (SDL_RWops *dst, Uint32 value)
DECLSPEC size_t SDLCALL SDL_WriteLE64 (SDL_RWops *dst, Uint64 value)
DECLSPEC size_t SDLCALL SDL_WriteBE64 (SDL_RWops *dst, Uint64 value)


Detailed Description

This file provides a general interface for SDL to read and write data sources. It can easily be extended to files, memory, etc.

Generated on Mon Sep 21 21:32:25 2009 for Simple DirectMedia Layer by  doxygen 1.5.8