1 // Created on: 2012-03-06
2 // Created by: Kirill GAVRILOV
3 // Copyright (c) 2012-2014 OPEN CASCADE SAS
5 // This file is part of Open CASCADE Technology software library.
7 // This library is free software; you can redistribute it and/or modify it under
8 // the terms of the GNU Lesser General Public License version 2.1 as published
9 // by the Free Software Foundation, with special exception defined in the file
10 // OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
11 // distribution for complete text of the license and disclaimer of any warranty.
13 // Alternatively, this file may be used under the terms of Open CASCADE
14 // commercial license or contractual agreement.
16 #ifndef OpenGl_GlCore11_HeaderFile
17 #define OpenGl_GlCore11_HeaderFile
19 #include <OpenGl_GlCore11Fwd.hxx>
22 //! Notice that all functions within this structure are actually exported by system GL library.
23 //! The main purpose for these hint - to control visibility of functions per GL version
24 //! (global functions should not be used directly to achieve this effect!).
25 struct OpenGl_GlCore11 : protected OpenGl_GlFunctions
28 #if !defined(GL_ES_VERSION_2_0)
31 inline void glTexEnvi (GLenum target, GLenum pname, GLint param)
33 ::glTexEnvi (target, pname, param);
34 OpenGl_TRACE(glTexEnvi)
37 inline void glGetTexEnviv (GLenum target, GLenum pname, GLint *params)
39 ::glGetTexEnviv (target, pname, params);
40 OpenGl_TRACE(glGetTexEnviv)
43 inline void glLogicOp (GLenum opcode)
46 OpenGl_TRACE(glLogicOp)
49 public: //! @name Begin/End primitive specification (removed since 3.1)
51 inline void glColor4fv (const GLfloat* theVec)
53 ::glColor4fv (theVec);
54 OpenGl_TRACE(glColor4fv)
57 public: //! @name Matrix operations (removed since 3.1)
59 inline void glMatrixMode (GLenum theMode)
61 ::glMatrixMode (theMode);
62 OpenGl_TRACE(glMatrixMode)
65 inline void glLoadIdentity()
68 OpenGl_TRACE(glLoadIdentity)
71 inline void glLoadMatrixf (const GLfloat* theMatrix)
73 ::glLoadMatrixf (theMatrix);
74 OpenGl_TRACE(glLoadMatrixf)
77 public: //! @name Line and Polygon stipple (removed since 3.1)
79 inline void glLineStipple (GLint theFactor, GLushort thePattern)
81 ::glLineStipple (theFactor, thePattern);
82 OpenGl_TRACE(glLineStipple)
85 inline void glPolygonStipple (const GLubyte* theMask)
87 ::glPolygonStipple (theMask);
88 OpenGl_TRACE(glPolygonStipple)
91 public: //! @name Fixed pipeline lighting (removed since 3.1)
93 inline void glShadeModel (GLenum theMode)
95 ::glShadeModel (theMode);
96 OpenGl_TRACE(glShadeModel)
99 inline void glLightf (GLenum theLight, GLenum pname, GLfloat param)
101 ::glLightf (theLight, pname, param);
102 OpenGl_TRACE(glLightf)
105 inline void glLightfv (GLenum theLight, GLenum pname, const GLfloat* params)
107 ::glLightfv (theLight, pname, params);
108 OpenGl_TRACE(glLightfv)
111 inline void glLightModeli (GLenum pname, GLint param)
113 ::glLightModeli(pname, param);
114 OpenGl_TRACE(glLightModeli)
117 inline void glLightModelfv (GLenum pname, const GLfloat* params)
119 ::glLightModelfv(pname, params);
120 OpenGl_TRACE(glLightModelfv)
123 inline void glMaterialf (GLenum face, GLenum pname, GLfloat param)
125 ::glMaterialf(face, pname, param);
126 OpenGl_TRACE(glMaterialf)
129 inline void glMaterialfv (GLenum face, GLenum pname, const GLfloat* params)
131 ::glMaterialfv(face, pname, params);
132 OpenGl_TRACE(glMaterialfv)
135 inline void glColorMaterial (GLenum face, GLenum mode)
137 ::glColorMaterial(face, mode);
138 OpenGl_TRACE(glColorMaterial)
141 public: //! @name clipping plane (removed since 3.1)
143 inline void glClipPlane (GLenum thePlane, const GLdouble* theEquation)
145 ::glClipPlane (thePlane, theEquation);
146 OpenGl_TRACE(glClipPlane)
149 public: //! @name Display lists (removed since 3.1)
151 inline void glDeleteLists (GLuint theList, GLsizei theRange)
153 ::glDeleteLists (theList, theRange);
154 OpenGl_TRACE(glDeleteLists)
157 inline GLuint glGenLists (GLsizei theRange)
159 const GLuint aRes = ::glGenLists (theRange);
160 OpenGl_TRACE(glGenLists)
164 inline void glNewList (GLuint theList, GLenum theMode)
166 ::glNewList (theList, theMode);
167 OpenGl_TRACE(glNewList)
170 inline void glEndList()
173 OpenGl_TRACE(glEndList)
176 inline void glCallList (GLuint theList)
178 ::glCallList (theList);
179 OpenGl_TRACE(glCallList)
182 inline void glCallLists (GLsizei theNb, GLenum theType, const GLvoid* theLists)
184 ::glCallLists (theNb, theType, theLists);
185 OpenGl_TRACE(glCallLists)
188 inline void glListBase (GLuint theBase)
190 ::glListBase (theBase);
191 OpenGl_TRACE(glListBase)
194 public: //! @name Current raster position and Rectangles (removed since 3.1)
196 inline void glRasterPos2i (GLint x, GLint y)
198 ::glRasterPos2i (x, y);
199 OpenGl_TRACE(glRasterPos2i)
202 inline void glRasterPos3fv (const GLfloat* theVec)
204 ::glRasterPos3fv (theVec);
205 OpenGl_TRACE(glRasterPos3fv)
208 public: //! @name Texture mapping (removed since 3.1)
210 inline void glTexGeni (GLenum coord, GLenum pname, GLint param)
212 ::glTexGeni (coord, pname, param);
213 OpenGl_TRACE(glTexGeni)
216 inline void glTexGenfv (GLenum coord, GLenum pname, const GLfloat* params)
218 ::glTexGenfv (coord, pname, params);
219 OpenGl_TRACE(glTexGenfv)
222 public: //! @name Pixel copying (removed since 3.1)
224 inline void glDrawPixels (GLsizei width, GLsizei height,
225 GLenum format, GLenum type,
226 const GLvoid* pixels)
228 ::glDrawPixels (width, height, format, type, pixels);
229 OpenGl_TRACE(glDrawPixels)
232 inline void glCopyPixels (GLint x, GLint y,
233 GLsizei width, GLsizei height,
236 ::glCopyPixels (x, y, width, height, type);
237 OpenGl_TRACE(glCopyPixels)
240 inline void glBitmap (GLsizei width, GLsizei height,
241 GLfloat xorig, GLfloat yorig,
242 GLfloat xmove, GLfloat ymove,
243 const GLubyte* bitmap)
245 ::glBitmap (width, height, xorig, yorig, xmove, ymove, bitmap);
246 OpenGl_TRACE(glBitmap)
249 public: //! @name Edge flags and fixed-function vertex processing (removed since 3.1)
251 inline void glIndexPointer (GLenum theType, GLsizei theStride, const GLvoid* thePtr)
253 ::glIndexPointer (theType, theStride, thePtr);
254 OpenGl_TRACE(glIndexPointer)
257 inline void glVertexPointer (GLint theSize, GLenum theType, GLsizei theStride, const GLvoid* thePtr)
259 ::glVertexPointer (theSize, theType, theStride, thePtr);
260 OpenGl_TRACE(glVertexPointer)
263 inline void glNormalPointer (GLenum theType, GLsizei theStride, const GLvoid* thePtr)
265 ::glNormalPointer (theType, theStride, thePtr);
266 OpenGl_TRACE(glNormalPointer)
269 inline void glColorPointer (GLint theSize, GLenum theType, GLsizei theStride, const GLvoid* thePtr)
271 ::glColorPointer (theSize, theType, theStride, thePtr);
272 OpenGl_TRACE(glColorPointer)
275 inline void glTexCoordPointer (GLint theSize, GLenum theType, GLsizei theStride, const GLvoid* thePtr)
277 ::glTexCoordPointer (theSize, theType, theStride, thePtr);
278 OpenGl_TRACE(glTexCoordPointer)
281 inline void glEnableClientState (GLenum theCap)
283 ::glEnableClientState (theCap);
284 OpenGl_TRACE(glEnableClientState)
287 inline void glDisableClientState (GLenum theCap)
289 ::glDisableClientState (theCap);
290 OpenGl_TRACE(glDisableClientState)
297 #endif // _OpenGl_GlCore11_Header