New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
VideoCommon: Better logic op invert approximation #10864
VideoCommon: Better logic op invert approximation #10864
Conversation
4a96599
to
ce6a170
Compare
Is there anything else remaining on this? |
ps->emulate_logic_op_with_blend = true; | ||
ps->logic_op_mode = static_cast<u32>(blend.logicmode.Value()); | ||
} | ||
blend.ApproximateLogicOpWithBlending(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
They're different. The new boolean in approximations
is whether blending should be enabled. LogicOpApproximationIsExact
says whether an approximation gives identical results to the real thing. As an example of a logic op where the two aren't the same, Invert
has blending enabled but perfectly emulates the logic op, and therefore returns true from LogicOpApproximationIsExact
.
ce6a170
to
9661558
Compare
Been running this for months. Found no issues with it. |
Do we want to merge this? |
9661558
to
cd50167
Compare
Can you rebase this so fifoci runs on this again? |
cd50167
to
600ad5f
Compare
Done Just a heads up, fifoci won't test this because all its runners support logic ops. The main logic-op-free API is Metal/MVK, and it supports logic ops via framebuffer fetch on the CI (M1). |
Tested on my MacBook Pro 16" (which doesn't support fbfetch on its dGPU), and the linked FIFO log now renders correctly. Other logic ops games like Kirby's Air Ride and Star Fox Adventures continue to render properly as well. |
Uses a bit of cooperation from the shader to perfectly emulate the
Invert
andCopyInverted
logic ops with blendingMakes f-zero-missing-shadows.dff.zip (which uses
Invert
) work on logic-op-free systems.