From b6f4767294261dca3beef6f280c4bac69df3f930 Mon Sep 17 00:00:00 2001 From: Matt Sarett Date: Wed, 7 Jun 2017 16:30:19 -0400 Subject: Do not return Index8 from SkAndroidCodec::computeOutputColorType Given that this is the only known use of Index8 color type, this is essentially an experimental delete. Bug: skia:6620 Change-Id: Ib363d237e0217f6e7f461a62e54d32892c428095 Reviewed-on: https://skia-review.googlesource.com/10586 Reviewed-by: Leon Scroggins Commit-Queue: Matt Sarett --- dm/DMSrcSink.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'dm') diff --git a/dm/DMSrcSink.cpp b/dm/DMSrcSink.cpp index 4ac7e80626..1ffffd3bf0 100644 --- a/dm/DMSrcSink.cpp +++ b/dm/DMSrcSink.cpp @@ -173,6 +173,9 @@ Error BRDSrc::draw(SkCanvas* canvas) const { return "Cannot decode (full) region."; } alpha8_to_gray8(&bitmap); + + // Verify that we no longer support kIndex8 from this API. + SkASSERT(kIndex_8_SkColorType != bitmap.colorType()); canvas->drawBitmap(bitmap, 0, 0); return ""; } @@ -229,6 +232,7 @@ Error BRDSrc::draw(SkCanvas* canvas) const { } alpha8_to_gray8(&bitmap); + SkASSERT(kIndex_8_SkColorType != bitmap.colorType()); canvas->drawBitmapRect(bitmap, SkRect::MakeXYWH((SkScalar) scaledBorder, (SkScalar) scaledBorder, (SkScalar) (subsetWidth / fSampleSize), -- cgit v1.2.3