From 5999a1a62edc069092bc171acf08827673eb5419 Mon Sep 17 00:00:00 2001 From: Stenzek Date: Wed, 28 Dec 2022 13:58:38 +1000 Subject: [PATCH] D3D12/Texture: Fix crash when upload buffer exhausts --- common/D3D12/Texture.cpp | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/common/D3D12/Texture.cpp b/common/D3D12/Texture.cpp index 62b5da9b15..35b080f47d 100644 --- a/common/D3D12/Texture.cpp +++ b/common/D3D12/Texture.cpp @@ -26,11 +26,6 @@ using namespace D3D12; -// Somehow NOMINMAX isn't getting set for CMake builds... -#ifdef min -#undef min -#endif - Texture::Texture() = default; Texture::Texture(ID3D12Resource* resource, D3D12_RESOURCE_STATES state) @@ -349,7 +344,7 @@ ID3D12GraphicsCommandList* Texture::BeginStreamUpdate(ID3D12GraphicsCommandList* } // cmdlist change - return g_d3d12_context->GetInitCommandList(); + cmdlist = g_d3d12_context->GetInitCommandList(); } *out_data = g_d3d12_context->GetTextureStreamBuffer().GetCurrentHostPointer();