aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorGravatar Brian Osman <brianosman@google.com>2017-03-20 13:11:36 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-03-20 17:50:51 +0000
commit628999dd99a10a737470c5c89c44ae28b6a764bf (patch)
treef749cc041859f5702d32a61b60dce1bfca91dac2 /src
parentf9bd468325fbce7a9eb5b1ce28537f628c4f8535 (diff)
Gray8 is supported on GPU, remove incorrect comments & check
BUG=skia: Change-Id: I3e5cb94b1e903d1b6ebbc36675d1c4082aef6841 Reviewed-on: https://skia-review.googlesource.com/9899 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Brian Osman <brianosman@google.com>
Diffstat (limited to 'src')
-rw-r--r--src/gpu/SkGr.cpp9
1 files changed, 0 insertions, 9 deletions
diff --git a/src/gpu/SkGr.cpp b/src/gpu/SkGr.cpp
index 9ba094714e..18f2abb951 100644
--- a/src/gpu/SkGr.cpp
+++ b/src/gpu/SkGr.cpp
@@ -238,15 +238,6 @@ GrTexture* GrGenerateMipMapsAndUploadToTexture(GrContext* ctx, const SkBitmap& b
GrSurfaceDesc desc = GrImageInfoToSurfaceDesc(bitmap.info(), *ctx->caps());
- // We don't support Gray8 directly in the GL backend, so fail-over to GrUploadBitmapToTexture.
- // That will transform the Gray8 to 8888, then use the driver/GPU to build mipmaps. If we build
- // the mips on the CPU here, they'll all be Gray8, which isn't useful. (They get treated as A8).
- // TODO: A better option might be to transform the initial bitmap here to 8888, then run the
- // CPU mip-mapper on that data before uploading. This is much less code for a rare case though:
- if (kGray_8_SkColorType == bitmap.colorType()) {
- return nullptr;
- }
-
SkAutoPixmapUnlock srcUnlocker;
if (!bitmap.requestLock(&srcUnlocker)) {
return nullptr;