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

Unified Diff: src/codec/SkJpegCodec.h

Issue 1260673002: SkScaledCodec class (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Remove PartialNativeScaling Created 5 years, 4 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
Index: src/codec/SkJpegCodec.h
diff --git a/src/codec/SkJpegCodec.h b/src/codec/SkJpegCodec.h
index 1844269e6b3eff13a2e53dd636a8845e299c8739..794866ef112fa4202c9d97e7c6542356bcfef05b 100644
--- a/src/codec/SkJpegCodec.h
+++ b/src/codec/SkJpegCodec.h
@@ -60,6 +60,7 @@ protected:
SkPMColor ctable[], int* ctableCount) override;
private:
+ SkAutoTDelete<SkSwizzler> fSwizzler;
/*
* Read enough of the stream to initialize the SkJpegCodec.
@@ -95,6 +96,12 @@ private:
SkJpegCodec(const SkImageInfo& srcInfo, SkStream* stream, JpegDecoderMgr* decoderMgr);
/*
+ * Create the swizzler based on the encoded format
+ */
+ Result initializeSwizzler(const SkImageInfo& requestedInfo, void* dst, size_t rowBytes,
+ const Options&, SkPMColor*, int* ctableCount);
+
+ /*
* Handles rewinding the input stream if it is necessary
*/
bool handleRewind();
@@ -107,19 +114,14 @@ private:
bool setOutputColorSpace(const SkImageInfo& dst);
/*
- * Checks if we can scale to the requested dimensions and scales the dimensions
- * if possible
+ * Checks if we can natively scale to the requested dimensions and natively scales the
+ * dimensions if possible
*/
- bool scaleToDimensions(uint32_t width, uint32_t height);
-
- /*
- * Create the swizzler based on the encoded format
- */
- void initializeSwizzler(const SkImageInfo& dstInfo, void* dst, size_t dstRowBytes,
- const Options& options);
+ bool nativelyScaleToDimensions(uint32_t width, uint32_t height);
SkAutoTDelete<JpegDecoderMgr> fDecoderMgr;
-
+ int fPartialDenom;
scroggo 2015/08/05 15:36:01 It looks like these are no longer used?
+ int fPartialNum;
friend class SkJpegScanlineDecoder;
typedef SkCodec INHERITED;

Powered by Google App Engine
This is Rietveld 408576698