aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkRecordDraw.h
diff options
context:
space:
mode:
authorGravatar mtklein <mtklein@chromium.org>2015-10-24 07:45:47 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2015-10-24 07:45:47 -0700
commit40732b34a1bf94eb44ee4b2327eece8d97735f11 (patch)
treec38580dad6fbf4a4abcf8885b53656b3d9757f14 /src/core/SkRecordDraw.h
parent6df232d251cefe8f3498a1ae4dad449bafa9ebb3 (diff)
SkRecord refactor: fill bounds array instead of BBH directly
This should be a strict refactor, just pulling out the bounds array. (It's the rescued nice parts of a dead-end CL targeting skia:4492.) BUG=skia: Review URL: https://codereview.chromium.org/1424553002
Diffstat (limited to 'src/core/SkRecordDraw.h')
-rw-r--r--src/core/SkRecordDraw.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/core/SkRecordDraw.h b/src/core/SkRecordDraw.h
index c2db37aebd..fdf98824ac 100644
--- a/src/core/SkRecordDraw.h
+++ b/src/core/SkRecordDraw.h
@@ -17,12 +17,14 @@
class SkDrawable;
class SkLayerInfo;
-// Fill a BBH to be used by SkRecordDraw to accelerate playback.
-void SkRecordFillBounds(const SkRect& cullRect, const SkRecord&, SkBBoxHierarchy*);
+// Calculate conservative identity space bounds for each op in the record.
+void SkRecordFillBounds(const SkRect& cullRect, const SkRecord&, SkRect bounds[]);
-void SkRecordComputeLayers(const SkRect& cullRect, const SkRecord& record,
- const SkBigPicture::SnapshotArray*,
- SkBBoxHierarchy* bbh, SkLayerInfo* data);
+// SkRecordFillBounds(), and gathers information about saveLayers and stores it for later
+// use (e.g., layer hoisting). The gathered information is sufficient to determine
+// where each saveLayer will land and which ops in the picture it represents.
+void SkRecordComputeLayers(const SkRect& cullRect, const SkRecord&, SkRect bounds[],
+ const SkBigPicture::SnapshotArray*, SkLayerInfo* data);
// Draw an SkRecord into an SkCanvas. A convenience wrapper around SkRecords::Draw.
void SkRecordDraw(const SkRecord&, SkCanvas*, SkPicture const* const drawablePicts[],