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

Side by Side Diff: tools/VisualBench/VisualStreamTimingModule.h

Issue 1392833006: Revert of small tidy of benchmarkstream (Closed) Base URL: https://skia.googlesource.com/skia.git@vb4b
Patch Set: 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright 2015 Google Inc. 2 * Copyright 2015 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef VisualStreamTimingModule_DEFINED 8 #ifndef VisualStreamTimingModule_DEFINED
9 #define VisualStreamTimingModule_DEFINED 9 #define VisualStreamTimingModule_DEFINED
10 10
(...skipping 13 matching lines...) Expand all
24 public: 24 public:
25 VisualStreamTimingModule(VisualBench* owner, bool preWarmBeforeSample); 25 VisualStreamTimingModule(VisualBench* owner, bool preWarmBeforeSample);
26 void draw(SkCanvas* canvas) override; 26 void draw(SkCanvas* canvas) override;
27 27
28 private: 28 private:
29 virtual void renderFrame(SkCanvas*, Benchmark*, int loops)=0; 29 virtual void renderFrame(SkCanvas*, Benchmark*, int loops)=0;
30 30
31 // subclasses should return true to advance the stream 31 // subclasses should return true to advance the stream
32 virtual bool timingFinished(Benchmark*, int loops, double measurement)=0; 32 virtual bool timingFinished(Benchmark*, int loops, double measurement)=0;
33 33
34 bool nextBenchmarkIfNecessary(SkCanvas*);
35
34 TimingStateMachine fTSM; 36 TimingStateMachine fTSM;
35 SkAutoTDelete<VisualBenchmarkStream> fBenchmarkStream; 37 SkAutoTDelete<VisualBenchmarkStream> fBenchmarkStream;
38 SkAutoTUnref<Benchmark> fBenchmark;
36 bool fReinitializeBenchmark; 39 bool fReinitializeBenchmark;
37 bool fPreWarmBeforeSample; 40 bool fPreWarmBeforeSample;
38 41
39 // support framework 42 // support framework
40 VisualBench* fOwner; 43 VisualBench* fOwner;
41 44
42 typedef VisualModule INHERITED; 45 typedef VisualModule INHERITED;
43 }; 46 };
44 47
45 #endif 48 #endif
OLDNEW
« no previous file with comments | « tools/VisualBench/VisualBenchmarkStream.cpp ('k') | tools/VisualBench/VisualStreamTimingModule.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698