diff --git a/src/gpu/vulkan/SDL_gpu_vulkan.c b/src/gpu/vulkan/SDL_gpu_vulkan.c index a2e2f3443f..23877f183c 100644 --- a/src/gpu/vulkan/SDL_gpu_vulkan.c +++ b/src/gpu/vulkan/SDL_gpu_vulkan.c @@ -7169,6 +7169,8 @@ static VkRenderPass VULKAN_INTERNAL_FetchRenderPass( key.sampleCount = VK_SAMPLE_COUNT_1_BIT; if (numColorTargets > 0) { key.sampleCount = SDLToVK_SampleCount[((VulkanTextureContainer *)colorTargetInfos[0].texture)->header.info.sample_count]; + } else if (numColorTargets == 0 && depthStencilTargetInfo != NULL) { + key.sampleCount = SDLToVK_SampleCount[((VulkanTextureContainer *)depthStencilTargetInfo->texture)->header.info.sample_count]; } key.numColorTargets = numColorTargets;