diff --git a/src/util/gl/context.cpp b/src/util/gl/context.cpp index 321455be0..45b2e5ba6 100644 --- a/src/util/gl/context.cpp +++ b/src/util/gl/context.cpp @@ -75,6 +75,22 @@ static void DisableBrokenExtensions(const char* gl_vendor, const char* gl_render GLAD_GL_EXT_disjoint_timer_query = 0; } } + else if (std::strstr(gl_vendor, "Qualcomm") && std::strstr(gl_renderer, "Adreno")) + { + // Framebuffer fetch appears to be broken in drivers ?? >= 464 < 502. + int gl_major_version = 0, gl_minor_version = 0, major_version = 0; + if ((std::sscanf(gl_version, "OpenGL ES %d.%d V@%d", &gl_major_version, &gl_minor_version, &major_version) == 3 && + gl_major_version >= 3 && gl_minor_version >= 2 && major_version < 502)) + { + Log_VerboseFmt("Disabling GL_EXT_shader_framebuffer_fetch on Adreno version {}", major_version); + GLAD_GL_EXT_shader_framebuffer_fetch = 0; + GLAD_GL_ARM_shader_framebuffer_fetch = 0; + } + else + { + Log_VerboseFmt("Keeping GL_EXT_shader_framebuffer_fetch on Adreno version {}", major_version); + } + } // If we're missing GLES 3.2, but have OES_draw_elements_base_vertex, redirect the function pointers. if (!glad_glDrawElementsBaseVertex && GLAD_GL_OES_draw_elements_base_vertex && !GLAD_GL_ES_VERSION_3_2)