From f51dda3e665058cea271f91f3c113451fbd8f7a3 Mon Sep 17 00:00:00 2001 From: Stenzek Date: Wed, 1 Jan 2025 19:38:46 +1000 Subject: [PATCH] GPUDevice: Allow this-frame pooled textures when not uploading data It won't break the render pass. --- src/util/gpu_device.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util/gpu_device.cpp b/src/util/gpu_device.cpp index 658b0396b..a18fe0571 100644 --- a/src/util/gpu_device.cpp +++ b/src/util/gpu_device.cpp @@ -1028,7 +1028,7 @@ std::unique_ptr GPUDevice::FetchTexture(u32 width, u32 height, u32 l TexturePool::iterator it; - if (is_texture && m_features.prefer_unused_textures) + if (is_texture && data && m_features.prefer_unused_textures) { // Try to find a texture that wasn't used this frame first. for (it = m_texture_pool.begin(); it != m_texture_pool.end(); ++it)