Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00012 #ifndef SDL_H
00013 #define SDL_H
00014
00015 const char *SdlOpen(uint32 x);
00016 void SdlClose(uint32 x);
00017
00018 #ifdef WIN32
00019 #define DYNAMICALLY_LOADED_SDL
00020 #endif
00021
00022 #ifdef DYNAMICALLY_LOADED_SDL
00023 #include <SDL.h>
00024
00025 struct SDLProcs {
00026 int (SDLCALL *SDL_Init)(Uint32);
00027 int (SDLCALL *SDL_InitSubSystem)(Uint32);
00028 char *(SDLCALL *SDL_GetError)();
00029 void (SDLCALL *SDL_QuitSubSystem)(Uint32);
00030 void (SDLCALL *SDL_UpdateRect)(SDL_Surface *, Sint32, Sint32, Uint32, Uint32);
00031 void (SDLCALL *SDL_UpdateRects)(SDL_Surface *, int, SDL_Rect *);
00032 int (SDLCALL *SDL_SetColors)(SDL_Surface *, SDL_Color *, int, int);
00033 void (SDLCALL *SDL_WM_SetCaption)(const char *, const char *);
00034 int (SDLCALL *SDL_ShowCursor)(int);
00035 void (SDLCALL *SDL_FreeSurface)(SDL_Surface *);
00036 int (SDLCALL *SDL_PollEvent)(SDL_Event *);
00037 void (SDLCALL *SDL_WarpMouse)(Uint16, Uint16);
00038 uint32 (SDLCALL *SDL_GetTicks)();
00039 int (SDLCALL *SDL_OpenAudio)(SDL_AudioSpec *, SDL_AudioSpec*);
00040 void (SDLCALL *SDL_PauseAudio)(int);
00041 void (SDLCALL *SDL_CloseAudio)();
00042 int (SDLCALL *SDL_LockSurface)(SDL_Surface*);
00043 void (SDLCALL *SDL_UnlockSurface)(SDL_Surface*);
00044 SDLMod (SDLCALL *SDL_GetModState)();
00045 void (SDLCALL *SDL_Delay)(Uint32);
00046 void (SDLCALL *SDL_Quit)();
00047 SDL_Surface *(SDLCALL *SDL_SetVideoMode)(int, int, int, Uint32);
00048 int (SDLCALL *SDL_EnableKeyRepeat)(int, int);
00049 void (SDLCALL *SDL_EnableUNICODE)(int);
00050 void (SDLCALL *SDL_VideoDriverName)(char *, int);
00051 SDL_Rect **(SDLCALL *SDL_ListModes)(void *, int);
00052 Uint8 *(SDLCALL *SDL_GetKeyState)(int *);
00053 SDL_Surface *(SDLCALL *SDL_LoadBMP_RW)(SDL_RWops *, int);
00054 SDL_RWops *(SDLCALL *SDL_RWFromFile)(const char *, const char *);
00055 int (SDLCALL *SDL_SetColorKey)(SDL_Surface *, Uint32, Uint32);
00056 void (SDLCALL *SDL_WM_SetIcon)(SDL_Surface *, Uint8 *);
00057 Uint32 (SDLCALL *SDL_MapRGB)(SDL_PixelFormat *, Uint8, Uint8, Uint8);
00058 int (SDLCALL *SDL_VideoModeOK)(int, int, int, Uint32);
00059 SDL_version *(SDLCALL *SDL_Linked_Version)();
00060 int (SDLCALL *SDL_BlitSurface)(SDL_Surface *, SDL_Rect *, SDL_Surface *, SDL_Rect *);
00061 SDL_Surface *(SDLCALL *SDL_CreateRGBSurface)(Uint32, int, int, int, Uint32, Uint32, Uint32, Uint32);
00062 };
00063
00064 extern SDLProcs sdl_proc;
00065
00066 #define SDL_CALL sdl_proc.
00067 #else
00068 #define SDL_CALL
00069 #endif
00070
00071 #endif