enable GL_ARB_shading_language_packing on GL 4.1

might fix #4515
This commit is contained in:
Mathias Agopian
2021-08-20 15:02:23 -07:00
committed by Mathias Agopian
parent 22afc3a93b
commit b30e4f9a4b
3 changed files with 7 additions and 1 deletions
+5
View File
@@ -344,6 +344,11 @@ void GLSLPostProcessor::fullOptimization(const TShader& tShader,
CompilerGLSL glslCompiler(move(spirv));
glslCompiler.set_common_options(glslOptions);
if (tShader.getStage() == EShLangFragment && !glslOptions.es) {
// enable GL_ARB_shading_language_packing if available
glslCompiler.add_header_line("#extension GL_ARB_shading_language_packing : enable");
}
if (tShader.getStage() == EShLangFragment && glslOptions.es) {
for (auto i : config.glsl.subpassInputToColorLocation) {
glslCompiler.remap_ext_framebuffer_fetch(i.first, i.second, true);