Mercurial > sdl-ios-xcode
comparison src/video/gem/SDL_gemvideo.h @ 1895:c121d94672cb
SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Mon, 10 Jul 2006 21:04:37 +0000 |
parents | 417f2af2bd52 |
children | f54670a477bb |
comparison
equal
deleted
inserted
replaced
1894:c69cee13dd76 | 1895:c121d94672cb |
---|---|
25 #define _SDL_gemvideo_h | 25 #define _SDL_gemvideo_h |
26 | 26 |
27 #include "SDL_mutex.h" | 27 #include "SDL_mutex.h" |
28 #include "../SDL_sysvideo.h" | 28 #include "../SDL_sysvideo.h" |
29 | 29 |
30 /* The implementation dependent data for the window manager cursor */ | |
31 struct WMcursor { | |
32 MFORM *mform_p; | |
33 }; | |
34 | |
35 /* Hidden "this" pointer for the video functions */ | 30 /* Hidden "this" pointer for the video functions */ |
36 #define _THIS SDL_VideoDevice *this | 31 #define _THIS SDL_VideoDevice *this |
37 | 32 |
38 /* Functions prototypes */ | 33 /* Functions prototypes */ |
39 void GEM_wind_redraw(_THIS, int winhandle, short *inside); | 34 void GEM_wind_redraw(_THIS, int winhandle, short *inside); |
40 | 35 |
41 /* Private display data */ | 36 /* Private display data */ |
42 | 37 |
43 #define B2S_C2P_1TO2 (1<<0) /* C2P convert buffer 1 to buffer 2 */ | 38 #define B2S_C2P_1TO2 (1<<0) /* C2P convert buffer 1 to buffer 2 */ |
44 #define B2S_C2P_1TOS (1<<1) /* C2P convert buffer 1 to screen */ | 39 #define B2S_C2P_1TOS (1<<1) /* C2P convert buffer 1 to screen */ |
45 #define B2S_VROCPYFM_1TOS (1<<2) /* vro_cpyfm() buffer 1 to screen */ | 40 #define B2S_VROCPYFM_1TOS (1<<2) /* vro_cpyfm() buffer 1 to screen */ |
46 #define B2S_VROCPYFM_2TOS (1<<3) /* vro_cpyfm() buffer 2 to screen */ | 41 #define B2S_VROCPYFM_2TOS (1<<3) /* vro_cpyfm() buffer 2 to screen */ |
47 | 42 |
48 #define SDL_NUMMODES 1 /* Fullscreen */ | 43 #define SDL_NUMMODES 1 /* Fullscreen */ |
49 | 44 |
50 struct SDL_PrivateVideoData { | 45 struct SDL_PrivateVideoData |
51 Uint16 buf2scr_ops; /* Operations to get buffer to screen */ | 46 { |
52 void *buffer1; /* Our shadow buffers */ | 47 Uint16 buf2scr_ops; /* Operations to get buffer to screen */ |
53 void *buffer2; | 48 void *buffer1; /* Our shadow buffers */ |
49 void *buffer2; | |
54 | 50 |
55 /* VDI infos */ | 51 /* VDI infos */ |
56 short vdi_handle; /* VDI handle */ | 52 short vdi_handle; /* VDI handle */ |
57 short full_w, full_h; /* Fullscreen size */ | 53 short full_w, full_h; /* Fullscreen size */ |
58 short bpp; /* Colour depth */ | 54 short bpp; /* Colour depth */ |
59 short pixelsize; /* Bytes per pixel */ | 55 short pixelsize; /* Bytes per pixel */ |
60 short old_numcolors; /* Number of colors in saved palette */ | 56 short old_numcolors; /* Number of colors in saved palette */ |
61 Uint16 pitch; /* Line length */ | 57 Uint16 pitch; /* Line length */ |
62 Uint16 format; /* Screen format */ | 58 Uint16 format; /* Screen format */ |
63 void *screen; /* Screen address */ | 59 void *screen; /* Screen address */ |
64 Uint32 red, green, blue, alpha; /* Screen components */ | 60 Uint32 red, green, blue, alpha; /* Screen components */ |
65 Uint32 screensize; | 61 Uint32 screensize; |
66 short blit_coords[8]; /* Coordinates for bitblt */ | 62 short blit_coords[8]; /* Coordinates for bitblt */ |
67 MFDB src_mfdb, dst_mfdb; /* VDI MFDB for bitblt */ | 63 MFDB src_mfdb, dst_mfdb; /* VDI MFDB for bitblt */ |
68 Uint16 old_palette[256][3]; /* Saved current palette */ | 64 Uint16 old_palette[256][3]; /* Saved current palette */ |
69 Uint16 cur_palette[256][3]; /* SDL application palette */ | 65 Uint16 cur_palette[256][3]; /* SDL application palette */ |
70 /* Function to set/restore palette */ | 66 /* Function to set/restore palette */ |
71 void (*setpalette)(_THIS, Uint16 newpal[256][3]); | 67 void (*setpalette) (_THIS, Uint16 newpal[256][3]); |
72 | 68 |
73 /* GEM infos */ | 69 /* GEM infos */ |
74 short desk_x, desk_y; /* Desktop properties */ | 70 short desk_x, desk_y; /* Desktop properties */ |
75 short desk_w, desk_h; | 71 short desk_w, desk_h; |
76 short win_handle; /* Our window handle */ | 72 short win_handle; /* Our window handle */ |
77 int window_type; /* Window type */ | 73 int window_type; /* Window type */ |
78 const char *title_name; /* Window title */ | 74 const char *title_name; /* Window title */ |
79 const char *icon_name; /* Icon title */ | 75 const char *icon_name; /* Icon title */ |
80 short version; /* AES version */ | 76 short version; /* AES version */ |
81 short wfeatures; /* AES window features */ | 77 short wfeatures; /* AES window features */ |
82 SDL_bool refresh_name; /* Change window title ? */ | 78 SDL_bool refresh_name; /* Change window title ? */ |
83 SDL_bool window_fulled; /* Window maximized ? */ | 79 SDL_bool window_fulled; /* Window maximized ? */ |
84 SDL_bool mouse_relative; /* Report relative mouse movement */ | 80 SDL_bool mouse_relative; /* Report relative mouse movement */ |
85 SDL_bool locked; /* AES locked for fullscreen ? */ | 81 SDL_bool locked; /* AES locked for fullscreen ? */ |
86 SDL_bool lock_redraw; /* Prevent redraw till buffers are setup */ | 82 SDL_bool lock_redraw; /* Prevent redraw till buffers are setup */ |
87 short message[8]; /* To self-send an AES message */ | 83 short message[8]; /* To self-send an AES message */ |
88 void *menubar; /* Menu bar save buffer when going fullscreen */ | 84 void *menubar; /* Menu bar save buffer when going fullscreen */ |
89 SDL_bool use_dev_mouse; /* Use /dev/mouse ? */ | 85 SDL_bool use_dev_mouse; /* Use /dev/mouse ? */ |
90 WMcursor *cursor; /* To restore cursor when leaving/entering window */ | |
91 | 86 |
92 SDL_bool fullscreen; /* Fullscreen or windowed mode ? */ | 87 SDL_bool fullscreen; /* Fullscreen or windowed mode ? */ |
93 SDL_Rect *SDL_modelist[SDL_NUMMODES+1]; /* Mode list */ | 88 SDL_Rect *SDL_modelist[SDL_NUMMODES + 1]; /* Mode list */ |
94 SDL_Surface *icon; /* The icon */ | 89 SDL_Surface *icon; /* The icon */ |
95 }; | 90 }; |
96 | 91 |
97 /* Hidden structure -> variables names */ | 92 /* Hidden structure -> variables names */ |
98 #define VDI_handle (this->hidden->vdi_handle) | 93 #define VDI_handle (this->hidden->vdi_handle) |
99 #define VDI_w (this->hidden->full_w) | 94 #define VDI_w (this->hidden->full_w) |
135 #define SDL_modelist (this->hidden->SDL_modelist) | 130 #define SDL_modelist (this->hidden->SDL_modelist) |
136 #define GEM_icon (this->hidden->icon) | 131 #define GEM_icon (this->hidden->icon) |
137 #define GEM_fullscreen (this->hidden->fullscreen) | 132 #define GEM_fullscreen (this->hidden->fullscreen) |
138 #define GEM_menubar (this->hidden->menubar) | 133 #define GEM_menubar (this->hidden->menubar) |
139 #define GEM_usedevmouse (this->hidden->use_dev_mouse) | 134 #define GEM_usedevmouse (this->hidden->use_dev_mouse) |
140 #define GEM_cursor (this->hidden->cursor) | |
141 | 135 |
142 #define GEM_buffer1 (this->hidden->buffer1) | 136 #define GEM_buffer1 (this->hidden->buffer1) |
143 #define GEM_buffer2 (this->hidden->buffer2) | 137 #define GEM_buffer2 (this->hidden->buffer2) |
144 #define GEM_bufops (this->hidden->buf2scr_ops) | 138 #define GEM_bufops (this->hidden->buf2scr_ops) |
145 | 139 |
187 - C2P from buffer 1 to buffer 2 | 181 - C2P from buffer 1 to buffer 2 |
188 - vro_cpyfm() from buffer 2 to screen | 182 - vro_cpyfm() from buffer 2 to screen |
189 */ | 183 */ |
190 | 184 |
191 #endif /* _SDL_gemvideo_h */ | 185 #endif /* _SDL_gemvideo_h */ |
186 /* vi: set ts=4 sw=4 expandtab: */ |