Panda3D
glgsg.h
Go to the documentation of this file.
1 /**
2  * PANDA 3D SOFTWARE
3  * Copyright (c) Carnegie Mellon University. All rights reserved.
4  *
5  * All use of this software is subject to the terms of the revised BSD
6  * license. You should have received a copy of this license along
7  * with this source code in a file named "LICENSE."
8  *
9  * @file glgsg.h
10  * @author drose
11  * @date 2004-02-09
12  */
13 
14 #ifndef GLGSG_H
15 #define GLGSG_H
16 
17 // This is the actual header file to include if you want to pick up any or all
18 // of the header files in this directory as compiled to use the "true" GL
19 // library.
20 
21 #include "pandabase.h"
22 #include "config_glgsg.h"
23 
24 #define GLP(name) gl ## name
25 
26 #ifndef STDFLOAT_DOUBLE
27 #define GLPf(name) gl ## name ## f
28 #define GLPfv(name) gl ## name ## fv
29 #else // STDFLOAT_DOUBLE
30 #define GLPf(name) gl ## name ## d
31 #define GLPfv(name) gl ## name ## dv
32 #endif // STDFLOAT_DOUBLE
33 
34 #define CLP(name) GL ## name
35 #define GLPREFIX_QUOTED "gl"
36 #define CLASSPREFIX_QUOTED "GL"
37 #define GLSYSTEM_NAME "OpenGL"
38 #define CONFIGOBJ config_glgsg
39 #define GLCAT glgsg_cat
40 #define EXPCL_GL EXPCL_PANDA_GLGSG
41 #define EXPTP_GL EXPTP_PANDA_GLGSG
42 
43 #if MIN_GL_VERSION_MAJOR > 1 || (MIN_GL_VERSION_MAJOR == 1 && MIN_GL_VERSION_MINOR >= 2)
44 #define EXPECT_GL_VERSION_1_2
45 #endif
46 
47 #if MIN_GL_VERSION_MAJOR > 1 || (MIN_GL_VERSION_MAJOR == 1 && MIN_GL_VERSION_MINOR >= 3)
48 #define EXPECT_GL_VERSION_1_3
49 #endif
50 
51 #if MIN_GL_VERSION_MAJOR > 1 || (MIN_GL_VERSION_MAJOR == 1 && MIN_GL_VERSION_MINOR >= 4)
52 #define EXPECT_GL_VERSION_1_4
53 #endif
54 
55 #if MIN_GL_VERSION_MAJOR > 1 || (MIN_GL_VERSION_MAJOR == 1 && MIN_GL_VERSION_MINOR >= 5)
56 #define EXPECT_GL_VERSION_1_5
57 #endif
58 
59 #if MIN_GL_VERSION_MAJOR > 2 || (MIN_GL_VERSION_MAJOR == 2 && MIN_GL_VERSION_MINOR >= 0)
60 #define EXPECT_GL_VERSION_2_0
61 #endif
62 
63 #if MIN_GL_VERSION_MAJOR > 2 || (MIN_GL_VERSION_MAJOR == 2 && MIN_GL_VERSION_MINOR >= 1)
64 #define EXPECT_GL_VERSION_2_1
65 #endif
66 
67 // Before including gl.h, need to include windows.h
68 #if defined(_WIN32)
69 #ifndef WIN32_LEAN_AND_MEAN
70 #define WIN32_LEAN_AND_MEAN 1
71 #endif
72 #include <windows.h>
73 #endif
74 
75 // This prevents glext.h from getting included by gl.h That way, we can
76 // provide our own, better version.
77 #define __glext_h_
78 #define GL_GLEXT_VERSION 0
79 
80 #ifdef IS_OSX
81  #include <OpenGL/gl.h>
82 #else
83  #include <GL/gl.h>
84 #endif
85 
86 #undef __glext_h_
87 #undef GL_GLEXT_VERSION
88 #include "panda_glext.h"
89 
90 #include "glstuff_src.h"
91 
92 #endif // GLGSG_H
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.