comparison src/video/gem/SDL_gemvideo.h @ 984:44fd54a0ae5f

Add OSMesa OpenGL support to the Atari GEM video driver
author Patrice Mandin <patmandin@gmail.com>
date Sun, 21 Nov 2004 21:59:47 +0000
parents d9209754ebee
children 475166d13b44
comparison
equal deleted inserted replaced
983:7f08bd66f1ca 984:44fd54a0ae5f
25 "@(#) $Id$"; 25 "@(#) $Id$";
26 #endif 26 #endif
27 27
28 #ifndef _SDL_gemvideo_h 28 #ifndef _SDL_gemvideo_h
29 #define _SDL_gemvideo_h 29 #define _SDL_gemvideo_h
30
31 #ifdef HAVE_OPENGL
32 #include <GL/osmesa.h>
33 #endif
30 34
31 #include "SDL_sysvideo.h" 35 #include "SDL_sysvideo.h"
32 #include "SDL_mutex.h" 36 #include "SDL_mutex.h"
33 37
34 /* Hidden "this" pointer for the video functions */ 38 /* Hidden "this" pointer for the video functions */
83 short message[8]; /* To self-send an AES message */ 87 short message[8]; /* To self-send an AES message */
84 88
85 SDL_bool fullscreen; /* Fullscreen or windowed mode ? */ 89 SDL_bool fullscreen; /* Fullscreen or windowed mode ? */
86 SDL_Rect *SDL_modelist[SDL_NUMMODES+1]; /* Mode list */ 90 SDL_Rect *SDL_modelist[SDL_NUMMODES+1]; /* Mode list */
87 SDL_Surface *icon; /* The icon */ 91 SDL_Surface *icon; /* The icon */
92
93 #ifdef HAVE_OPENGL
94 OSMesaContext ctx; /* OSMesa OpenGL context */
95 #endif
88 }; 96 };
89 97
90 /* Hidden structure -> variables names */ 98 /* Hidden structure -> variables names */
91 #define VDI_handle (this->hidden->vdi_handle) 99 #define VDI_handle (this->hidden->vdi_handle)
92 #define VDI_w (this->hidden->full_w) 100 #define VDI_w (this->hidden->full_w)
128 #define GEM_fullscreen (this->hidden->fullscreen) 136 #define GEM_fullscreen (this->hidden->fullscreen)
129 137
130 #define GEM_buffer1 (this->hidden->buffer1) 138 #define GEM_buffer1 (this->hidden->buffer1)
131 #define GEM_buffer2 (this->hidden->buffer2) 139 #define GEM_buffer2 (this->hidden->buffer2)
132 #define GEM_bufops (this->hidden->buf2scr_ops) 140 #define GEM_bufops (this->hidden->buf2scr_ops)
141
142 #define GEM_ctx (this->hidden->ctx)
133 143
134 #define VDI_FBMASK(amask, rmask, gmask, bmask) \ 144 #define VDI_FBMASK(amask, rmask, gmask, bmask) \
135 VDI_alphamask = (amask); \ 145 VDI_alphamask = (amask); \
136 VDI_redmask = (rmask); \ 146 VDI_redmask = (rmask); \
137 VDI_greenmask = (gmask); \ 147 VDI_greenmask = (gmask); \