summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon/ShaderCache.cpp
diff options
context:
space:
mode:
authorConnor McLaughlin <stenzek@gmail.com>2019-08-04 14:39:38 +1000
committerGitHub <noreply@github.com>2019-08-04 14:39:38 +1000
commit7de6b57c13235a56ddda024ae46f76e88170522f (patch)
treeee2585bf7831b4b0cf6508760116979a4ad14a4f /Source/Core/VideoCommon/ShaderCache.cpp
parentc829351c90f8f9833a0a311c7982603c0c1339c9 (diff)
parentf6f9dc0cacb0dcbbd09d31acbb6e3a3ece764541 (diff)
Merge pull request #8284 from stenzek/logic-op-hack
RenderState: Approximate logic op with blending if unsupported
Diffstat (limited to 'Source/Core/VideoCommon/ShaderCache.cpp')
-rw-r--r--Source/Core/VideoCommon/ShaderCache.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/Source/Core/VideoCommon/ShaderCache.cpp b/Source/Core/VideoCommon/ShaderCache.cpp
index 3d4f286b68..e3066520fb 100644
--- a/Source/Core/VideoCommon/ShaderCache.cpp
+++ b/Source/Core/VideoCommon/ShaderCache.cpp
@@ -558,6 +558,13 @@ AbstractPipelineConfig ShaderCache::GetGXPipelineConfig(
config.depth_state = depth_state;
config.blending_state = blending_state;
config.framebuffer_state = g_framebuffer_manager->GetEFBFramebufferState();
+
+ if (config.blending_state.logicopenable && !g_ActiveConfig.backend_info.bSupportsLogicOp)
+ {
+ WARN_LOG(VIDEO, "Approximating logic op with blending, this will produce incorrect rendering.");
+ config.blending_state.ApproximateLogicOpWithBlending();
+ }
+
return config;
}