From 51278bab5ded412fa1a38c2564cc3fda71e3129b Mon Sep 17 00:00:00 2001 From: Mike Erwin Date: Thu, 18 May 2017 16:58:33 -0400 Subject: remove GPU_legacy_support query In the move to OpenGL 3.3 core profile, we drop support for compatibility profile and older versions. OpenSubdiv was the only user; I'll update OSD next. --- source/blender/gpu/intern/gpu_extensions.c | 43 ------------------------------ 1 file changed, 43 deletions(-) (limited to 'source/blender/gpu/intern/gpu_extensions.c') diff --git a/source/blender/gpu/intern/gpu_extensions.c b/source/blender/gpu/intern/gpu_extensions.c index 2a2e73c6ba8..fb6c2ef9b6e 100644 --- a/source/blender/gpu/intern/gpu_extensions.c +++ b/source/blender/gpu/intern/gpu_extensions.c @@ -266,49 +266,6 @@ void gpu_extensions_exit(void) GPU_invalid_tex_free(); } -bool GPU_legacy_support(void) -{ -#ifdef WITH_LEGACY_OPENGL - /* return whether or not current GL context is compatible with legacy OpenGL */ - /* (will be removed after switching to core profile) */ - - static bool checked = false; - static bool support = true; - - if (!checked) { - if (GLEW_VERSION_3_2) { - GLint profile; - glGetIntegerv(GL_CONTEXT_PROFILE_MASK, &profile); - - if (G.debug & G_DEBUG_GPU) { - printf("GL_CONTEXT_PROFILE_MASK = %#x (%s profile)\n", (unsigned int)profile, - (profile & GL_CONTEXT_COMPATIBILITY_PROFILE_BIT) ? "compatibility" : - (profile & GL_CONTEXT_CORE_PROFILE_BIT) ? "core" : "unknown"); - } - - if (profile == 0) { - /* workaround for nVidia's Linux driver */ - support = GLEW_ARB_compatibility; - } - else { - support = profile & GL_CONTEXT_COMPATIBILITY_PROFILE_BIT; - } - } - else if (GLEW_VERSION_3_1) { - support = GLEW_ARB_compatibility; - } - - /* any OpenGL version <= 3.0 is legacy, so support remains true */ - - checked = true; - } - - return support; -#else - return false; -#endif -} - bool GPU_full_non_power_of_two_support(void) { /* always supported on full GL but still relevant for OpenGL ES 2.0 where -- cgit v1.2.3