commit | 38c05871c66292b1db7a98a67df7ee7cfd12bca3 | [log] [tgz] |
---|---|---|
author | mtklein <mtklein@chromium.org> | Thu Oct 02 13:03:58 2014 -0700 |
committer | Commit bot <commit-bot@chromium.org> | Thu Oct 02 13:03:58 2014 -0700 |
tree | eecfd88310619a8bb5499e130583b47d7bcf7a7d | |
parent | 0a528c187ab2221e9720d17d1bc76123b5fa8788 [diff] [blame] |
Save/Restore around bench runs. BUG=skia: Review URL: https://codereview.chromium.org/619353002
diff --git a/bench/Benchmark.cpp b/bench/Benchmark.cpp index 9205ba9..88e385d 100644 --- a/bench/Benchmark.cpp +++ b/bench/Benchmark.cpp
@@ -7,6 +7,7 @@ #include "Benchmark.h" +#include "SkCanvas.h" #include "SkPaint.h" #include "SkParse.h" @@ -37,6 +38,7 @@ } void Benchmark::draw(const int loops, SkCanvas* canvas) { + SkAutoCanvasRestore ar(canvas, true/*save now*/); this->onDraw(loops, canvas); }