mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-05-31 14:29:14 +08:00
GPU: Fix segfault when copying to Vulkan swapchain (#15543)
This commit is contained in:
@@ -2500,6 +2500,11 @@ static void VULKAN_INTERNAL_TrackTextureTransfer(
|
|||||||
VulkanCommandBuffer *commandBuffer,
|
VulkanCommandBuffer *commandBuffer,
|
||||||
VulkanTexture *texture)
|
VulkanTexture *texture)
|
||||||
{
|
{
|
||||||
|
// Textures not managed by our allocator (i.e. the swapchain) don't need to be refcounted.
|
||||||
|
if (texture->usedRegion == NULL) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
TRACK_RESOURCE(
|
TRACK_RESOURCE(
|
||||||
texture,
|
texture,
|
||||||
VulkanTexture *,
|
VulkanTexture *,
|
||||||
|
|||||||
Reference in New Issue
Block a user