diff options
author | halcanary <halcanary@google.com> | 2015-03-20 12:31:52 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-03-20 12:31:52 -0700 |
commit | db0dcc7436375e5d59c27f9011f09b64de407c9d (patch) | |
tree | 2824c96cb508e352be54b2f483d11006bdfd52bf /src/pdf/SkPDFBitmap.h | |
parent | bf0c56f82bc2a275377d35f45b768ed227e4f9b8 (diff) |
PDF: remove last use of SkPDFImage
Add a GM.
BUG=skia:255
Review URL: https://codereview.chromium.org/950633003
Diffstat (limited to 'src/pdf/SkPDFBitmap.h')
-rw-r--r-- | src/pdf/SkPDFBitmap.h | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/pdf/SkPDFBitmap.h b/src/pdf/SkPDFBitmap.h index 45a8aa6350..02a79df24e 100644 --- a/src/pdf/SkPDFBitmap.h +++ b/src/pdf/SkPDFBitmap.h @@ -17,18 +17,15 @@ class SkPDFCanon; * It is designed to use a minimal amout of memory, aside from refing * the bitmap's pixels, and its emitObject() does not cache any data. * - * As of now, it only supports 8888 bitmaps (the most common case). + * If !bitmap.isImmutable(), then a copy of the bitmap must be made; + * there is no way around this. * * The SkPDFBitmap::Create function will check the canon for duplicates. */ class SkPDFBitmap : public SkPDFObject { public: // Returns NULL on unsupported bitmap; - // TODO(halcanary): support other bitmap colortypes and replace - // SkPDFImage. - static SkPDFBitmap* Create(SkPDFCanon*, - const SkBitmap&, - const SkIRect& subset); + static SkPDFBitmap* Create(SkPDFCanon*, const SkBitmap&); ~SkPDFBitmap(); void emitObject(SkWStream*, SkPDFCatalog*) SK_OVERRIDE; void addResources(SkTSet<SkPDFObject*>* resourceSet, @@ -43,7 +40,7 @@ private: const SkBitmap fBitmap; const SkAutoTUnref<SkPDFObject> fSMask; SkPDFBitmap(const SkBitmap&, SkPDFObject*); - void emitDict(SkWStream*, SkPDFCatalog*, size_t, bool) const; + void emitDict(SkWStream*, SkPDFCatalog*, size_t) const; }; #endif // SkPDFBitmap_DEFINED |