Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(785)

Unified Diff: src/gpu/vk/GrVkGpuCommandBuffer.cpp

Issue 2274663005: Add GrVkCopyPipeline to handle vulkan copies as draws (Closed) Base URL: https://skia.googlesource.com/skia.git@compatibleCopyDS
Patch Set: indent nits Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/vk/GrVkGpu.cpp ('k') | src/gpu/vk/GrVkMemory.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/vk/GrVkGpuCommandBuffer.cpp
diff --git a/src/gpu/vk/GrVkGpuCommandBuffer.cpp b/src/gpu/vk/GrVkGpuCommandBuffer.cpp
index a5840699b88dbafdc62b9109bdbc36e6dae89294..81edc2ecf51c4150dfc2dabccc9ef8b41e9d3abd 100644
--- a/src/gpu/vk/GrVkGpuCommandBuffer.cpp
+++ b/src/gpu/vk/GrVkGpuCommandBuffer.cpp
@@ -118,10 +118,12 @@ void GrVkGpuCommandBuffer::onSubmit(const SkIRect& bounds) {
// we don't attach the resolve to the framebuffer so no need to change its layout.
GrVkImage* targetImage = fRenderTarget->msaaImage() ? fRenderTarget->msaaImage()
: fRenderTarget;
+
+ // Change layout of our render target so it can be used as the color attachment
targetImage->setImageLayout(fGpu,
VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL,
VK_ACCESS_COLOR_ATTACHMENT_WRITE_BIT,
- VK_PIPELINE_STAGE_TOP_OF_PIPE_BIT,
+ VK_PIPELINE_STAGE_ALL_GRAPHICS_BIT,
false);
// If we are using a stencil attachment we also need to update its layout
@@ -131,7 +133,7 @@ void GrVkGpuCommandBuffer::onSubmit(const SkIRect& bounds) {
VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL,
VK_ACCESS_DEPTH_STENCIL_ATTACHMENT_WRITE_BIT |
VK_ACCESS_DEPTH_STENCIL_ATTACHMENT_READ_BIT,
- VK_PIPELINE_STAGE_TOP_OF_PIPE_BIT,
+ VK_PIPELINE_STAGE_ALL_GRAPHICS_BIT,
false);
}
« no previous file with comments | « src/gpu/vk/GrVkGpu.cpp ('k') | src/gpu/vk/GrVkMemory.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698