Remove reference to WITH_LEGACY_OPENGL

We only keep this as a way to get GPU_stubs to run, in case we want to do a
throughout cleanup in the codebase and want code using legacy calls to
fail to build.
This commit is contained in:
Dalai Felinto
2017-05-19 14:15:49 +02:00
parent 3527739002
commit 2383667a2e
8 changed files with 3 additions and 329 deletions

View File

@@ -878,23 +878,6 @@ GHOST_TSuccess GHOST_ContextWGL::initializeDrawingContext()
else
m_hGLRC = s_sharedHGLRC;
}
#ifdef WITH_LEGACY_OPENGL
else {
if (m_contextProfileMask != 0)
fprintf(stderr, "Warning! Legacy WGL is unable to select between OpenGL profiles.");
if (m_contextMajorVersion != 0 || m_contextMinorVersion != 0)
fprintf(stderr, "Warning! Legacy WGL is unable to select between OpenGL versions.");
if (m_contextFlags != 0)
fprintf(stderr, "Warning! Legacy WGL is unable to set context flags.");
if (!s_singleContextMode || s_sharedHGLRC == NULL)
m_hGLRC = ::wglCreateContext(m_hDC);
else
m_hGLRC = s_sharedHGLRC;
}
#endif // WITH_LEGACY_OPENGL
if (!WIN32_CHK(m_hGLRC != NULL)) {
::wglMakeCurrent(prevHDC, prevHGLRC);
@@ -946,13 +929,7 @@ GHOST_TSuccess GHOST_ContextWGL::initializeDrawingContext()
MB_OK | MB_ICONERROR);
exit(0);
}
#if defined(WITH_LEGACY_OPENGL)
else if (version[0] < '3') {
// relax requirements for Mesa, which uses GL 3.0
// while other drivers use GL 3.3+ compatibility profile
#else
else if (version[0] < '3' || (version[0] == '3' && version[2] < '3')) {
#endif
MessageBox(m_hWnd, "Blender requires a graphics driver with OpenGL 3.3 support.\n\n"
"The program will now close.",
"Blender - Unsupported Graphics Driver!",