From 2da1d4f30e321d8fe6d741c7fa1bb969430fdc03 Mon Sep 17 00:00:00 2001 From: assiduous Date: Sat, 8 Aug 2020 21:59:47 -0700 Subject: Added comment --- Graphics/GraphicsEngineD3D12/src/DeviceContextD3D12Impl.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'Graphics/GraphicsEngineD3D12') diff --git a/Graphics/GraphicsEngineD3D12/src/DeviceContextD3D12Impl.cpp b/Graphics/GraphicsEngineD3D12/src/DeviceContextD3D12Impl.cpp index abc1d0dc..08b64857 100644 --- a/Graphics/GraphicsEngineD3D12/src/DeviceContextD3D12Impl.cpp +++ b/Graphics/GraphicsEngineD3D12/src/DeviceContextD3D12Impl.cpp @@ -1134,7 +1134,11 @@ void DeviceContextD3D12Impl::CommitSubpassRenderTargets() ARI.SrcRect.bottom = MipProps.LogicalHeight; } - RPRT.EndingAccess.Type = D3D12_RENDER_PASS_ENDING_ACCESS_TYPE_RESOLVE; + // The resolve source is left in its initial resource state at the time the render pass ends. + // A resolve operation submitted by a render pass doesn't implicitly change the state of any resource. + // https://docs.microsoft.com/en-us/windows/win32/api/d3d12/ne-d3d12-d3d12_render_pass_ending_access_type + RPRT.EndingAccess.Type = D3D12_RENDER_PASS_ENDING_ACCESS_TYPE_RESOLVE; + auto& ResolveParams = RPRT.EndingAccess.Resolve; ResolveParams.pSrcResource = pSrcTexD3D12->GetD3D12Resource(); ResolveParams.pDstResource = pDstTexD3D12->GetD3D12Resource(); -- cgit v1.2.3