summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon/RenderState.h
diff options
context:
space:
mode:
authorStenzek <stenzek@gmail.com>2019-08-02 19:20:36 +1000
committerStenzek <stenzek@gmail.com>2019-08-04 14:06:08 +1000
commitf6f9dc0cacb0dcbbd09d31acbb6e3a3ece764541 (patch)
tree049bab9cb6e1b2f22627c3820e44c5b6098e49b2 /Source/Core/VideoCommon/RenderState.h
parent4ccb4ef74fc8fd88b8fc62a2ec05ddb3fc84a94e (diff)
RenderState: Approximate logic op with blending if unsupported
This is a giant hack which was previously removed because it causes broken rendering. However, it seems that some devices still do not support logical operations (looking at you, Adreno/Mali). Therefore, for a handful of cases where the hack actually makes things slightly better, we can use it. ... but not without spamming the log with warnings. With my warning message PR, we can inform the users before emulation starts anyway.
Diffstat (limited to 'Source/Core/VideoCommon/RenderState.h')
-rw-r--r--Source/Core/VideoCommon/RenderState.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/Source/Core/VideoCommon/RenderState.h b/Source/Core/VideoCommon/RenderState.h
index dc0676ccc4..f5bf085d72 100644
--- a/Source/Core/VideoCommon/RenderState.h
+++ b/Source/Core/VideoCommon/RenderState.h
@@ -68,6 +68,10 @@ union BlendingState
{
void Generate(const BPMemory& bp);
+ // HACK: Replaces logical operations with blend operations.
+ // Will not be bit-correct, and in some cases not even remotely in the same ballpark.
+ void ApproximateLogicOpWithBlending();
+
BlendingState& operator=(const BlendingState& rhs);
bool operator==(const BlendingState& rhs) const { return hex == rhs.hex; }