Skip to content
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

D3D: Implement logic op support #6013

Merged
merged 7 commits into from Sep 4, 2017
Merged

D3D: Implement logic op support #6013

merged 7 commits into from Sep 4, 2017

Conversation

stenzek
Copy link
Contributor

@stenzek stenzek commented Sep 3, 2017

Requires #5337.

This brings D3D to parity with OpenGL and Vulkan, however at the cost of additional shader variants, since D3D doesn't implicitly convert the floating point color to integer first (just reinterprets the bits).

It also requires Direct3D 11.1, and a WDDM 1.2 driver. So, this will only work on Windows 8 and above. Windows 7 will result in visual breakage in games which uses logic ops, but the approximation method used before was significantly incorrect anyway.

Fixes https://bugs.dolphin-emu.org/issues/10513 and probably others.

@@ -43,7 +43,8 @@ struct pixel_shader_uid_data
u32 numColorChans : 2;
u32 rgba6_format : 1;
u32 dither : 1;
u32 pad : 16;
u32 uint_output : 1;

This comment was marked as off-topic.

@iwubcode
Copy link
Contributor

iwubcode commented Sep 3, 2017

I get the following Warning when trying to boot any game:

DX11::FramebufferManager::FramebufferManager failed in FramebufferManager.cpp at line 192: create EFB RTV.

(occurs twice but then after clicking ok, everything seems to look fine).

Regardless, Okami and Opoona seem to be fixed in this PR.

This brings D3D to parity with OpenGL and Vulkan.
@stenzek
Copy link
Contributor Author

stenzek commented Sep 4, 2017

@iwubcode Should be fixed now. Interesting that the NV driver doesn't complain about this (uint view on a unorm texture instead of typeless). The validation layer would have caught it if I had left it enabled when testing though..

Copy link
Contributor

@iwubcode iwubcode left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Haven't ran a fifo compare yet but the code looks good and it fixes Opoona/Okami.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants