| // Copyright 2013 The Chromium Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| #ifndef CC_BENCHMARKS_MICRO_BENCHMARK_IMPL_H_ |
| #define CC_BENCHMARKS_MICRO_BENCHMARK_IMPL_H_ |
| #include "base/callback.h" |
| #include "base/memory/scoped_refptr.h" |
| #include "cc/cc_export.h" |
| class SingleThreadTaskRunner; |
| class CC_EXPORT MicroBenchmarkImpl { |
| using DoneCallback = base::OnceCallback<void(base::Value)>; |
| explicit MicroBenchmarkImpl( |
| scoped_refptr<base::SingleThreadTaskRunner> origin_task_runner); |
| virtual ~MicroBenchmarkImpl(); |
| virtual void DidCompleteCommit(LayerTreeHostImpl* host); |
| virtual void RunOnLayer(LayerImpl* layer); |
| virtual void RunOnLayer(PictureLayerImpl* layer); |
| void NotifyDone(base::Value result); |
| scoped_refptr<base::SingleThreadTaskRunner> origin_task_runner_; |
| #endif // CC_BENCHMARKS_MICRO_BENCHMARK_IMPL_H_ |