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

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

Issue 2039913007: Fix mipmap generation on Nexus 5x & 6p devices. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 6 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/vk/GrVkGpu.cpp
diff --git a/src/gpu/vk/GrVkGpu.cpp b/src/gpu/vk/GrVkGpu.cpp
index fb533e317ed20be2176efeb951e02d36afa099d8..36713ec821beb616779d8c804c13399efbc57e4d 100644
--- a/src/gpu/vk/GrVkGpu.cpp
+++ b/src/gpu/vk/GrVkGpu.cpp
@@ -734,10 +734,10 @@ void GrVkGpu::generateMipmap(GrVkTexture* tex) const {
memset(&blitRegion, 0, sizeof(VkImageBlit));
blitRegion.srcSubresource = { VK_IMAGE_ASPECT_COLOR_BIT, 0, 0, 1 };
blitRegion.srcOffsets[0] = { 0, 0, 0 };
- blitRegion.srcOffsets[1] = { width, height, 0 };
+ blitRegion.srcOffsets[1] = { width, height, 1 };
blitRegion.dstSubresource = { VK_IMAGE_ASPECT_COLOR_BIT, 0, 0, 1 };
blitRegion.dstOffsets[0] = { 0, 0, 0 };
- blitRegion.dstOffsets[1] = { width, height, 0 };
+ blitRegion.dstOffsets[1] = { width, height, 1 };
fCurrentCmdBuffer->blitImage(this,
oldResource,
@@ -780,10 +780,10 @@ void GrVkGpu::generateMipmap(GrVkTexture* tex) const {
blitRegion.srcSubresource = { VK_IMAGE_ASPECT_COLOR_BIT, mipLevel - 1, 0, 1 };
blitRegion.srcOffsets[0] = { 0, 0, 0 };
- blitRegion.srcOffsets[1] = { prevWidth, prevHeight, 0 };
+ blitRegion.srcOffsets[1] = { prevWidth, prevHeight, 1 };
blitRegion.dstSubresource = { VK_IMAGE_ASPECT_COLOR_BIT, mipLevel, 0, 1 };
blitRegion.dstOffsets[0] = { 0, 0, 0 };
- blitRegion.dstOffsets[1] = { width, height, 0 };
+ blitRegion.dstOffsets[1] = { width, height, 1 };
fCurrentCmdBuffer->blitImage(this,
*tex,
*tex,
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698