diff options
-rw-r--r-- | src/gui/rhi/qrhivulkan.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/rhi/qrhivulkan.cpp b/src/gui/rhi/qrhivulkan.cpp index f94f27a79e1..c0ade70bf7a 100644 --- a/src/gui/rhi/qrhivulkan.cpp +++ b/src/gui/rhi/qrhivulkan.cpp @@ -4369,7 +4369,7 @@ void QRhiVulkan::enqueueResourceUpdates(QVkCommandBuffer *cbD, QRhiResourceUpdat // Copy from the (optimal and not host visible) image into the buffer. VkBufferImageCopy copyDesc = {}; copyDesc.bufferOffset = 0; - copyDesc.imageSubresource.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT; + copyDesc.imageSubresource.aspectMask = aspectMaskForTextureFormat(readback.format); copyDesc.imageSubresource.mipLevel = uint32_t(u.rb.level()); copyDesc.imageSubresource.baseArrayLayer = is3D ? 0 : uint32_t(u.rb.layer()); copyDesc.imageSubresource.layerCount = 1; |