Commit 68c5b1e4 authored by Tobias WEBER's avatar Tobias WEBER

defines

parent 87b20569
...@@ -39,15 +39,19 @@ ...@@ -39,15 +39,19 @@
#define _GL_MIN_VER 3 #define _GL_MIN_VER 3
#endif #endif
#if !defined(_GL_SUFFIX)
#define _GL_SUFFIX _Core
#endif
// GL functions include // GL functions include
#define _GL_INC_IMPL(MAJ, MIN) <QtGui/QOpenGLFunctions_ ## MAJ ## _ ## MIN ## _Core> #define _GL_INC_IMPL(MAJ, MIN, SUFF) <QtGui/QOpenGLFunctions_ ## MAJ ## _ ## MIN ## SUFF>
#define _GL_INC(MAJ, MIN) _GL_INC_IMPL(MAJ, MIN) #define _GL_INC(MAJ, MIN, SUFF) _GL_INC_IMPL(MAJ, MIN, SUFF)
#include _GL_INC(_GL_MAJ_VER, _GL_MIN_VER) #include _GL_INC(_GL_MAJ_VER, _GL_MIN_VER, _GL_SUFFIX)
// GL functions typedef // GL functions typedef
#define _GL_FUNC_IMPL(MAJ, MIN) QOpenGLFunctions_ ## MAJ ## _ ## MIN ## _Core #define _GL_FUNC_IMPL(MAJ, MIN, SUFF) QOpenGLFunctions_ ## MAJ ## _ ## MIN ## SUFF
#define _GL_FUNC(MAJ, MIN) _GL_FUNC_IMPL(MAJ, MIN) #define _GL_FUNC(MAJ, MIN, SUFF) _GL_FUNC_IMPL(MAJ, MIN, SUFF)
using qgl_funcs = _GL_FUNC(_GL_MAJ_VER, _GL_MIN_VER); using qgl_funcs = _GL_FUNC(_GL_MAJ_VER, _GL_MIN_VER, _GL_SUFFIX);
// GL surface format // GL surface format
extern void set_gl_format(bool bCore=true, int iMajorVer=3, int iMinorVer=3, int iSamples=8); extern void set_gl_format(bool bCore=true, int iMajorVer=3, int iMinorVer=3, int iSamples=8);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment