mirror of
https://github.com/overte-org/overte.git
synced 2025-08-08 13:58:51 +02:00
fixing missing glew init
This commit is contained in:
parent
c0859ffd4c
commit
94d57a2e43
1 changed files with 14 additions and 0 deletions
|
@ -763,6 +763,20 @@ void Application::initializeGL() {
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef WIN32
|
||||||
|
GLenum err = glewInit();
|
||||||
|
if (GLEW_OK != err) {
|
||||||
|
/* Problem: glewInit failed, something is seriously wrong. */
|
||||||
|
qCDebug(interfaceapp, "Error: %s\n", glewGetErrorString(err));
|
||||||
|
}
|
||||||
|
qCDebug(interfaceapp, "Status: Using GLEW %s\n", glewGetString(GLEW_VERSION));
|
||||||
|
|
||||||
|
if (wglewGetExtension("WGL_EXT_swap_control")) {
|
||||||
|
int swapInterval = wglGetSwapIntervalEXT();
|
||||||
|
qCDebug(interfaceapp, "V-Sync is %s\n", (swapInterval > 0 ? "ON" : "OFF"));
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(Q_OS_LINUX)
|
#if defined(Q_OS_LINUX)
|
||||||
// TODO: Write the correct code for Linux...
|
// TODO: Write the correct code for Linux...
|
||||||
/* if (wglewGetExtension("WGL_EXT_swap_control")) {
|
/* if (wglewGetExtension("WGL_EXT_swap_control")) {
|
||||||
|
|
Loading…
Reference in a new issue