Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(170)

Unified Diff: tools/VisualBench/VisualStreamTimingModule.cpp

Issue 1416063002: Force VisualBench to reset GLContext on GrContext reset (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: tweaks Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« tools/VisualBench/VisualBench.cpp ('K') | « tools/VisualBench/VisualBench.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/VisualBench/VisualStreamTimingModule.cpp
diff --git a/tools/VisualBench/VisualStreamTimingModule.cpp b/tools/VisualBench/VisualStreamTimingModule.cpp
index 0a57e672211a2152053545bf114200325061f9c7..cecc5acca7284a635a7eae4236c806d164cf14a1 100644
--- a/tools/VisualBench/VisualStreamTimingModule.cpp
+++ b/tools/VisualBench/VisualStreamTimingModule.cpp
@@ -19,10 +19,12 @@ VisualStreamTimingModule::VisualStreamTimingModule(VisualBench* owner, bool preW
inline void VisualStreamTimingModule::handleInitState(SkCanvas* canvas) {
switch (fInitState) {
case kNewBenchmark_InitState:
- fOwner->clear(canvas, SK_ColorWHITE, 2);
fBenchmarkStream->current()->delayedSetup();
// fallthrough
case kReset_InitState:
+ // This will flicker unfortunately, but as we are reseting the GLContext each bench,
+ // we unfortunately don't have a choice
+ fOwner->clear(canvas, SK_ColorWHITE, 2);
fBenchmarkStream->current()->preTimingHooks(canvas);
break;
case kNone_InitState:
« tools/VisualBench/VisualBench.cpp ('K') | « tools/VisualBench/VisualBench.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698