Explorar o código

gl_shader_decompiler: Fix regression in render target declarations

A previous commit introduced a way to declare as few render targets as
possible. Turns out this introduced a regression in some games.
ReinUsesLisp %!s(int64=6) %!d(string=hai) anos
pai
achega
825d629565
Modificáronse 1 ficheiros con 2 adicións e 12 borrados
  1. 2 12
      src/video_core/renderer_opengl/gl_shader_decompiler.cpp

+ 2 - 12
src/video_core/renderer_opengl/gl_shader_decompiler.cpp

@@ -543,18 +543,8 @@ private:
         if (stage != ShaderType::Fragment) {
         if (stage != ShaderType::Fragment) {
             return;
             return;
         }
         }
-
-        bool any = false;
-        for (u32 render_target = 0; render_target < Maxwell::NumRenderTargets; ++render_target) {
-            if (!IsRenderTargetEnabled(render_target)) {
-                continue;
-            }
-            code.AddLine("layout (location = {}) out vec4 frag_color{};", render_target,
-                         render_target);
-            any = true;
-        }
-        if (any) {
-            code.AddNewLine();
+        for (u32 rt = 0; rt < Maxwell::NumRenderTargets; ++rt) {
+            code.AddLine("layout (location = {}) out vec4 frag_color{};", rt, rt);
         }
         }
     }
     }