Commit 0a9c0b7b by Jamie Madill Committed by Commit Bot

Vulkan: Fix image queue changes with graph disabled.

These again weren't being tested on the CQ. Probably necessary for some image sharing scenarios. Bug: angleproject:4029 Change-Id: Iccbebf127e2ec6fdb74dd213998674fff77b75b2 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2065529 Commit-Queue: Jamie Madill <jmadill@chromium.org> Reviewed-by: 's avatarMichael Spang <spang@chromium.org>
parent 475c527b
...@@ -126,7 +126,14 @@ angle::Result RenderbufferVk::setStorageEGLImageTarget(const gl::Context *contex ...@@ -126,7 +126,14 @@ angle::Result RenderbufferVk::setStorageEGLImageTarget(const gl::Context *contex
if (mImage->isQueueChangeNeccesary(rendererQueueFamilyIndex)) if (mImage->isQueueChangeNeccesary(rendererQueueFamilyIndex))
{ {
vk::CommandBuffer *commandBuffer = nullptr; vk::CommandBuffer *commandBuffer = nullptr;
ANGLE_TRY(mImage->recordCommands(contextVk, &commandBuffer)); if (contextVk->commandGraphEnabled())
{
ANGLE_TRY(mImage->recordCommands(contextVk, &commandBuffer));
}
else
{
ANGLE_TRY(contextVk->getOutsideRenderPassCommandBuffer(&commandBuffer));
}
mImage->changeLayoutAndQueue(aspect, vk::ImageLayout::ColorAttachment, mImage->changeLayoutAndQueue(aspect, vk::ImageLayout::ColorAttachment,
rendererQueueFamilyIndex, commandBuffer); rendererQueueFamilyIndex, commandBuffer);
} }
......
...@@ -862,7 +862,14 @@ angle::Result TextureVk::setEGLImageTarget(const gl::Context *context, ...@@ -862,7 +862,14 @@ angle::Result TextureVk::setEGLImageTarget(const gl::Context *context,
if (mImage->isQueueChangeNeccesary(rendererQueueFamilyIndex)) if (mImage->isQueueChangeNeccesary(rendererQueueFamilyIndex))
{ {
vk::CommandBuffer *commandBuffer = nullptr; vk::CommandBuffer *commandBuffer = nullptr;
ANGLE_TRY(mImage->recordCommands(contextVk, &commandBuffer)); if (contextVk->commandGraphEnabled())
{
ANGLE_TRY(mImage->recordCommands(contextVk, &commandBuffer));
}
else
{
ANGLE_TRY(contextVk->getOutsideRenderPassCommandBuffer(&commandBuffer));
}
mImage->changeLayoutAndQueue(VK_IMAGE_ASPECT_COLOR_BIT, mImage->changeLayoutAndQueue(VK_IMAGE_ASPECT_COLOR_BIT,
vk::ImageLayout::AllGraphicsShadersReadOnly, vk::ImageLayout::AllGraphicsShadersReadOnly,
rendererQueueFamilyIndex, commandBuffer); rendererQueueFamilyIndex, commandBuffer);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment