1 /* GdkGLExt - OpenGL Extension to GDK
2  * Copyright (C) 2002-2004  Naofumi Yasufuku
3  *
4  * This library is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Lesser General Public
6  * License as published by the Free Software Foundation; either
7  * version 2.1 of the License, or (at your option) any later version.
8  *
9  * This library is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12  * Lesser General Public License for more details.
13  *
14  * You should have received a copy of the GNU Lesser General Public
15  * License along with this library; if not, write to the Free Software
16  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307  USA.
17  */
18 
19 #ifndef __GDK_GL_CONFIG_X11_H__
20 #define __GDK_GL_CONFIG_X11_H__
21 
22 #include <gdk/gdkglconfig.h>
23 #include <gdk/x11/gdkglx.h>
24 
25 G_BEGIN_DECLS
26 
27 typedef struct _GdkGLConfigImplX11      GdkGLConfigImplX11;
28 typedef struct _GdkGLConfigImplX11Class GdkGLConfigImplX11Class;
29 
30 #define GDK_TYPE_GL_CONFIG_IMPL_X11              (gdk_gl_config_impl_x11_get_type ())
31 #define GDK_GL_CONFIG_IMPL_X11(object)           (G_TYPE_CHECK_INSTANCE_CAST ((object), GDK_TYPE_GL_CONFIG_IMPL_X11, GdkGLConfigImplX11))
32 #define GDK_GL_CONFIG_IMPL_X11_CLASS(klass)      (G_TYPE_CHECK_CLASS_CAST ((klass), GDK_TYPE_GL_CONFIG_IMPL_X11, GdkGLConfigImplX11Class))
33 #define GDK_IS_GL_CONFIG_IMPL_X11(object)        (G_TYPE_CHECK_INSTANCE_TYPE ((object), GDK_TYPE_GL_CONFIG_IMPL_X11))
34 #define GDK_IS_GL_CONFIG_IMPL_X11_CLASS(klass)   (G_TYPE_CHECK_CLASS_TYPE ((klass), GDK_TYPE_GL_CONFIG_IMPL_X11))
35 #define GDK_GL_CONFIG_IMPL_X11_GET_CLASS(obj)    (G_TYPE_INSTANCE_GET_CLASS ((obj), GDK_TYPE_GL_CONFIG_IMPL_X11, GdkGLConfigImplX11Class))
36 
37 struct _GdkGLConfigImplX11
38 {
39   GdkGLConfig parent_instance;
40 
41   Display *xdisplay;
42   int screen_num;
43   XVisualInfo *xvinfo;
44 
45   GdkScreen *screen;
46 
47   GdkColormap *colormap;
48 
49   guint is_mesa_glx : 1;
50 };
51 
52 struct _GdkGLConfigImplX11Class
53 {
54   GdkGLConfigClass parent_class;
55 };
56 
57 GType gdk_gl_config_impl_x11_get_type (void);
58 
59 G_END_DECLS
60 
61 #endif /* __GDK_GL_CONFIG_X11_H__ */
62