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

Unified Diff: tools/VisualBench.h

Issue 1159213002: Expand VisualBench to a real benching tool (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: tweaks Created 5 years, 7 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
Index: tools/VisualBench.h
diff --git a/tools/VisualBench.h b/tools/VisualBench.h
index d9e0b508669c34ad799f9b8e5adf49495cdb0319..9fd733dcf147636a1d9f3ccdda533545d974b536 100644
--- a/tools/VisualBench.h
+++ b/tools/VisualBench.h
@@ -38,12 +38,20 @@ protected:
private:
void setTitle();
bool setupBackend();
+ void resetContext();
void setupRenderTarget();
bool onHandleChar(SkUnichar unichar) override;
+ void timeFrame(SkCanvas*);
+ void printStats();
+
+ struct Timing {
+ SkString fName;
+ SkTArray<double> fMeasurements;
+ };
- int fCurrentLoops;
int fCurrentPicture;
int fCurrentFrame;
+ SkTArray<Timing> fTimings;
SkTArray<SkPicture*> fPictures;
// support framework

Powered by Google App Engine
This is Rietveld 408576698