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

Unified Diff: src/core/SkPicturePlayback.h

Issue 227603006: hack Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: yet more hackage Created 6 years, 8 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/core/SkPicture.cpp ('k') | src/core/SkPicturePlayback.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkPicturePlayback.h
===================================================================
--- src/core/SkPicturePlayback.h (revision 14079)
+++ src/core/SkPicturePlayback.h (working copy)
@@ -87,8 +87,40 @@
const SkPicture::OperationList& getActiveOps(const SkIRect& queryRect);
- void draw(SkCanvas& canvas, SkDrawPictureCallback*);
+ struct Foo {
+ public:
+ size_t fStart;
+ size_t fStop;
+ SkIPoint fPos;
+ SkBitmap* fBM;
+ const SkPaint* fPaint;
+ };
+ class Bar {
+ public:
+ ~Bar() {
+ this->freeAll();
+ }
+
+ Foo* lookupStart(size_t start);
+ Foo* lookupStop(size_t stop);
+ Foo* push() {
+ return fFoo.push();
+ }
+
+ void freeAll() {
+ for (int i = 0; i < fFoo.count(); ++i) {
+ SkDELETE(fFoo[i].fBM);
+ fFoo[i].fBM = NULL;
+ }
+ }
+
+ private:
+ SkTDArray<Foo> fFoo;
+ };
+
+ void draw(SkCanvas& canvas, int start, int stop, SkDrawPictureCallback*, Bar* bar);
+
void serialize(SkWStream*, SkPicture::EncodeBitmap) const;
void flatten(SkWriteBuffer&) const;
« no previous file with comments | « src/core/SkPicture.cpp ('k') | src/core/SkPicturePlayback.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698