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

Unified Diff: src/codec/SkSwizzler.h

Issue 1665583002: Handle gray alpha conversions in SkSwizzler (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Compile in Debug mode :) Created 4 years, 11 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/codec/SkPngCodec.cpp ('k') | src/codec/SkSwizzler.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/codec/SkSwizzler.h
diff --git a/src/codec/SkSwizzler.h b/src/codec/SkSwizzler.h
index eebf886993b1663640577e4f5558826bc8fd48e9..7eebe7f98156506ebd4f45837e2021909fc3b972 100644
--- a/src/codec/SkSwizzler.h
+++ b/src/codec/SkSwizzler.h
@@ -22,6 +22,7 @@ public:
kUnknown, // Invalid type.
kBit, // A single bit to distinguish between white and black.
kGray,
+ kGrayAlpha,
kIndex1,
kIndex2,
kIndex4,
@@ -55,6 +56,7 @@ public:
case kIndex:
case kNoOp8:
return 8;
+ case kGrayAlpha:
case kNoOp16:
return 16;
case kRGB:
@@ -162,6 +164,10 @@ private:
int dstWidth, int bpp, int deltaSrc, int offset,
const SkPMColor ctable[]);
+ template <RowProc Proc>
+ static void SkipLeadingGrayAlphaZerosThen(void* dst, const uint8_t* src, int width, int bpp,
+ int deltaSrc, int offset, const SkPMColor ctable[]);
+
// May be NULL. We have not implemented optimized functions for all supported transforms.
const RowProc fFastProc;
// Always non-NULL. Supports sampling.
« no previous file with comments | « src/codec/SkPngCodec.cpp ('k') | src/codec/SkSwizzler.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698