The motivation for this CL is to de-clutter SkPicture's beginRecording method.
R=reed@google.com
Author: robertphillips@google.com
Review URL: https://codereview.chromium.org/186813003
git-svn-id: http://skia.googlecode.com/svn/trunk@13658 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/src/core/SkPictureRecord.h b/src/core/SkPictureRecord.h
index 1b62f3d..e7c6d7f 100644
--- a/src/core/SkPictureRecord.h
+++ b/src/core/SkPictureRecord.h
@@ -103,6 +103,10 @@
void beginRecording();
void endRecording();
+ void internalOnly_EnableOpts(bool optsEnabled) {
+ fOptsEnabled = optsEnabled;
+ }
+
private:
void handleOptimization(int opt);
int recordRestoreOffsetPlaceholder(SkRegion::Op);
@@ -287,7 +291,8 @@
SkTDArray<SkPicture*> fPictureRefs;
uint32_t fRecordFlags;
- int fInitialSaveCount;
+ bool fOptsEnabled;
+ int fInitialSaveCount;
friend class SkPicturePlayback;
friend class SkPictureTester; // for unit testing