00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031 #ifdef SDL_NO_COMPAT
00032 #define _SDL_compat_h
00033 #endif
00034
00035 #ifndef _SDL_compat_h
00036 #define _SDL_compat_h
00037
00038 #include "SDL_video.h"
00039 #include "SDL_version.h"
00040
00041 #include "begin_code.h"
00042
00043 #ifdef __cplusplus
00044
00045 extern "C" {
00046
00047 #endif
00048
00049 #define SDL_SWSURFACE 0x00000000
00050 #define SDL_SRCALPHA 0x00010000
00051 #define SDL_SRCCOLORKEY 0x00020000
00052 #define SDL_ANYFORMAT 0x00100000
00053 #define SDL_HWPALETTE 0x00200000
00054 #define SDL_DOUBLEBUF 0x00400000
00055 #define SDL_FULLSCREEN 0x00800000
00056 #define SDL_RESIZABLE 0x01000000
00057 #define SDL_NOFRAME 0x02000000
00058 #define SDL_OPENGL 0x04000000
00059 #define SDL_HWSURFACE 0x08000001
00060 #define SDL_ASYNCBLIT 0x08000000
00061 #define SDL_RLEACCELOK 0x08000000
00062 #define SDL_HWACCEL 0x08000000
00063
00064 #define SDL_APPMOUSEFOCUS 0x01
00065 #define SDL_APPINPUTFOCUS 0x02
00066 #define SDL_APPACTIVE 0x04
00067
00068 #define SDL_LOGPAL 0x01
00069 #define SDL_PHYSPAL 0x02
00070
00071 #define SDL_ACTIVEEVENT SDL_EVENT_RESERVED1
00072 #define SDL_VIDEORESIZE SDL_EVENT_RESERVED2
00073 #define SDL_VIDEOEXPOSE SDL_EVENT_RESERVED3
00074 #define SDL_ACTIVEEVENTMASK SDL_EVENTMASK(SDL_ACTIVEEVENT)
00075 #define SDL_VIDEORESIZEMASK SDL_EVENTMASK(SDL_VIDEORESIZE)
00076 #define SDL_VIDEOEXPOSEMASK SDL_EVENTMASK(SDL_VIDEOEXPOSE)
00077
00078 #define SDL_BUTTON_WHEELUP 4
00079 #define SDL_BUTTON_WHEELDOWN 5
00080
00081 #define SDL_DEFAULT_REPEAT_DELAY 500
00082 #define SDL_DEFAULT_REPEAT_INTERVAL 30
00083
00084 typedef struct SDL_VideoInfo
00085 {
00086 Uint32 hw_available:1;
00087 Uint32 wm_available:1;
00088 Uint32 UnusedBits1:6;
00089 Uint32 UnusedBits2:1;
00090 Uint32 blit_hw:1;
00091 Uint32 blit_hw_CC:1;
00092 Uint32 blit_hw_A:1;
00093 Uint32 blit_sw:1;
00094 Uint32 blit_sw_CC:1;
00095 Uint32 blit_sw_A:1;
00096 Uint32 blit_fill:1;
00097 Uint32 UnusedBits3:16;
00098 Uint32 video_mem;
00099
00100 SDL_PixelFormat *vfmt;
00101
00102 int current_w;
00103 int current_h;
00104 } SDL_VideoInfo;
00105
00106
00107
00108
00109
00110
00111
00112
00113 #define SDL_YV12_OVERLAY 0x32315659
00114 #define SDL_IYUV_OVERLAY 0x56555949
00115 #define SDL_YUY2_OVERLAY 0x32595559
00116 #define SDL_UYVY_OVERLAY 0x59565955
00117 #define SDL_YVYU_OVERLAY 0x55595659
00118
00119
00120 typedef struct SDL_Overlay
00121 {
00122 Uint32 format;
00123 int w, h;
00124 int planes;
00125 Uint16 *pitches;
00126 Uint8 **pixels;
00127
00128
00129 struct private_yuvhwfuncs *hwfuncs;
00130 struct private_yuvhwdata *hwdata;
00131
00132
00133 Uint32 hw_overlay:1;
00134 Uint32 UnusedBits:31;
00135 } SDL_Overlay;
00136
00137 typedef enum
00138 {
00139 SDL_GRAB_QUERY = -1,
00140 SDL_GRAB_OFF = 0,
00141 SDL_GRAB_ON = 1
00142 } SDL_GrabMode;
00143
00144 struct SDL_SysWMinfo;
00145
00146
00147
00148
00149 #define SDLK_0 '0'
00150 #define SDLK_1 '1'
00151 #define SDLK_2 '2'
00152 #define SDLK_3 '3'
00153 #define SDLK_4 '4'
00154 #define SDLK_5 '5'
00155 #define SDLK_6 '6'
00156 #define SDLK_7 '7'
00157 #define SDLK_8 '8'
00158 #define SDLK_9 '9'
00159 #define SDLK_a 'a'
00160 #define SDLK_b 'b'
00161 #define SDLK_c 'c'
00162 #define SDLK_d 'd'
00163 #define SDLK_e 'e'
00164 #define SDLK_f 'f'
00165 #define SDLK_g 'g'
00166 #define SDLK_h 'h'
00167 #define SDLK_i 'i'
00168 #define SDLK_j 'j'
00169 #define SDLK_k 'k'
00170 #define SDLK_l 'l'
00171 #define SDLK_m 'm'
00172 #define SDLK_n 'n'
00173 #define SDLK_o 'o'
00174 #define SDLK_p 'p'
00175 #define SDLK_q 'q'
00176 #define SDLK_r 'r'
00177 #define SDLK_s 's'
00178 #define SDLK_t 't'
00179 #define SDLK_u 'u'
00180 #define SDLK_v 'v'
00181 #define SDLK_w 'w'
00182 #define SDLK_x 'x'
00183 #define SDLK_y 'y'
00184 #define SDLK_z 'z'
00185 #define SDLK_QUOTE '\''
00186 #define SDLK_MINUS '-'
00187 #define SDLK_BACKQUOTE '`'
00188 #define SDLK_EXCLAIM '!'
00189 #define SDLK_QUOTEDBL '"'
00190 #define SDLK_HASH '#'
00191 #define SDLK_DOLLAR '$'
00192 #define SDLK_AMPERSAND '&'
00193 #define SDLK_LEFTPAREN '('
00194 #define SDLK_RIGHTPAREN ')'
00195 #define SDLK_ASTERISK '*'
00196 #define SDLK_PLUS '+'
00197 #define SDLK_COLON ':'
00198 #define SDLK_LESS '<'
00199 #define SDLK_GREATER '>'
00200 #define SDLK_QUESTION '?'
00201 #define SDLK_AT '@'
00202 #define SDLK_CARET '^'
00203 #define SDLK_UNDERSCORE '_'
00204 #define SDLK_KP0 SDLK_KP_0
00205 #define SDLK_KP1 SDLK_KP_1
00206 #define SDLK_KP2 SDLK_KP_2
00207 #define SDLK_KP3 SDLK_KP_3
00208 #define SDLK_KP4 SDLK_KP_4
00209 #define SDLK_KP5 SDLK_KP_5
00210 #define SDLK_KP6 SDLK_KP_6
00211 #define SDLK_KP7 SDLK_KP_7
00212 #define SDLK_KP8 SDLK_KP_8
00213 #define SDLK_KP9 SDLK_KP_9
00214 #define SDLK_NUMLOCK SDLK_NUMLOCKCLEAR
00215 #define SDLK_SCROLLOCK SDLK_SCROLLLOCK
00216 #define SDLK_PRINT SDLK_PRINTSCREEN
00217
00218
00219 #define KMOD_LMETA KMOD_LGUI
00220 #define KMOD_RMETA KMOD_RGUI
00221 #define KMOD_META KMOD_GUI
00222
00223
00224 #define SDLK_LSUPER SDLK_LMETA
00225 #define SDLK_RSUPER SDLK_RMETA
00226 #define SDLK_COMPOSE SDLK_APPLICATION
00227 #define SDLK_BREAK SDLK_STOP
00228 #define SDLK_EURO SDLK_2
00229
00230
00231 #define SDL_SetModuleHandle(x)
00232 #define SDL_AllocSurface SDL_CreateRGBSurface
00233
00234 extern DECLSPEC const SDL_version *SDLCALL SDL_Linked_Version(void);
00235 extern DECLSPEC char *SDLCALL SDL_AudioDriverName(char *namebuf, int maxlen);
00236 extern DECLSPEC char *SDLCALL SDL_VideoDriverName(char *namebuf, int maxlen);
00237 extern DECLSPEC const SDL_VideoInfo *SDLCALL SDL_GetVideoInfo(void);
00238 extern DECLSPEC int SDLCALL SDL_VideoModeOK(int width,
00239 int height,
00240 int bpp, Uint32 flags);
00241 extern DECLSPEC SDL_Rect **SDLCALL SDL_ListModes(const SDL_PixelFormat *
00242 format, Uint32 flags);
00243 extern DECLSPEC SDL_Surface *SDLCALL SDL_SetVideoMode(int width, int height,
00244 int bpp, Uint32 flags);
00245 extern DECLSPEC SDL_Surface *SDLCALL SDL_GetVideoSurface(void);
00246 extern DECLSPEC void SDLCALL SDL_UpdateRects(SDL_Surface * screen,
00247 int numrects, SDL_Rect * rects);
00248 extern DECLSPEC void SDLCALL SDL_UpdateRect(SDL_Surface * screen,
00249 Sint32 x,
00250 Sint32 y, Uint32 w, Uint32 h);
00251 extern DECLSPEC int SDLCALL SDL_Flip(SDL_Surface * screen);
00252 extern DECLSPEC int SDLCALL SDL_SetAlpha(SDL_Surface * surface,
00253 Uint32 flag, Uint8 alpha);
00254 extern DECLSPEC SDL_Surface *SDLCALL SDL_DisplayFormat(SDL_Surface * surface);
00255 extern DECLSPEC SDL_Surface *SDLCALL SDL_DisplayFormatAlpha(SDL_Surface *
00256 surface);
00257 extern DECLSPEC void SDLCALL SDL_WM_SetCaption(const char *title,
00258 const char *icon);
00259 extern DECLSPEC void SDLCALL SDL_WM_GetCaption(const char **title,
00260 const char **icon);
00261 extern DECLSPEC void SDLCALL SDL_WM_SetIcon(SDL_Surface * icon, Uint8 * mask);
00262 extern DECLSPEC int SDLCALL SDL_WM_IconifyWindow(void);
00263 extern DECLSPEC int SDLCALL SDL_WM_ToggleFullScreen(SDL_Surface * surface);
00264 extern DECLSPEC SDL_GrabMode SDLCALL SDL_WM_GrabInput(SDL_GrabMode mode);
00265 extern DECLSPEC int SDLCALL SDL_SetPalette(SDL_Surface * surface,
00266 int flags,
00267 const SDL_Color * colors,
00268 int firstcolor, int ncolors);
00269 extern DECLSPEC int SDLCALL SDL_SetColors(SDL_Surface * surface,
00270 const SDL_Color * colors,
00271 int firstcolor, int ncolors);
00272 extern DECLSPEC int SDLCALL SDL_GetWMInfo(struct SDL_SysWMinfo *info);
00273 extern DECLSPEC Uint8 SDLCALL SDL_GetAppState(void);
00274 extern DECLSPEC void SDLCALL SDL_WarpMouse(Uint16 x, Uint16 y);
00275 extern DECLSPEC SDL_Overlay *SDLCALL SDL_CreateYUVOverlay(int width,
00276 int height,
00277 Uint32 format,
00278 SDL_Surface *
00279 display);
00280 extern DECLSPEC int SDLCALL SDL_LockYUVOverlay(SDL_Overlay * overlay);
00281 extern DECLSPEC void SDLCALL SDL_UnlockYUVOverlay(SDL_Overlay * overlay);
00282 extern DECLSPEC int SDLCALL SDL_DisplayYUVOverlay(SDL_Overlay * overlay,
00283 SDL_Rect * dstrect);
00284 extern DECLSPEC void SDLCALL SDL_FreeYUVOverlay(SDL_Overlay * overlay);
00285 extern DECLSPEC void SDLCALL SDL_GL_SwapBuffers(void);
00286 extern DECLSPEC int SDLCALL SDL_EnableKeyRepeat(int delay, int interval);
00287 extern DECLSPEC void SDLCALL SDL_GetKeyRepeat(int *delay, int *interval);
00288 extern DECLSPEC int SDLCALL SDL_EnableUNICODE(int enable);
00289
00290
00291 #ifdef __cplusplus
00292
00293 }
00294
00295 #endif
00296 #include "close_code.h"
00297
00298 #endif
00299
00300