diff options
| author | brianosman <brianosman@google.com> | 2016-02-24 11:47:47 -0800 |
|---|---|---|
| committer | Commit bot <commit-bot@chromium.org> | 2016-02-24 11:47:47 -0800 |
| commit | ca34846584f57e0cd39edfc13e9263c29bf0dd03 (patch) | |
| tree | 6aa61efde7b44e7fde8f4f174cb8279ad0968dc5 /samplecode/SampleApp.cpp | |
| parent | 43437c2f1928073a30c2bab6d32df854658235ec (diff) | |
Added a flag that forces SampleApp to continuously redraw, even in non-animated tests. Helpful when profiling or debugging.
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1731853003
Review URL: https://codereview.chromium.org/1731853003
Diffstat (limited to 'samplecode/SampleApp.cpp')
| -rw-r--r-- | samplecode/SampleApp.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/samplecode/SampleApp.cpp b/samplecode/SampleApp.cpp index 61cd75149f..7ebac5f215 100644 --- a/samplecode/SampleApp.cpp +++ b/samplecode/SampleApp.cpp @@ -744,6 +744,7 @@ DEFINE_string(sequence, "", "Path to file containing the desired samples/gms to DEFINE_bool(sort, false, "Sort samples by title."); DEFINE_bool(list, false, "List samples?"); DEFINE_bool(gpu, false, "Start up with gpu?"); +DEFINE_bool(redraw, false, "Force continuous redrawing, for profiling or debugging tools."); DEFINE_string(key, "", ""); // dummy to enable gm tests that have platform-specific names #ifdef SAMPLE_PDF_FILE_VIEWER DEFINE_string(pdfPath, "", "Path to direcotry of pdf files."); @@ -1101,7 +1102,7 @@ void SampleWindow::draw(SkCanvas* canvas) { this->postInvalDelay(); } - if (this->sendAnimatePulse()) { + if (this->sendAnimatePulse() || FLAGS_redraw) { this->inval(nullptr); } |
