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.
This commit is contained in:
ReinUsesLisp 2020-03-12 04:28:50 -03:00
parent eb5861e0a2
commit 825d629565

View File

@ -543,18 +543,8 @@ private:
if (stage != ShaderType::Fragment) {
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);
}
}