include/SDL_endian.h
changeset 337 9154ec9ca3d2
parent 297 f6ffac90895c
child 769 b8d311d90021
equal deleted inserted replaced
336:745873ea091f 337:9154ec9ca3d2
   122 #define SDL_SwapBE32(X)	(X)
   122 #define SDL_SwapBE32(X)	(X)
   123 #define SDL_SwapBE64(X)	(X)
   123 #define SDL_SwapBE64(X)	(X)
   124 #endif
   124 #endif
   125 
   125 
   126 /* Read an item of the specified endianness and return in native format */
   126 /* Read an item of the specified endianness and return in native format */
   127 extern DECLSPEC Uint16 SDL_ReadLE16(SDL_RWops *src);
   127 extern DECLSPEC Uint16 SDLCALL SDL_ReadLE16(SDL_RWops *src);
   128 extern DECLSPEC Uint16 SDL_ReadBE16(SDL_RWops *src);
   128 extern DECLSPEC Uint16 SDLCALL SDL_ReadBE16(SDL_RWops *src);
   129 extern DECLSPEC Uint32 SDL_ReadLE32(SDL_RWops *src);
   129 extern DECLSPEC Uint32 SDLCALL SDL_ReadLE32(SDL_RWops *src);
   130 extern DECLSPEC Uint32 SDL_ReadBE32(SDL_RWops *src);
   130 extern DECLSPEC Uint32 SDLCALL SDL_ReadBE32(SDL_RWops *src);
   131 extern DECLSPEC Uint64 SDL_ReadLE64(SDL_RWops *src);
   131 extern DECLSPEC Uint64 SDLCALL SDL_ReadLE64(SDL_RWops *src);
   132 extern DECLSPEC Uint64 SDL_ReadBE64(SDL_RWops *src);
   132 extern DECLSPEC Uint64 SDLCALL SDL_ReadBE64(SDL_RWops *src);
   133 
   133 
   134 /* Write an item of native format to the specified endianness */
   134 /* Write an item of native format to the specified endianness */
   135 extern DECLSPEC int SDL_WriteLE16(SDL_RWops *dst, Uint16 value);
   135 extern DECLSPEC int SDLCALL SDL_WriteLE16(SDL_RWops *dst, Uint16 value);
   136 extern DECLSPEC int SDL_WriteBE16(SDL_RWops *dst, Uint16 value);
   136 extern DECLSPEC int SDLCALL SDL_WriteBE16(SDL_RWops *dst, Uint16 value);
   137 extern DECLSPEC int SDL_WriteLE32(SDL_RWops *dst, Uint32 value);
   137 extern DECLSPEC int SDLCALL SDL_WriteLE32(SDL_RWops *dst, Uint32 value);
   138 extern DECLSPEC int SDL_WriteBE32(SDL_RWops *dst, Uint32 value);
   138 extern DECLSPEC int SDLCALL SDL_WriteBE32(SDL_RWops *dst, Uint32 value);
   139 extern DECLSPEC int SDL_WriteLE64(SDL_RWops *dst, Uint64 value);
   139 extern DECLSPEC int SDLCALL SDL_WriteLE64(SDL_RWops *dst, Uint64 value);
   140 extern DECLSPEC int SDL_WriteBE64(SDL_RWops *dst, Uint64 value);
   140 extern DECLSPEC int SDLCALL SDL_WriteBE64(SDL_RWops *dst, Uint64 value);
   141 
   141 
   142 
   142 
   143 /* Ends C function definitions when using C++ */
   143 /* Ends C function definitions when using C++ */
   144 #ifdef __cplusplus
   144 #ifdef __cplusplus
   145 }
   145 }