OLD | NEW |
1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "cc/scheduler/delay_based_time_source.h" | 5 #include "cc/scheduler/delay_based_time_source.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <cmath> | 8 #include <cmath> |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "base/bind.h" | 11 #include "base/bind.h" |
12 #include "base/debug/trace_event.h" | |
13 #include "base/debug/trace_event_argument.h" | |
14 #include "base/location.h" | 12 #include "base/location.h" |
15 #include "base/logging.h" | 13 #include "base/logging.h" |
16 #include "base/single_thread_task_runner.h" | 14 #include "base/single_thread_task_runner.h" |
| 15 #include "base/trace_event/trace_event.h" |
| 16 #include "base/trace_event/trace_event_argument.h" |
17 | 17 |
18 namespace cc { | 18 namespace cc { |
19 | 19 |
20 namespace { | 20 namespace { |
21 | 21 |
22 // kDoubleTickDivisor prevents ticks from running within the specified | 22 // kDoubleTickDivisor prevents ticks from running within the specified |
23 // fraction of an interval. This helps account for jitter in the timebase as | 23 // fraction of an interval. This helps account for jitter in the timebase as |
24 // well as quick timer reactivation. | 24 // well as quick timer reactivation. |
25 static const int kDoubleTickDivisor = 2; | 25 static const int kDoubleTickDivisor = 2; |
26 | 26 |
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
305 state->BeginDictionary("next_parameters"); | 305 state->BeginDictionary("next_parameters"); |
306 state->SetDouble("interval_us", next_parameters_.interval.InMicroseconds()); | 306 state->SetDouble("interval_us", next_parameters_.interval.InMicroseconds()); |
307 state->SetDouble("tick_target_us", | 307 state->SetDouble("tick_target_us", |
308 next_parameters_.tick_target.ToInternalValue()); | 308 next_parameters_.tick_target.ToInternalValue()); |
309 state->EndDictionary(); | 309 state->EndDictionary(); |
310 | 310 |
311 state->SetBoolean("active", active_); | 311 state->SetBoolean("active", active_); |
312 } | 312 } |
313 | 313 |
314 } // namespace cc | 314 } // namespace cc |
OLD | NEW |