Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorJeroen Bakker <jeroen@blender.org>2022-06-15 10:09:43 +0300
committerPhilipp Oeser <info@graphics-engineer.com>2022-06-22 13:20:44 +0300
commit92fee7077ab8b38918622ac530e53205d053cb9c (patch)
tree060b7107613372796b40ac724271578ff0a3a427 /source
parentde267abe4eb8d761e56f62c97ee588a1d6fdbd3f (diff)
Fix T98708: Crash on startup - OpenGL4.2 without conservative depth.
Intel iGPU (HD4000) supports OpenGL 4.4 but doesn't support conservative depth. (GL_ARB_conservative_depth). This change will only check for the availability of the extension.
Diffstat (limited to 'source')
-rw-r--r--source/blender/gpu/opengl/gl_shader.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/gpu/opengl/gl_shader.cc b/source/blender/gpu/opengl/gl_shader.cc
index 957bc8b24be..4595beab66b 100644
--- a/source/blender/gpu/opengl/gl_shader.cc
+++ b/source/blender/gpu/opengl/gl_shader.cc
@@ -613,7 +613,7 @@ std::string GLShader::fragment_interface_declare(const ShaderCreateInfo &info) c
if (info.early_fragment_test_) {
ss << "layout(early_fragment_tests) in;\n";
}
- if (GLEW_VERSION_4_2 || GLEW_ARB_conservative_depth) {
+ if (GLEW_ARB_conservative_depth) {
ss << "layout(" << to_string(info.depth_write_) << ") out float gl_FragDepth;\n";
}
ss << "\n/* Outputs. */\n";
@@ -836,7 +836,7 @@ static char *glsl_patch_default_get()
STR_CONCAT(patch, slen, "#extension GL_ARB_texture_cube_map_array : enable\n");
STR_CONCAT(patch, slen, "#define GPU_ARB_texture_cube_map_array\n");
}
- if (!GLEW_VERSION_4_2 && GLEW_ARB_conservative_depth) {
+ if (GLEW_ARB_conservative_depth) {
STR_CONCAT(patch, slen, "#extension GL_ARB_conservative_depth : enable\n");
}
if (GPU_shader_image_load_store_support()) {