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

Unified Diff: src/core/SkRecorder.h

Issue 1112523006: Sketch splitting SkPicture into an interface and SkBigPicture. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: note Created 5 years, 7 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/SkRecordDraw.cpp ('k') | src/core/SkRecorder.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkRecorder.h
diff --git a/src/core/SkRecorder.h b/src/core/SkRecorder.h
index d0a992fc082f85fcbeaef70553d808f9a1ff711e..b6f153dc54824f533f6a4b0de1ab61f4302b5268 100644
--- a/src/core/SkRecorder.h
+++ b/src/core/SkRecorder.h
@@ -8,7 +8,9 @@
#ifndef SkRecorder_DEFINED
#define SkRecorder_DEFINED
+#include "SkBigPicture.h"
#include "SkCanvas.h"
+#include "SkMiniRecorder.h"
#include "SkRecord.h"
#include "SkRecords.h"
#include "SkTDArray.h"
@@ -25,7 +27,7 @@ public:
void append(SkDrawable* drawable);
// Return a new or ref'd array of pictures that were snapped from our drawables.
- SkPicture::SnapshotArray* newDrawableSnapshot();
+ SkBigPicture::SnapshotArray* newDrawableSnapshot();
private:
SkTDArray<SkDrawable*> fArray;
@@ -36,10 +38,10 @@ private:
class SkRecorder : public SkCanvas {
public:
// Does not take ownership of the SkRecord.
- SkRecorder(SkRecord*, int width, int height); // legacy version
- SkRecorder(SkRecord*, const SkRect& bounds);
+ SkRecorder(SkRecord*, int width, int height, SkMiniRecorder* = nullptr); // legacy version
+ SkRecorder(SkRecord*, const SkRect& bounds, SkMiniRecorder* = nullptr);
- void reset(SkRecord*, const SkRect& bounds);
+ void reset(SkRecord*, const SkRect& bounds, SkMiniRecorder* = nullptr);
size_t approxBytesUsedBySubPictures() const { return fApproxBytesUsedBySubPictures; }
@@ -120,6 +122,8 @@ public:
SkSurface* onNewSurface(const SkImageInfo&, const SkSurfaceProps&) override { return NULL; }
+ void flushMiniRecorder();
+
private:
template <typename T>
T* copy(const T*);
@@ -136,6 +140,8 @@ private:
size_t fApproxBytesUsedBySubPictures;
SkRecord* fRecord;
SkAutoTDelete<SkDrawableList> fDrawableList;
+
+ SkMiniRecorder* fMiniRecorder;
};
#endif//SkRecorder_DEFINED
« no previous file with comments | « src/core/SkRecordDraw.cpp ('k') | src/core/SkRecorder.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698