Chromium Code Reviews| Index: include/core/SkPicture.h |
| diff --git a/include/core/SkPicture.h b/include/core/SkPicture.h |
| index c4c6f20326455f7f102f9ed8f833e3f9c85eb1d3..8398bc80c1472401169a41a583665098f2ca1c43 100644 |
| --- a/include/core/SkPicture.h |
| +++ b/include/core/SkPicture.h |
| @@ -259,11 +259,13 @@ private: |
| void createHeader(SkPictInfo* info) const; |
| static bool IsValidPictInfo(const SkPictInfo& info); |
| - // Takes ownership of the SkRecord, refs the (optional) BBH. |
| - SkPicture(SkScalar width, SkScalar height, SkRecord*, SkBBoxHierarchy*); |
| + // Takes ownership of the SkRecord, refs the (optional) drawablePicts and BBH. |
| + SkPicture(SkScalar width, SkScalar height, SkRecord*, SkData* drawablePicts, |
| + SkBBoxHierarchy*); |
| static SkPicture* Forwardport(const SkPictInfo&, const SkPictureData*); |
| - static SkPictureData* Backport(const SkRecord&, const SkPictInfo&); |
| + static SkPictureData* Backport(const SkRecord&, const SkPictInfo&, |
| + SkPicture* const drawablePics[], int drawableCount); |
| const SkScalar fCullWidth; |
| const SkScalar fCullHeight; |
| @@ -271,6 +273,15 @@ private: |
| mutable SkTDArray<DeletionListener*> fDeletionListeners; // pointers are refed |
| SkAutoTDelete<SkRecord> fRecord; |
| SkAutoTUnref<SkBBoxHierarchy> fBBH; |
| + SkAutoTUnref<SkData> fDrawablePicts; |
|
mtklein
2014/11/17 20:40:33
Let's start with SkTDArray<const SkPicture*>, pass
reed1
2014/11/17 21:27:44
as we discussed, pass by value is complicated, sin
|
| + |
| + // helpers for fDrawablePicts |
| + int drawableCount() const; |
| + // will return NULL if drawableCount() returns 0 |
| + SkPicture* const* drawablePicts() const; |
| + |
| + struct PathCounter; |
| + |
| struct Analysis { |
| Analysis() {} // Only used by SkPictureData codepath. |
| explicit Analysis(const SkRecord&); |