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

Unified Diff: src/codec/SkMaskSwizzler.h

Issue 1332053002: Fill incomplete images in SkCodec parent class (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Use aligned memory in swizzler test Created 5 years, 2 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/SkJpegCodec.cpp ('k') | src/codec/SkSampler.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/codec/SkMaskSwizzler.h
diff --git a/src/codec/SkMaskSwizzler.h b/src/codec/SkMaskSwizzler.h
index fbc951a070806e954896e56913e863360ca398ee..0513d838c743975759d51c1fd05164f21593b5ab 100644
--- a/src/codec/SkMaskSwizzler.h
+++ b/src/codec/SkMaskSwizzler.h
@@ -35,6 +35,15 @@ public:
*/
SkSwizzler::ResultAlpha swizzle(void* dst, const uint8_t* SK_RESTRICT src);
+ /**
+ * Implement fill using a custom width.
+ */
+ void fill(const SkImageInfo& info, void* dst, size_t rowBytes, uint32_t colorOrIndex,
+ SkCodec::ZeroInitialized zeroInit) override {
+ const SkImageInfo fillInfo = info.makeWH(fDstWidth, info.height());
+ SkSampler::Fill(fillInfo, dst, rowBytes, colorOrIndex, zeroInit);
+ }
+
private:
/*
« no previous file with comments | « src/codec/SkJpegCodec.cpp ('k') | src/codec/SkSampler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698