OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #ifndef MEDIA_AUDIO_AUDIO_OUTPUT_CONTROLLER_H_ | 5 #ifndef MEDIA_AUDIO_AUDIO_OUTPUT_CONTROLLER_H_ |
6 #define MEDIA_AUDIO_AUDIO_OUTPUT_CONTROLLER_H_ | 6 #define MEDIA_AUDIO_AUDIO_OUTPUT_CONTROLLER_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include "base/atomic_ref_count.h" | 10 #include "base/atomic_ref_count.h" |
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
249 SyncReader* const sync_reader_; | 249 SyncReader* const sync_reader_; |
250 | 250 |
251 // The message loop of audio manager thread that this object runs on. | 251 // The message loop of audio manager thread that this object runs on. |
252 const scoped_refptr<base::SingleThreadTaskRunner> message_loop_; | 252 const scoped_refptr<base::SingleThreadTaskRunner> message_loop_; |
253 | 253 |
254 // Scans audio samples from OnMoreData() as input to compute power levels. | 254 // Scans audio samples from OnMoreData() as input to compute power levels. |
255 AudioPowerMonitor power_monitor_; | 255 AudioPowerMonitor power_monitor_; |
256 | 256 |
257 // Flags when we've asked for a stream to start but it never did. | 257 // Flags when we've asked for a stream to start but it never did. |
258 base::AtomicRefCount on_more_io_data_called_; | 258 base::AtomicRefCount on_more_io_data_called_; |
259 scoped_ptr<base::OneShotTimer> wedge_timer_; | 259 std::unique_ptr<base::OneShotTimer> wedge_timer_; |
danakj
2016/04/22 22:47:36
include memory
dcheng
2016/04/22 23:13:20
Done.
| |
260 | 260 |
261 // Flag which indicates errors received during Stop/Close should be ignored. | 261 // Flag which indicates errors received during Stop/Close should be ignored. |
262 // These errors are generally harmless since a fresh stream is about to be | 262 // These errors are generally harmless since a fresh stream is about to be |
263 // recreated, but if forwarded, renderer side clients may consider them | 263 // recreated, but if forwarded, renderer side clients may consider them |
264 // catastrophic and abort their operations. | 264 // catastrophic and abort their operations. |
265 // | 265 // |
266 // If |stream_| is started then |ignore_errors_during_stop_close_| must only | 266 // If |stream_| is started then |ignore_errors_during_stop_close_| must only |
267 // be accessed while |error_lock_| is held. | 267 // be accessed while |error_lock_| is held. |
268 bool ignore_errors_during_stop_close_; | 268 bool ignore_errors_during_stop_close_; |
269 base::Lock error_lock_; | 269 base::Lock error_lock_; |
270 | 270 |
271 DISALLOW_COPY_AND_ASSIGN(AudioOutputController); | 271 DISALLOW_COPY_AND_ASSIGN(AudioOutputController); |
272 }; | 272 }; |
273 | 273 |
274 } // namespace media | 274 } // namespace media |
275 | 275 |
276 #endif // MEDIA_AUDIO_AUDIO_OUTPUT_CONTROLLER_H_ | 276 #endif // MEDIA_AUDIO_AUDIO_OUTPUT_CONTROLLER_H_ |
OLD | NEW |