diff options
author | mtklein <mtklein@chromium.org> | 2015-07-01 07:04:37 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-07-01 07:04:37 -0700 |
commit | d711d115d28b9838303dcc232516aa2f552f3a2a (patch) | |
tree | a4ebfb7860017f4bcb3707c267ecbff4ee51e077 /include/core/SkPictureRecorder.h | |
parent | c0e80c139e15496a8a96eec7848689b6f0e7bcc1 (diff) |
Thread through a flag to force SkPicture::playback() when recording subpictures.
This makes nanobench picture recording benchmarks somewhat useful again,
as opposed to all taking about 5us to run no matter the content.
ATTN Sheriff: this will probably trigger perf.skia.org alerts.
BUG=skia:
Review URL: https://codereview.chromium.org/1219873002
Diffstat (limited to 'include/core/SkPictureRecorder.h')
-rw-r--r-- | include/core/SkPictureRecorder.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/include/core/SkPictureRecorder.h b/include/core/SkPictureRecorder.h index a84b721e44..811d02a36e 100644 --- a/include/core/SkPictureRecorder.h +++ b/include/core/SkPictureRecorder.h @@ -33,7 +33,11 @@ public: enum RecordFlags { // This flag indicates that, if some BHH is being computed, saveLayer // information should also be extracted at the same time. - kComputeSaveLayerInfo_RecordFlag = 0x01 + kComputeSaveLayerInfo_RecordFlag = 0x01, + + // If you call drawPicture() on the recording canvas, this flag forces + // that to use SkPicture::playback() immediately rather than (e.g.) reffing the picture. + kPlaybackDrawPicture_RecordFlag = 0x02, }; /** Returns the canvas that records the drawing commands. |