summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar ReinUsesLisp2019-12-25 20:13:43 -0300
committerGravatar ReinUsesLisp2020-02-28 16:50:58 -0300
commit915d73f3b8871fc31b9b6571d645ced6f766bc43 (patch)
treec6cbed195070e4345954b47a38c3ca87fd4d9c6e /src
parentgl_state: Remove polygon offset tracking (diff)
downloadyuzu-915d73f3b8871fc31b9b6571d645ced6f766bc43.tar.gz
yuzu-915d73f3b8871fc31b9b6571d645ced6f766bc43.tar.xz
yuzu-915d73f3b8871fc31b9b6571d645ced6f766bc43.zip
gl_state: Remove blend color tracking
Diffstat (limited to 'src')
-rw-r--r--src/video_core/renderer_opengl/gl_rasterizer.cpp5
-rw-r--r--src/video_core/renderer_opengl/gl_state.cpp7
-rw-r--r--src/video_core/renderer_opengl/gl_state.h7
3 files changed, 1 insertions, 18 deletions
diff --git a/src/video_core/renderer_opengl/gl_rasterizer.cpp b/src/video_core/renderer_opengl/gl_rasterizer.cpp
index 744892618..5c5273b5d 100644
--- a/src/video_core/renderer_opengl/gl_rasterizer.cpp
+++ b/src/video_core/renderer_opengl/gl_rasterizer.cpp
@@ -1117,10 +1117,7 @@ void RasterizerOpenGL::SyncBlendState() {
1117 auto& maxwell3d = system.GPU().Maxwell3D(); 1117 auto& maxwell3d = system.GPU().Maxwell3D();
1118 const auto& regs = maxwell3d.regs; 1118 const auto& regs = maxwell3d.regs;
1119 1119
1120 state.blend_color.red = regs.blend_color.r; 1120 glBlendColor(regs.blend_color.r, regs.blend_color.g, regs.blend_color.b, regs.blend_color.a);
1121 state.blend_color.green = regs.blend_color.g;
1122 state.blend_color.blue = regs.blend_color.b;
1123 state.blend_color.alpha = regs.blend_color.a;
1124 1121
1125 state.independant_blend.enabled = regs.independent_blend_enable; 1122 state.independant_blend.enabled = regs.independent_blend_enable;
1126 if (!state.independant_blend.enabled) { 1123 if (!state.independant_blend.enabled) {
diff --git a/src/video_core/renderer_opengl/gl_state.cpp b/src/video_core/renderer_opengl/gl_state.cpp
index 05c271ad2..e8463da7e 100644
--- a/src/video_core/renderer_opengl/gl_state.cpp
+++ b/src/video_core/renderer_opengl/gl_state.cpp
@@ -330,13 +330,6 @@ void OpenGLState::ApplyBlending() {
330 ApplyGlobalBlending(); 330 ApplyGlobalBlending();
331 } 331 }
332 cur_state.independant_blend.enabled = independant_blend.enabled; 332 cur_state.independant_blend.enabled = independant_blend.enabled;
333
334 if (UpdateTie(
335 std::tie(cur_state.blend_color.red, cur_state.blend_color.green,
336 cur_state.blend_color.blue, cur_state.blend_color.alpha),
337 std::tie(blend_color.red, blend_color.green, blend_color.blue, blend_color.alpha))) {
338 glBlendColor(blend_color.red, blend_color.green, blend_color.blue, blend_color.alpha);
339 }
340} 333}
341 334
342void OpenGLState::ApplyLogicOp() { 335void OpenGLState::ApplyLogicOp() {
diff --git a/src/video_core/renderer_opengl/gl_state.h b/src/video_core/renderer_opengl/gl_state.h
index 71a2cad2e..b06a88f01 100644
--- a/src/video_core/renderer_opengl/gl_state.h
+++ b/src/video_core/renderer_opengl/gl_state.h
@@ -82,13 +82,6 @@ public:
82 } independant_blend; 82 } independant_blend;
83 83
84 struct { 84 struct {
85 GLclampf red = 0.0f;
86 GLclampf green = 0.0f;
87 GLclampf blue = 0.0f;
88 GLclampf alpha = 0.0f;
89 } blend_color; // GL_BLEND_COLOR
90
91 struct {
92 bool enabled = false; // GL_LOGIC_OP_MODE 85 bool enabled = false; // GL_LOGIC_OP_MODE
93 GLenum operation = GL_COPY; 86 GLenum operation = GL_COPY;
94 } logic_op; 87 } logic_op;