annotate src/video/SDL_sysvideo.h @ 5153:1435f8a6425c

Nobody is currently maintaining the QNX code, so removing it for now.
author Sam Lantinga <slouken@libsdl.org>
date Tue, 01 Feb 2011 21:40:03 -0800
parents be02be2ea897
children fb424691cfc7
rev   line source
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
1 /*
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
2 SDL - Simple DirectMedia Layer
3697
f7b03b6838cb Fixed bug #926
Sam Lantinga <slouken@libsdl.org>
parents: 3695
diff changeset
3 Copyright (C) 1997-2010 Sam Lantinga
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
4
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
5 This library is free software; you can redistribute it and/or
1312
c9b51268668f Updated copyright information and removed rcs id lines (problematic in branch merges)
Sam Lantinga <slouken@libsdl.org>
parents: 1251
diff changeset
6 modify it under the terms of the GNU Lesser General Public
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
7 License as published by the Free Software Foundation; either
1312
c9b51268668f Updated copyright information and removed rcs id lines (problematic in branch merges)
Sam Lantinga <slouken@libsdl.org>
parents: 1251
diff changeset
8 version 2.1 of the License, or (at your option) any later version.
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
9
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
10 This library is distributed in the hope that it will be useful,
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
1312
c9b51268668f Updated copyright information and removed rcs id lines (problematic in branch merges)
Sam Lantinga <slouken@libsdl.org>
parents: 1251
diff changeset
13 Lesser General Public License for more details.
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
14
1312
c9b51268668f Updated copyright information and removed rcs id lines (problematic in branch merges)
Sam Lantinga <slouken@libsdl.org>
parents: 1251
diff changeset
15 You should have received a copy of the GNU Lesser General Public
c9b51268668f Updated copyright information and removed rcs id lines (problematic in branch merges)
Sam Lantinga <slouken@libsdl.org>
parents: 1251
diff changeset
16 License along with this library; if not, write to the Free Software
c9b51268668f Updated copyright information and removed rcs id lines (problematic in branch merges)
Sam Lantinga <slouken@libsdl.org>
parents: 1251
diff changeset
17 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
18
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
19 Sam Lantinga
252
e8157fcb3114 Updated the source with the correct e-mail address
Sam Lantinga <slouken@libsdl.org>
parents: 173
diff changeset
20 slouken@libsdl.org
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
21 */
1402
d910939febfa Use consistent identifiers for the various platforms we support.
Sam Lantinga <slouken@libsdl.org>
parents: 1361
diff changeset
22 #include "SDL_config.h"
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
23
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
24 #ifndef _SDL_sysvideo_h
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
25 #define _SDL_sysvideo_h
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
26
5150
ad50b3db78bd The rendering functions take a context so it's clear what window they're drawing to. This also potentially opens to the door to multi-threaded rendering in the future.
Sam Lantinga <slouken@libsdl.org>
parents: 5148
diff changeset
27 #include "SDL_events.h"
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
28 #include "SDL_mouse.h"
2268
4baee598306d Date: Thu, 05 Jul 2007 14:02:33 -0700
Sam Lantinga <slouken@libsdl.org>
parents: 2245
diff changeset
29 #include "SDL_keysym.h"
5148
2f44e6969a59 Split the rendering API out into a separate header file.
Sam Lantinga <slouken@libsdl.org>
parents: 5144
diff changeset
30 #include "SDL_render.h"
4782
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
31 #include "SDL_shape.h"
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
32
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
33 /* The SDL video driver */
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
34
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
35 typedef struct SDL_RenderDriver SDL_RenderDriver;
4782
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
36 typedef struct SDL_WindowShaper SDL_WindowShaper;
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
37 typedef struct SDL_ShapeDriver SDL_ShapeDriver;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
38 typedef struct SDL_VideoDisplay SDL_VideoDisplay;
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
39 typedef struct SDL_VideoDevice SDL_VideoDevice;
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
40
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
41 /* Define the SDL texture structure */
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
42 struct SDL_Texture
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
43 {
3695
f6a8be3fefa0 Added magic to detect already freed or otherwise invalid windows and textures.
Sam Lantinga <slouken@libsdl.org>
parents: 3685
diff changeset
44 const void *magic;
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
45 Uint32 format; /**< The pixel format of the texture */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
46 int access; /**< SDL_TextureAccess */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
47 int w; /**< The width of the texture */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
48 int h; /**< The height of the texture */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
49 int modMode; /**< The texture modulation mode */
4929
aa8888658021 Use the enumerated type for blend and scale mode instead of int
Sam Lantinga <slouken@libsdl.org>
parents: 4862
diff changeset
50 SDL_BlendMode blendMode; /**< The texture blend mode */
3685
64ce267332c6 Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
Sam Lantinga <slouken@libsdl.org>
parents: 3678
diff changeset
51 Uint8 r, g, b, a; /**< Texture modulation values */
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
52
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
53 SDL_Renderer *renderer;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
54
3685
64ce267332c6 Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
Sam Lantinga <slouken@libsdl.org>
parents: 3678
diff changeset
55 void *driverdata; /**< Driver specific texture representation */
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
56
3685
64ce267332c6 Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
Sam Lantinga <slouken@libsdl.org>
parents: 3678
diff changeset
57 SDL_Texture *prev;
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
58 SDL_Texture *next;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
59 };
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
60
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
61 /* Define the SDL renderer structure */
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
62 struct SDL_Renderer
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
63 {
5150
ad50b3db78bd The rendering functions take a context so it's clear what window they're drawing to. This also potentially opens to the door to multi-threaded rendering in the future.
Sam Lantinga <slouken@libsdl.org>
parents: 5148
diff changeset
64 const void *magic;
ad50b3db78bd The rendering functions take a context so it's clear what window they're drawing to. This also potentially opens to the door to multi-threaded rendering in the future.
Sam Lantinga <slouken@libsdl.org>
parents: 5148
diff changeset
65
ad50b3db78bd The rendering functions take a context so it's clear what window they're drawing to. This also potentially opens to the door to multi-threaded rendering in the future.
Sam Lantinga <slouken@libsdl.org>
parents: 5148
diff changeset
66 void (*WindowEvent) (SDL_Renderer * renderer, const SDL_WindowEvent *event);
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
67 int (*CreateTexture) (SDL_Renderer * renderer, SDL_Texture * texture);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
68 int (*QueryTexturePixels) (SDL_Renderer * renderer, SDL_Texture * texture,
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
69 void **pixels, int *pitch);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
70 int (*SetTextureColorMod) (SDL_Renderer * renderer,
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
71 SDL_Texture * texture);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
72 int (*SetTextureAlphaMod) (SDL_Renderer * renderer,
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
73 SDL_Texture * texture);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
74 int (*SetTextureBlendMode) (SDL_Renderer * renderer,
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
75 SDL_Texture * texture);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
76 int (*UpdateTexture) (SDL_Renderer * renderer, SDL_Texture * texture,
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
77 const SDL_Rect * rect, const void *pixels,
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
78 int pitch);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
79 int (*LockTexture) (SDL_Renderer * renderer, SDL_Texture * texture,
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
80 const SDL_Rect * rect, int markDirty, void **pixels,
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
81 int *pitch);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
82 void (*UnlockTexture) (SDL_Renderer * renderer, SDL_Texture * texture);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
83 void (*DirtyTexture) (SDL_Renderer * renderer, SDL_Texture * texture,
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
84 int numrects, const SDL_Rect * rects);
3596
f638ded38b8a Added SDL_RenderClear() as a fast method of clearing the screen to the drawing color.
Sam Lantinga <slouken@libsdl.org>
parents: 3536
diff changeset
85 int (*RenderClear) (SDL_Renderer * renderer);
f638ded38b8a Added SDL_RenderClear() as a fast method of clearing the screen to the drawing color.
Sam Lantinga <slouken@libsdl.org>
parents: 3536
diff changeset
86 int (*RenderDrawPoints) (SDL_Renderer * renderer, const SDL_Point * points,
f638ded38b8a Added SDL_RenderClear() as a fast method of clearing the screen to the drawing color.
Sam Lantinga <slouken@libsdl.org>
parents: 3536
diff changeset
87 int count);
f638ded38b8a Added SDL_RenderClear() as a fast method of clearing the screen to the drawing color.
Sam Lantinga <slouken@libsdl.org>
parents: 3536
diff changeset
88 int (*RenderDrawLines) (SDL_Renderer * renderer, const SDL_Point * points,
f638ded38b8a Added SDL_RenderClear() as a fast method of clearing the screen to the drawing color.
Sam Lantinga <slouken@libsdl.org>
parents: 3536
diff changeset
89 int count);
f638ded38b8a Added SDL_RenderClear() as a fast method of clearing the screen to the drawing color.
Sam Lantinga <slouken@libsdl.org>
parents: 3536
diff changeset
90 int (*RenderFillRects) (SDL_Renderer * renderer, const SDL_Rect ** rects,
f638ded38b8a Added SDL_RenderClear() as a fast method of clearing the screen to the drawing color.
Sam Lantinga <slouken@libsdl.org>
parents: 3536
diff changeset
91 int count);
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
92 int (*RenderCopy) (SDL_Renderer * renderer, SDL_Texture * texture,
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
93 const SDL_Rect * srcrect, const SDL_Rect * dstrect);
3427
36cf454ba065 Work in progress on implementation of SDL_RenderReadPixels() and SDL_RenderWritePixels(), code untested.
Sam Lantinga <slouken@libsdl.org>
parents: 3417
diff changeset
94 int (*RenderReadPixels) (SDL_Renderer * renderer, const SDL_Rect * rect,
3435
9f62f47d989b You can specify the format for pixel data in SDL_RenderReadPixels() and SDL_RenderWritePixels()
Sam Lantinga <slouken@libsdl.org>
parents: 3427
diff changeset
95 Uint32 format, void * pixels, int pitch);
3427
36cf454ba065 Work in progress on implementation of SDL_RenderReadPixels() and SDL_RenderWritePixels(), code untested.
Sam Lantinga <slouken@libsdl.org>
parents: 3417
diff changeset
96 int (*RenderWritePixels) (SDL_Renderer * renderer, const SDL_Rect * rect,
3435
9f62f47d989b You can specify the format for pixel data in SDL_RenderReadPixels() and SDL_RenderWritePixels()
Sam Lantinga <slouken@libsdl.org>
parents: 3427
diff changeset
97 Uint32 format, const void * pixels, int pitch);
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
98 void (*RenderPresent) (SDL_Renderer * renderer);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
99 void (*DestroyTexture) (SDL_Renderer * renderer, SDL_Texture * texture);
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
100
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
101 void (*DestroyRenderer) (SDL_Renderer * renderer);
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
102
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
103 /* The current renderer info */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
104 SDL_RendererInfo info;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
105
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
106 /* The window associated with the renderer */
3685
64ce267332c6 Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
Sam Lantinga <slouken@libsdl.org>
parents: 3678
diff changeset
107 SDL_Window *window;
64ce267332c6 Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
Sam Lantinga <slouken@libsdl.org>
parents: 3678
diff changeset
108
64ce267332c6 Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
Sam Lantinga <slouken@libsdl.org>
parents: 3678
diff changeset
109 /* The list of textures */
64ce267332c6 Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
Sam Lantinga <slouken@libsdl.org>
parents: 3678
diff changeset
110 SDL_Texture *textures;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
111
2884
9dde605c7540 Date: Fri, 19 Dec 2008 20:17:35 +0100
Sam Lantinga <slouken@libsdl.org>
parents: 2859
diff changeset
112 Uint8 r, g, b, a; /**< Color for drawing operations values */
4929
aa8888658021 Use the enumerated type for blend and scale mode instead of int
Sam Lantinga <slouken@libsdl.org>
parents: 4862
diff changeset
113 SDL_BlendMode blendMode; /**< The drawing blend mode */
2884
9dde605c7540 Date: Fri, 19 Dec 2008 20:17:35 +0100
Sam Lantinga <slouken@libsdl.org>
parents: 2859
diff changeset
114
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
115 void *driverdata;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
116 };
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
117
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
118 /* Define the SDL render driver structure */
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
119 struct SDL_RenderDriver
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
120 {
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
121 SDL_Renderer *(*CreateRenderer) (SDL_Window * window, Uint32 flags);
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
122
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
123 /* Info about the renderer capabilities */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
124 SDL_RendererInfo info;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
125 };
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
126
4782
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
127 /* Define the SDL window-shaper structure */
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
128 struct SDL_WindowShaper
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
129 {
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
130 /* The window associated with the shaper */
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
131 SDL_Window *window;
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
132
4851
5624fb0190b5 Changed flags and positioning (for the fake-hiding) as Andreas recommended.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 4849
diff changeset
133 /* The user's specified coordinates for the window, for once we give it a shape. */
5624fb0190b5 Changed flags and positioning (for the fake-hiding) as Andreas recommended.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 4849
diff changeset
134 Uint32 userx,usery;
4782
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
135
4807
c9eb95f29770 Added color-key mode and redid the code to work with it.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 4782
diff changeset
136 /* The parameters for shape calculation. */
c9eb95f29770 Added color-key mode and redid the code to work with it.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 4782
diff changeset
137 SDL_WindowShapeMode mode;
4782
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
138
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
139 /* Has this window been assigned a shape? */
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
140 SDL_bool hasshape;
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
141
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
142 void *driverdata;
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
143 };
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
144
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
145 /* Define the SDL shape driver structure */
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
146 struct SDL_ShapeDriver
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
147 {
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
148 SDL_WindowShaper *(*CreateShaper)(SDL_Window * window);
4849
0b918c186938 Finally got the Win32 API code for shaping to work! Just need to fix SDL_CalculateShapeTree() now!
egottlieb
parents: 4810
diff changeset
149 int (*SetWindowShape)(SDL_WindowShaper *shaper,SDL_Surface *shape,SDL_WindowShapeMode *shape_mode);
4782
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
150 int (*ResizeWindowShape)(SDL_Window *window);
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
151 };
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
152
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
153 /* Define the SDL window structure, corresponding to toplevel windows */
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
154 struct SDL_Window
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
155 {
3695
f6a8be3fefa0 Added magic to detect already freed or otherwise invalid windows and textures.
Sam Lantinga <slouken@libsdl.org>
parents: 3685
diff changeset
156 const void *magic;
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
157 Uint32 id;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
158 char *title;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
159 int x, y;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
160 int w, h;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
161 Uint32 flags;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
162
3685
64ce267332c6 Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
Sam Lantinga <slouken@libsdl.org>
parents: 3678
diff changeset
163 SDL_VideoDisplay *display;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
164
3500
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
165 SDL_DisplayMode fullscreen_mode;
4782
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
166
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
167 SDL_WindowShaper *shaper;
3500
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
168
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
169 void *userdata;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
170 void *driverdata;
3685
64ce267332c6 Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
Sam Lantinga <slouken@libsdl.org>
parents: 3678
diff changeset
171
64ce267332c6 Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
Sam Lantinga <slouken@libsdl.org>
parents: 3678
diff changeset
172 SDL_Window *prev;
64ce267332c6 Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
Sam Lantinga <slouken@libsdl.org>
parents: 3678
diff changeset
173 SDL_Window *next;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
174 };
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
175 #define FULLSCREEN_VISIBLE(W) \
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
176 (((W)->flags & SDL_WINDOW_FULLSCREEN) && \
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
177 ((W)->flags & SDL_WINDOW_SHOWN) && \
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
178 !((W)->flags & SDL_WINDOW_MINIMIZED))
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
179
2742
b86247d21929 Added retained backing attribute, reference to UIKit renderer
Holmes Futrell <hfutrell@umail.ucsb.edu>
parents: 2735
diff changeset
180 /*
b86247d21929 Added retained backing attribute, reference to UIKit renderer
Holmes Futrell <hfutrell@umail.ucsb.edu>
parents: 2735
diff changeset
181 * Define the SDL display structure This corresponds to physical monitors
b86247d21929 Added retained backing attribute, reference to UIKit renderer
Holmes Futrell <hfutrell@umail.ucsb.edu>
parents: 2735
diff changeset
182 * attached to the system.
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
183 */
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
184 struct SDL_VideoDisplay
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
185 {
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
186 int max_display_modes;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
187 int num_display_modes;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
188 SDL_DisplayMode *display_modes;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
189 SDL_DisplayMode desktop_mode;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
190 SDL_DisplayMode current_mode;
3502
98a819296cdc Whenever a window becomes fullscreen, shown, unminimized, and has input focus it will change the display to the corresponding fullscreen video mode.
Sam Lantinga <slouken@libsdl.org>
parents: 3501
diff changeset
191 SDL_bool updating_fullscreen;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
192
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
193 Uint16 *gamma;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
194 Uint16 *saved_gamma; /* (just offset into gamma) */
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
195
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
196 int num_render_drivers;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
197 SDL_RenderDriver *render_drivers;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
198
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
199 SDL_Window *windows;
3517
e7eec78e4b92 Fixed mouse events for fullscreen windows on Mac OS X
Sam Lantinga <slouken@libsdl.org>
parents: 3511
diff changeset
200 SDL_Window *fullscreen_window;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
201
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
202 SDL_VideoDevice *device;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
203
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
204 void *driverdata;
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
205 };
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
206
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
207 /* Define the SDL video driver structure */
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
208 #define _THIS SDL_VideoDevice *_this
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
209
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
210 struct SDL_VideoDevice
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
211 {
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
212 /* * * */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
213 /* The name of this video driver */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
214 const char *name;
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
215
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
216 /* * * */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
217 /* Initialization/Query functions */
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
218
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
219 /*
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
220 * Initialize the native video subsystem, filling in the list of
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
221 * displays for this driver, returning 0 or -1 if there's an error.
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
222 */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
223 int (*VideoInit) (_THIS);
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
224
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
225 /*
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
226 * Reverse the effects VideoInit() -- called if VideoInit() fails or
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
227 * if the application is shutting down the video subsystem.
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
228 */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
229 void (*VideoQuit) (_THIS);
1913
83420da906a5 Implemented Windows OpenGL support
Sam Lantinga <slouken@libsdl.org>
parents: 1912
diff changeset
230
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
231 /* * * */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
232 /*
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
233 * Display functions
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
234 */
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
235
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
236 /*
3528
59ff7a2beb57 Added an API function to query geometry of multiple monitors:
Sam Lantinga <slouken@libsdl.org>
parents: 3517
diff changeset
237 * Get the bounds of a display
59ff7a2beb57 Added an API function to query geometry of multiple monitors:
Sam Lantinga <slouken@libsdl.org>
parents: 3517
diff changeset
238 */
59ff7a2beb57 Added an API function to query geometry of multiple monitors:
Sam Lantinga <slouken@libsdl.org>
parents: 3517
diff changeset
239 int (*GetDisplayBounds) (_THIS, SDL_VideoDisplay * display, SDL_Rect * rect);
59ff7a2beb57 Added an API function to query geometry of multiple monitors:
Sam Lantinga <slouken@libsdl.org>
parents: 3517
diff changeset
240
59ff7a2beb57 Added an API function to query geometry of multiple monitors:
Sam Lantinga <slouken@libsdl.org>
parents: 3517
diff changeset
241 /*
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
242 * Get a list of the available display modes. e.g.
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
243 * SDL_AddDisplayMode(_this->current_display, mode)
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
244 */
3500
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
245 void (*GetDisplayModes) (_THIS, SDL_VideoDisplay * display);
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
246
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
247 /*
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
248 * Setting the display mode is independent of creating windows, so
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
249 * when the display mode is changed, all existing windows should have
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
250 * their data updated accordingly, including the display surfaces
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
251 * associated with them.
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
252 */
3500
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
253 int (*SetDisplayMode) (_THIS, SDL_VideoDisplay * display, SDL_DisplayMode * mode);
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
254
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
255 /* Set the gamma ramp */
3500
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
256 int (*SetDisplayGammaRamp) (_THIS, SDL_VideoDisplay * display, Uint16 * ramp);
2742
b86247d21929 Added retained backing attribute, reference to UIKit renderer
Holmes Futrell <hfutrell@umail.ucsb.edu>
parents: 2735
diff changeset
257
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
258 /* Get the gamma ramp */
3500
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
259 int (*GetDisplayGammaRamp) (_THIS, SDL_VideoDisplay * display, Uint16 * ramp);
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
260
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
261 /* * * */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
262 /*
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
263 * Window functions
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
264 */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
265 int (*CreateWindow) (_THIS, SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
266 int (*CreateWindowFrom) (_THIS, SDL_Window * window, const void *data);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
267 void (*SetWindowTitle) (_THIS, SDL_Window * window);
2967
e4a469d6ddab Implemented SDL_SetWindowIcon(), with translucent icon support under X11.
Sam Lantinga <slouken@libsdl.org>
parents: 2901
diff changeset
268 void (*SetWindowIcon) (_THIS, SDL_Window * window, SDL_Surface * icon);
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
269 void (*SetWindowPosition) (_THIS, SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
270 void (*SetWindowSize) (_THIS, SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
271 void (*ShowWindow) (_THIS, SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
272 void (*HideWindow) (_THIS, SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
273 void (*RaiseWindow) (_THIS, SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
274 void (*MaximizeWindow) (_THIS, SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
275 void (*MinimizeWindow) (_THIS, SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
276 void (*RestoreWindow) (_THIS, SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
277 void (*SetWindowGrab) (_THIS, SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
278 void (*DestroyWindow) (_THIS, SDL_Window * window);
4782
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
279
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
280 /* * * */
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
281 /*
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
282 * Shaped-window functions
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
283 */
b6930aefd008 Finished X11 shaped-window functionality and removed ellipse+polygon rendering.
Eli Gottlieb <eligottlieb@gmail.com>
parents: 3701
diff changeset
284 SDL_ShapeDriver shape_driver;
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
285
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
286 /* Get some platform dependent window information */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
287 SDL_bool(*GetWindowWMInfo) (_THIS, SDL_Window * window,
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
288 struct SDL_SysWMinfo * info);
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
289
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
290 /* * * */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
291 /*
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
292 * OpenGL support
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
293 */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
294 int (*GL_LoadLibrary) (_THIS, const char *path);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
295 void *(*GL_GetProcAddress) (_THIS, const char *proc);
3057
089a77aebb7d Added test program for SDL_CreateWindowFrom()
Sam Lantinga <slouken@libsdl.org>
parents: 3025
diff changeset
296 void (*GL_UnloadLibrary) (_THIS);
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
297 SDL_GLContext(*GL_CreateContext) (_THIS, SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
298 int (*GL_MakeCurrent) (_THIS, SDL_Window * window, SDL_GLContext context);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
299 int (*GL_SetSwapInterval) (_THIS, int interval);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
300 int (*GL_GetSwapInterval) (_THIS);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
301 void (*GL_SwapWindow) (_THIS, SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
302 void (*GL_DeleteContext) (_THIS, SDL_GLContext context);
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
303
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
304 /* * * */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
305 /*
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
306 * Event manager functions
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
307 */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
308 void (*PumpEvents) (_THIS);
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
309
3025
54fac87e1f34 Added an API to enable/disable the screen saver.
Sam Lantinga <slouken@libsdl.org>
parents: 2967
diff changeset
310 /* Suspend the screensaver */
54fac87e1f34 Added an API to enable/disable the screen saver.
Sam Lantinga <slouken@libsdl.org>
parents: 2967
diff changeset
311 void (*SuspendScreenSaver) (_THIS);
54fac87e1f34 Added an API to enable/disable the screen saver.
Sam Lantinga <slouken@libsdl.org>
parents: 2967
diff changeset
312
3280
00cace2d9080 Merged a cleaned up version of Jiang's code changes from Google Summer of Code 2009
Sam Lantinga <slouken@libsdl.org>
parents: 3276
diff changeset
313 /* Text input */
00cace2d9080 Merged a cleaned up version of Jiang's code changes from Google Summer of Code 2009
Sam Lantinga <slouken@libsdl.org>
parents: 3276
diff changeset
314 void (*StartTextInput) (_THIS);
00cace2d9080 Merged a cleaned up version of Jiang's code changes from Google Summer of Code 2009
Sam Lantinga <slouken@libsdl.org>
parents: 3276
diff changeset
315 void (*StopTextInput) (_THIS);
00cace2d9080 Merged a cleaned up version of Jiang's code changes from Google Summer of Code 2009
Sam Lantinga <slouken@libsdl.org>
parents: 3276
diff changeset
316 void (*SetTextInputRect) (_THIS, SDL_Rect *rect);
00cace2d9080 Merged a cleaned up version of Jiang's code changes from Google Summer of Code 2009
Sam Lantinga <slouken@libsdl.org>
parents: 3276
diff changeset
317
4495
dbbfdb9ea716 Simplified clipboard API for sanity's sake.
Sam Lantinga <slouken@libsdl.org>
parents: 4472
diff changeset
318 /* Clipboard */
dbbfdb9ea716 Simplified clipboard API for sanity's sake.
Sam Lantinga <slouken@libsdl.org>
parents: 4472
diff changeset
319 int (*SetClipboardText) (_THIS, const char *text);
dbbfdb9ea716 Simplified clipboard API for sanity's sake.
Sam Lantinga <slouken@libsdl.org>
parents: 4472
diff changeset
320 char * (*GetClipboardText) (_THIS);
dbbfdb9ea716 Simplified clipboard API for sanity's sake.
Sam Lantinga <slouken@libsdl.org>
parents: 4472
diff changeset
321 SDL_bool (*HasClipboardText) (_THIS);
dbbfdb9ea716 Simplified clipboard API for sanity's sake.
Sam Lantinga <slouken@libsdl.org>
parents: 4472
diff changeset
322
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
323 /* * * */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
324 /* Data common to all drivers */
3025
54fac87e1f34 Added an API to enable/disable the screen saver.
Sam Lantinga <slouken@libsdl.org>
parents: 2967
diff changeset
325 SDL_bool suspend_screensaver;
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
326 int num_displays;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
327 SDL_VideoDisplay *displays;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
328 int current_display;
3695
f6a8be3fefa0 Added magic to detect already freed or otherwise invalid windows and textures.
Sam Lantinga <slouken@libsdl.org>
parents: 3685
diff changeset
329 Uint8 window_magic;
5150
ad50b3db78bd The rendering functions take a context so it's clear what window they're drawing to. This also potentially opens to the door to multi-threaded rendering in the future.
Sam Lantinga <slouken@libsdl.org>
parents: 5148
diff changeset
330 Uint8 renderer_magic;
3695
f6a8be3fefa0 Added magic to detect already freed or otherwise invalid windows and textures.
Sam Lantinga <slouken@libsdl.org>
parents: 3685
diff changeset
331 Uint8 texture_magic;
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
332 Uint32 next_object_id;
4495
dbbfdb9ea716 Simplified clipboard API for sanity's sake.
Sam Lantinga <slouken@libsdl.org>
parents: 4472
diff changeset
333 char * clipboard_text;
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
334
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
335 /* * * */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
336 /* Data used by the GL drivers */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
337 struct
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
338 {
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
339 int red_size;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
340 int green_size;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
341 int blue_size;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
342 int alpha_size;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
343 int depth_size;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
344 int buffer_size;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
345 int stencil_size;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
346 int double_buffer;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
347 int accum_red_size;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
348 int accum_green_size;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
349 int accum_blue_size;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
350 int accum_alpha_size;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
351 int stereo;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
352 int multisamplebuffers;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
353 int multisamplesamples;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
354 int accelerated;
3100
7dc982143c06 Date: Sun, 22 Mar 2009 12:52:29 +0000
Sam Lantinga <slouken@libsdl.org>
parents: 3083
diff changeset
355 int major_version;
7dc982143c06 Date: Sun, 22 Mar 2009 12:52:29 +0000
Sam Lantinga <slouken@libsdl.org>
parents: 3083
diff changeset
356 int minor_version;
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
357 int retained_backing;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
358 int driver_loaded;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
359 char driver_path[256];
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
360 void *dll_handle;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
361 } gl_config;
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
362
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
363 /* * * */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
364 /* Data private to this driver */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
365 void *driverdata;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
366 struct SDL_GLDriverData *gl_data;
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
367
3161
494559cc723b OpenPandora support added by David Carré
Sam Lantinga <slouken@libsdl.org>
parents: 3100
diff changeset
368 #if SDL_VIDEO_DRIVER_PANDORA
494559cc723b OpenPandora support added by David Carré
Sam Lantinga <slouken@libsdl.org>
parents: 3100
diff changeset
369 struct SDL_PrivateGLESData *gles_data;
494559cc723b OpenPandora support added by David Carré
Sam Lantinga <slouken@libsdl.org>
parents: 3100
diff changeset
370 #endif
494559cc723b OpenPandora support added by David Carré
Sam Lantinga <slouken@libsdl.org>
parents: 3100
diff changeset
371
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
372 /* * * */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
373 /* The function used to dispose of this structure */
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
374 void (*free) (_THIS);
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
375 };
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
376
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
377 typedef struct VideoBootStrap
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
378 {
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
379 const char *name;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
380 const char *desc;
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
381 int (*available) (void);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
382 SDL_VideoDevice *(*create) (int devindex);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
383 } VideoBootStrap;
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
384
1931
103c6fec2a60 The Mac OS X Cocoa video driver is under construction...
Sam Lantinga <slouken@libsdl.org>
parents: 1928
diff changeset
385 #if SDL_VIDEO_DRIVER_COCOA
103c6fec2a60 The Mac OS X Cocoa video driver is under construction...
Sam Lantinga <slouken@libsdl.org>
parents: 1928
diff changeset
386 extern VideoBootStrap COCOA_bootstrap;
1361
19418e4422cb New configure-based build system. Still work in progress, but much improved
Sam Lantinga <slouken@libsdl.org>
parents: 1330
diff changeset
387 #endif
19418e4422cb New configure-based build system. Still work in progress, but much improved
Sam Lantinga <slouken@libsdl.org>
parents: 1330
diff changeset
388 #if SDL_VIDEO_DRIVER_X11
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
389 extern VideoBootStrap X11_bootstrap;
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
390 #endif
1361
19418e4422cb New configure-based build system. Still work in progress, but much improved
Sam Lantinga <slouken@libsdl.org>
parents: 1330
diff changeset
391 #if SDL_VIDEO_DRIVER_DIRECTFB
167
cb384ef627f6 Added support for DirectFB video on Linux (thanks Denis!)
Sam Lantinga <slouken@libsdl.org>
parents: 75
diff changeset
392 extern VideoBootStrap DirectFB_bootstrap;
cb384ef627f6 Added support for DirectFB video on Linux (thanks Denis!)
Sam Lantinga <slouken@libsdl.org>
parents: 75
diff changeset
393 #endif
5062
e8916fe9cfc8 Fixed bug #925
Sam Lantinga <slouken@libsdl.org>
parents: 5048
diff changeset
394 #if SDL_VIDEO_DRIVER_WINDOWS
e8916fe9cfc8 Fixed bug #925
Sam Lantinga <slouken@libsdl.org>
parents: 5048
diff changeset
395 extern VideoBootStrap WINDOWS_bootstrap;
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
396 #endif
1361
19418e4422cb New configure-based build system. Still work in progress, but much improved
Sam Lantinga <slouken@libsdl.org>
parents: 1330
diff changeset
397 #if SDL_VIDEO_DRIVER_BWINDOW
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
398 extern VideoBootStrap BWINDOW_bootstrap;
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
399 #endif
5153
1435f8a6425c Nobody is currently maintaining the QNX code, so removing it for now.
Sam Lantinga <slouken@libsdl.org>
parents: 5152
diff changeset
400 #if SDL_VIDEO_DRIVER_PANDORA
1435f8a6425c Nobody is currently maintaining the QNX code, so removing it for now.
Sam Lantinga <slouken@libsdl.org>
parents: 5152
diff changeset
401 extern VideoBootStrap PND_bootstrap;
3083
0bc41e0361d3 Date: Mon, 2 Mar 2009 16:27:42 +0200
Sam Lantinga <slouken@libsdl.org>
parents: 3057
diff changeset
402 #endif
5153
1435f8a6425c Nobody is currently maintaining the QNX code, so removing it for now.
Sam Lantinga <slouken@libsdl.org>
parents: 5152
diff changeset
403 #if SDL_VIDEO_DRIVER_NDS
1435f8a6425c Nobody is currently maintaining the QNX code, so removing it for now.
Sam Lantinga <slouken@libsdl.org>
parents: 5152
diff changeset
404 extern VideoBootStrap NDS_bootstrap;
173
83018110dce8 Added initial support for EPOC/Symbian OS (thanks Hannu!)
Sam Lantinga <slouken@libsdl.org>
parents: 167
diff changeset
405 #endif
2742
b86247d21929 Added retained backing attribute, reference to UIKit renderer
Holmes Futrell <hfutrell@umail.ucsb.edu>
parents: 2735
diff changeset
406 #if SDL_VIDEO_DRIVER_UIKIT
b86247d21929 Added retained backing attribute, reference to UIKit renderer
Holmes Futrell <hfutrell@umail.ucsb.edu>
parents: 2735
diff changeset
407 extern VideoBootStrap UIKIT_bootstrap;
b86247d21929 Added retained backing attribute, reference to UIKit renderer
Holmes Futrell <hfutrell@umail.ucsb.edu>
parents: 2735
diff changeset
408 #endif
5153
1435f8a6425c Nobody is currently maintaining the QNX code, so removing it for now.
Sam Lantinga <slouken@libsdl.org>
parents: 5152
diff changeset
409 #if SDL_VIDEO_DRIVER_ANDROID
1435f8a6425c Nobody is currently maintaining the QNX code, so removing it for now.
Sam Lantinga <slouken@libsdl.org>
parents: 5152
diff changeset
410 extern VideoBootStrap Android_bootstrap;
1435f8a6425c Nobody is currently maintaining the QNX code, so removing it for now.
Sam Lantinga <slouken@libsdl.org>
parents: 5152
diff changeset
411 #endif
1361
19418e4422cb New configure-based build system. Still work in progress, but much improved
Sam Lantinga <slouken@libsdl.org>
parents: 1330
diff changeset
412 #if SDL_VIDEO_DRIVER_DUMMY
19418e4422cb New configure-based build system. Still work in progress, but much improved
Sam Lantinga <slouken@libsdl.org>
parents: 1330
diff changeset
413 extern VideoBootStrap DUMMY_bootstrap;
19418e4422cb New configure-based build system. Still work in progress, but much improved
Sam Lantinga <slouken@libsdl.org>
parents: 1330
diff changeset
414 #endif
19418e4422cb New configure-based build system. Still work in progress, but much improved
Sam Lantinga <slouken@libsdl.org>
parents: 1330
diff changeset
415
3685
64ce267332c6 Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
Sam Lantinga <slouken@libsdl.org>
parents: 3678
diff changeset
416 #define SDL_CurrentDisplay (&_this->displays[_this->current_display])
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
417
4472
791b3256fb22 Mostly cleaned up warnings with -Wmissing-prototypes
Sam Lantinga <slouken@libsdl.org>
parents: 3701
diff changeset
418 extern SDL_VideoDevice *SDL_GetVideoDevice(void);
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
419 extern int SDL_AddBasicVideoDisplay(const SDL_DisplayMode * desktop_mode);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
420 extern int SDL_AddVideoDisplay(const SDL_VideoDisplay * display);
3500
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
421 extern SDL_bool SDL_AddDisplayMode(SDL_VideoDisplay *display, const SDL_DisplayMode * mode);
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
422 extern int SDL_GetNumDisplayModesForDisplay(SDL_VideoDisplay * display);
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
423 extern int SDL_GetDisplayModeForDisplay(SDL_VideoDisplay * display, int index, SDL_DisplayMode * mode);
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
424 extern int SDL_GetDesktopDisplayModeForDisplay(SDL_VideoDisplay * display, SDL_DisplayMode * mode);
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
425 extern int SDL_GetCurrentDisplayModeForDisplay(SDL_VideoDisplay * display, SDL_DisplayMode * mode);
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
426 extern SDL_DisplayMode * SDL_GetClosestDisplayModeForDisplay(SDL_VideoDisplay * display, const SDL_DisplayMode * mode, SDL_DisplayMode * closest);
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
427 extern int SDL_SetDisplayModeForDisplay(SDL_VideoDisplay * display, const SDL_DisplayMode * mode);
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
428 extern int SDL_SetGammaRampForDisplay(SDL_VideoDisplay * display, const Uint16 * red, const Uint16 * green, const Uint16 * blue);
4b594623401b Work in progress on multi-display support:
Sam Lantinga <slouken@libsdl.org>
parents: 3435
diff changeset
429 extern int SDL_GetGammaRampForDisplay(SDL_VideoDisplay * display, Uint16 * red, Uint16 * green, Uint16 * blue);
3501
467e67d301f3 Removed a little redundancy in the naming
Sam Lantinga <slouken@libsdl.org>
parents: 3500
diff changeset
430 extern void SDL_AddRenderDriver(SDL_VideoDisplay *display, const SDL_RenderDriver * driver);
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
431
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
432 extern int SDL_RecreateWindow(SDL_Window * window, Uint32 flags);
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
433
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
434 extern void SDL_OnWindowShown(SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
435 extern void SDL_OnWindowHidden(SDL_Window * window);
3502
98a819296cdc Whenever a window becomes fullscreen, shown, unminimized, and has input focus it will change the display to the corresponding fullscreen video mode.
Sam Lantinga <slouken@libsdl.org>
parents: 3501
diff changeset
436 extern void SDL_OnWindowMinimized(SDL_Window * window);
98a819296cdc Whenever a window becomes fullscreen, shown, unminimized, and has input focus it will change the display to the corresponding fullscreen video mode.
Sam Lantinga <slouken@libsdl.org>
parents: 3501
diff changeset
437 extern void SDL_OnWindowRestored(SDL_Window * window);
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
438 extern void SDL_OnWindowFocusGained(SDL_Window * window);
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
439 extern void SDL_OnWindowFocusLost(SDL_Window * window);
3685
64ce267332c6 Switched from SDL_WindowID and SDL_TextureID to SDL_Window* and SDL_Texture* for code simplicity and improved performance.
Sam Lantinga <slouken@libsdl.org>
parents: 3678
diff changeset
440 extern SDL_Window * SDL_GetFocusWindow(void);
0
74212992fb08 Initial revision
Sam Lantinga <slouken@lokigames.com>
parents:
diff changeset
441
2753
Sam Lantinga <slouken@libsdl.org>
parents: 2742
diff changeset
442 #endif /* _SDL_sysvideo_h */
1895
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
443
c121d94672cb SDL 1.2 is moving to a branch, and SDL 1.3 is becoming the head.
Sam Lantinga <slouken@libsdl.org>
parents: 1737
diff changeset
444 /* vi: set ts=4 sw=4 expandtab: */