Mercurial > sdl-ios-xcode
annotate src/video/wincommon/SDL_wingl_c.h @ 311:2847fd83f115
Date: Fri, 15 Mar 2002 18:24:59 GMT+1
From: Patrice Mandin <pmandin@caramail.com>
Subject: [SDL] [PATCH] Atari port, bug in xbios driver driver
Hello,
This patch correct a stupid mistake in the FlipHWSurface
function, where I forgot to update surface->pixels when
using a double buffered surface.
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Wed, 20 Mar 2002 02:24:29 +0000 |
parents | f6ffac90895c |
children | 9c42ee1b7d77 |
rev | line source |
---|---|
0 | 1 /* |
2 SDL - Simple DirectMedia Layer | |
297
f6ffac90895c
Updated copyright information for 2002
Sam Lantinga <slouken@libsdl.org>
parents:
252
diff
changeset
|
3 Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002 Sam Lantinga |
0 | 4 |
5 This library is free software; you can redistribute it and/or | |
6 modify it under the terms of the GNU Library General Public | |
7 License as published by the Free Software Foundation; either | |
8 version 2 of the License, or (at your option) any later version. | |
9 | |
10 This library is distributed in the hope that it will be useful, | |
11 but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 Library General Public License for more details. | |
14 | |
15 You should have received a copy of the GNU Library General Public | |
16 License along with this library; if not, write to the Free | |
17 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | |
18 | |
19 Sam Lantinga | |
252
e8157fcb3114
Updated the source with the correct e-mail address
Sam Lantinga <slouken@libsdl.org>
parents:
0
diff
changeset
|
20 slouken@libsdl.org |
0 | 21 */ |
22 | |
23 #ifdef SAVE_RCSID | |
24 static char rcsid = | |
25 "@(#) $Id$"; | |
26 #endif | |
27 | |
28 /* WGL implementation of SDL OpenGL support */ | |
29 | |
30 #include "SDL_sysvideo.h" | |
31 | |
32 | |
33 struct SDL_PrivateGLData { | |
34 int gl_active; /* to stop switching drivers while we have a valid context */ | |
35 | |
36 #ifdef HAVE_OPENGL | |
37 PIXELFORMATDESCRIPTOR GL_pfd; | |
38 HDC GL_hdc; | |
39 HGLRC GL_hrc; | |
40 | |
41 void * (WINAPI *wglGetProcAddress)(const char *proc); | |
42 | |
43 HGLRC (WINAPI *wglCreateContext)(HDC hdc); | |
44 | |
45 BOOL (WINAPI *wglDeleteContext)(HGLRC hglrc); | |
46 | |
47 BOOL (WINAPI *wglMakeCurrent)(HDC hdc, HGLRC hglrc); | |
48 | |
49 #endif /* HAVE_OPENGL */ | |
50 }; | |
51 | |
52 /* Old variable names */ | |
53 #define gl_active (this->gl_data->gl_active) | |
54 #define GL_pfd (this->gl_data->GL_pfd) | |
55 #define GL_hdc (this->gl_data->GL_hdc) | |
56 #define GL_hrc (this->gl_data->GL_hrc) | |
57 | |
58 /* OpenGL functions */ | |
59 extern int WIN_GL_SetupWindow(_THIS); | |
60 extern void WIN_GL_ShutDown(_THIS); | |
61 #ifdef HAVE_OPENGL | |
62 extern int WIN_GL_MakeCurrent(_THIS); | |
63 extern int WIN_GL_GetAttribute(_THIS, SDL_GLattr attrib, int* value); | |
64 extern void WIN_GL_SwapBuffers(_THIS); | |
65 extern void WIN_GL_UnloadLibrary(_THIS); | |
66 extern int WIN_GL_LoadLibrary(_THIS, const char* path); | |
67 extern void *WIN_GL_GetProcAddress(_THIS, const char* proc); | |
68 #endif | |
69 |