From 51c2c9e5f247c7711f2cca6a9f14f81397fe61f7 Mon Sep 17 00:00:00 2001 From: Triang3l Date: Tue, 27 Apr 2021 19:55:29 +0300 Subject: [PATCH] [D3D12] Fix render target reference leak --- src/xenia/gpu/d3d12/d3d12_render_target_cache.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/xenia/gpu/d3d12/d3d12_render_target_cache.h b/src/xenia/gpu/d3d12/d3d12_render_target_cache.h index efc86db64..1f552e8fe 100644 --- a/src/xenia/gpu/d3d12/d3d12_render_target_cache.h +++ b/src/xenia/gpu/d3d12/d3d12_render_target_cache.h @@ -149,9 +149,7 @@ class D3D12RenderTargetCache final : public RenderTargetCache { descriptor_load_separate_(std::move(descriptor_load_separate)), descriptor_srv_(std::move(descriptor_srv)), descriptor_srv_stencil_(std::move(descriptor_srv_stencil)), - resource_state_(resource_state) { - resource_->AddRef(); - } + resource_state_(resource_state) {} ID3D12Resource* resource() const { return resource_.Get(); } const ui::d3d12::D3D12CpuDescriptorPool::Descriptor& descriptor_draw()