summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/video_core/renderer_opengl/gl_shader_decompiler.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp
index 8d68156bf..d3a5d2f12 100644
--- a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp
+++ b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp
@@ -2766,22 +2766,21 @@ private:
2766 const bool depth_compare = 2766 const bool depth_compare =
2767 instr.texs.UsesMiscMode(Tegra::Shader::TextureMiscMode::DC); 2767 instr.texs.UsesMiscMode(Tegra::Shader::TextureMiscMode::DC);
2768 const auto process_mode = instr.texs.GetTextureProcessMode(); 2768 const auto process_mode = instr.texs.GetTextureProcessMode();
2769
2769 UNIMPLEMENTED_IF_MSG(instr.texs.UsesMiscMode(Tegra::Shader::TextureMiscMode::NODEP), 2770 UNIMPLEMENTED_IF_MSG(instr.texs.UsesMiscMode(Tegra::Shader::TextureMiscMode::NODEP),
2770 "NODEP is not implemented"); 2771 "NODEP is not implemented");
2771 2772
2772 const auto scope = shader.Scope(); 2773 const auto scope = shader.Scope();
2773 2774
2774 const auto [coord, texture] = 2775 auto [coord, texture] =
2775 GetTEXSCode(instr, texture_type, process_mode, depth_compare, is_array); 2776 GetTEXSCode(instr, texture_type, process_mode, depth_compare, is_array);
2776 2777
2777 shader.AddLine(coord); 2778 shader.AddLine(coord);
2778 2779
2779 if (!depth_compare) { 2780 if (depth_compare) {
2780 shader.AddLine("vec4 texture_tmp = " + texture + ';'); 2781 texture = "vec4(" + texture + ')';
2781
2782 } else {
2783 shader.AddLine("vec4 texture_tmp = vec4(" + texture + ");");
2784 } 2782 }
2783 shader.AddLine("vec4 texture_tmp = " + texture + ';');
2785 2784
2786 WriteTexsInstruction(instr, "texture_tmp"); 2785 WriteTexsInstruction(instr, "texture_tmp");
2787 break; 2786 break;