summaryrefslogtreecommitdiff
path: root/src/video_core/rasterizer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/video_core/rasterizer.cpp')
-rw-r--r--src/video_core/rasterizer.cpp13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/video_core/rasterizer.cpp b/src/video_core/rasterizer.cpp
index 226fad783..ecfdbc9e8 100644
--- a/src/video_core/rasterizer.cpp
+++ b/src/video_core/rasterizer.cpp
@@ -498,7 +498,8 @@ static void ProcessTriangleInternal(const Shader::OutputVertex& v0,
498 // with some basic arithmetic. Alpha combiners can be configured separately but work 498 // with some basic arithmetic. Alpha combiners can be configured separately but work
499 // analogously. 499 // analogously.
500 Math::Vec4<u8> combiner_output; 500 Math::Vec4<u8> combiner_output;
501 Math::Vec4<u8> combiner_buffer = { 501 Math::Vec4<u8> combiner_buffer = {0, 0, 0, 0};
502 Math::Vec4<u8> next_combiner_buffer = {
502 regs.tev_combiner_buffer_color.r, regs.tev_combiner_buffer_color.g, 503 regs.tev_combiner_buffer_color.r, regs.tev_combiner_buffer_color.g,
503 regs.tev_combiner_buffer_color.b, regs.tev_combiner_buffer_color.a 504 regs.tev_combiner_buffer_color.b, regs.tev_combiner_buffer_color.a
504 }; 505 };
@@ -747,14 +748,16 @@ static void ProcessTriangleInternal(const Shader::OutputVertex& v0,
747 combiner_output[2] = std::min((unsigned)255, color_output.b() * tev_stage.GetColorMultiplier()); 748 combiner_output[2] = std::min((unsigned)255, color_output.b() * tev_stage.GetColorMultiplier());
748 combiner_output[3] = std::min((unsigned)255, alpha_output * tev_stage.GetAlphaMultiplier()); 749 combiner_output[3] = std::min((unsigned)255, alpha_output * tev_stage.GetAlphaMultiplier());
749 750
751 combiner_buffer = next_combiner_buffer;
752
750 if (regs.tev_combiner_buffer_input.TevStageUpdatesCombinerBufferColor(tev_stage_index)) { 753 if (regs.tev_combiner_buffer_input.TevStageUpdatesCombinerBufferColor(tev_stage_index)) {
751 combiner_buffer.r() = combiner_output.r(); 754 next_combiner_buffer.r() = combiner_output.r();
752 combiner_buffer.g() = combiner_output.g(); 755 next_combiner_buffer.g() = combiner_output.g();
753 combiner_buffer.b() = combiner_output.b(); 756 next_combiner_buffer.b() = combiner_output.b();
754 } 757 }
755 758
756 if (regs.tev_combiner_buffer_input.TevStageUpdatesCombinerBufferAlpha(tev_stage_index)) { 759 if (regs.tev_combiner_buffer_input.TevStageUpdatesCombinerBufferAlpha(tev_stage_index)) {
757 combiner_buffer.a() = combiner_output.a(); 760 next_combiner_buffer.a() = combiner_output.a();
758 } 761 }
759 } 762 }
760 763