mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-29 12:19:12 +00:00
D3D11: Query for output merger logic op support and use logic op code only if supported
Previously code assumed that if DX11.1 runtime is supported, logic ops will, but Windows 7 SP1 with a Platform Update supports DX11.1 runtime without logic ops. This created pretty jarring visual artifacts, which now should be gone OR replaced with much less jarring errors.
This commit is contained in:
parent
a6b8e8b9c3
commit
ff00873610
5 changed files with 64 additions and 16 deletions
|
@ -12,6 +12,7 @@
|
|||
#include "VideoBackends/D3D/D3DState.h"
|
||||
#include "VideoBackends/D3D/DXTexture.h"
|
||||
#include "VideoBackends/D3DCommon/Common.h"
|
||||
#include "VideoCommon/VideoConfig.h"
|
||||
|
||||
namespace DX11
|
||||
{
|
||||
|
@ -360,10 +361,10 @@ std::unique_ptr<DXFramebuffer> DXFramebuffer::Create(DXTexture* color_attachment
|
|||
if (FAILED(hr))
|
||||
return nullptr;
|
||||
|
||||
// Only create the integer RTV on Win8+.
|
||||
// Only create the integer RTV when logic ops are supported (Win8+).
|
||||
DXGI_FORMAT integer_format =
|
||||
D3DCommon::GetRTVFormatForAbstractFormat(color_attachment->GetFormat(), true);
|
||||
if (D3D::device1 && integer_format != desc.Format)
|
||||
if (g_ActiveConfig.backend_info.bSupportsLogicOp && integer_format != desc.Format)
|
||||
{
|
||||
desc.Format = integer_format;
|
||||
hr = D3D::device->CreateRenderTargetView(color_attachment->GetD3DTexture(), &desc,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue