Fix vulkan backend clearing the canvas textures to undefined contents

This commit is contained in:
Magnus Norddahl 2022-10-28 20:41:34 +02:00 committed by Rachael Alexanderson
parent 7f99c61f24
commit 1a1adc5c29

View file

@ -206,7 +206,7 @@ void VulkanFrameBuffer::RenderTextureView(FCanvasTexture* tex, std::function<voi
mRenderState->EndRenderPass();
VkImageTransition()
.AddImage(image, VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL, true)
.AddImage(image, VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL, false)
.Execute(mCommands->GetDrawCommands());
mRenderState->SetRenderTarget(image, depthStencil->View.get(), image->Image->width, image->Image->height, VK_FORMAT_R8G8B8A8_UNORM, VK_SAMPLE_COUNT_1_BIT);