Add Gray8 pixel config
authorBrian Osman <brianosman@google.com>
Mon, 9 Jan 2017 20:32:57 +0000 (15:32 -0500)
committerSkia Commit-Bot <skia-commit-bot@chromium.org>
Tue, 10 Jan 2017 16:20:03 +0000 (16:20 +0000)
commitf2956459f707de596dcb2c79a7ee1fa62d599c0d
tree4c558c871bd88d8d599162b63864ce7083f58f0e
parente98234f231d66848e149db683c11b6388e10b233
Add Gray8 pixel config

This is still just linear (non-sRGB), but adding sRGB will
be the next step. I've verified that this is really making
R8 textures when uploading Gray8 bitmaps. Tests pass, and
the all_bitmap_configs GM still renders correctly (unlike
when we just mapped Gray8 to Alpha8).

This adds another pixel config, which could grow our cache
footprint, but the benefits of not using 4bpp for 1bpp data
should outweigh that?

BUG=skia:6110

Change-Id: I4fc4c2479fc25f1d278e174a9bb5b542a0cb184c
Reviewed-on: https://skia-review.googlesource.com/6817
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
include/gpu/GrColor.h
include/gpu/GrTypes.h
include/private/GrSwizzle.h
src/gpu/GrCaps.cpp
src/gpu/GrContext.cpp
src/gpu/GrShaderCaps.cpp
src/gpu/SkGr.cpp
src/gpu/gl/GrGLCaps.cpp
src/gpu/gl/GrGLDefines.h
src/gpu/gl/GrGLGpu.cpp
src/gpu/vk/GrVkUtil.cpp