Index: src/images/SkDecodingImageGenerator.h |
diff --git a/src/images/SkDecodingImageGenerator.h b/src/images/SkDecodingImageGenerator.h |
index fef7c6c7c789a0f1e4d5a6af9834a649c33c04cb..17802433b166b446bc43f4ceb089945d4553bb94 100644 |
--- a/src/images/SkDecodingImageGenerator.h |
+++ b/src/images/SkDecodingImageGenerator.h |
@@ -18,15 +18,7 @@ class SkStreamRewindable; |
* An implementation of SkImageGenerator that calls into |
* SkImageDecoder. |
*/ |
-class SkDecodingImageGenerator : public SkImageGenerator { |
-public: |
- virtual ~SkDecodingImageGenerator(); |
- virtual SkData* refEncodedData() SK_OVERRIDE; |
- // This implementaion of getInfo() always returns true. |
- virtual bool getInfo(SkImageInfo* info) SK_OVERRIDE; |
- virtual bool getPixels(const SkImageInfo& info, |
- void* pixels, |
- size_t rowBytes) SK_OVERRIDE; |
+namespace SkDecodingImageGenerator { |
reed2
2014/04/04 20:59:51
Why namespace instead of class? Other examples in
|
/** |
* These options will be passed on to the image decoder. The |
* defaults are sensible. |
@@ -97,31 +89,15 @@ public: |
* |
* @return NULL on failure, a new SkImageGenerator on success. |
*/ |
- static SkImageGenerator* Create(SkStreamRewindable* stream, |
- const Options& opt); |
+ SkImageGenerator* Create(SkStreamRewindable* stream, |
+ const Options& opt); |
/** |
* @param data Contains the encoded image data that will be used by |
* the SkDecodingImageGenerator. Will be ref()ed by the |
* SkImageGenerator constructor and and unref()ed on deletion. |
*/ |
- static SkImageGenerator* Create(SkData* data, const Options& opt); |
- |
-private: |
- SkData* fData; |
- SkStreamRewindable* fStream; |
- const SkImageInfo fInfo; |
- const int fSampleSize; |
- const bool fDitherImage; |
- |
- SkDecodingImageGenerator(SkData* data, |
- SkStreamRewindable* stream, |
- const SkImageInfo& info, |
- int sampleSize, |
- bool ditherImage); |
- static SkImageGenerator* Create(SkData*, SkStreamRewindable*, |
- const Options&); |
- typedef SkImageGenerator INHERITED; |
+ SkImageGenerator* Create(SkData* data, const Options& opt); |
}; |
// // Example of most basic use case: |