| 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 // Audio rendering unit utilizing an AudioRendererSink to output data. | 5 // Audio rendering unit utilizing an AudioRendererSink to output data. |
| 6 // | 6 // |
| 7 // This class lives inside three threads during it's lifetime, namely: | 7 // This class lives inside three threads during it's lifetime, namely: |
| 8 // 1. Render thread | 8 // 1. Render thread |
| 9 // Where the object is created. | 9 // Where the object is created. |
| 10 // 2. Media thread (provided via constructor) | 10 // 2. Media thread (provided via constructor) |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 61 const scoped_refptr<base::SingleThreadTaskRunner>& task_runner, | 61 const scoped_refptr<base::SingleThreadTaskRunner>& task_runner, |
| 62 AudioRendererSink* sink, | 62 AudioRendererSink* sink, |
| 63 ScopedVector<AudioDecoder> decoders, | 63 ScopedVector<AudioDecoder> decoders, |
| 64 const AudioHardwareConfig& hardware_config, | 64 const AudioHardwareConfig& hardware_config, |
| 65 const scoped_refptr<MediaLog>& media_log); | 65 const scoped_refptr<MediaLog>& media_log); |
| 66 ~AudioRendererImpl() override; | 66 ~AudioRendererImpl() override; |
| 67 | 67 |
| 68 // TimeSource implementation. | 68 // TimeSource implementation. |
| 69 void StartTicking() override; | 69 void StartTicking() override; |
| 70 void StopTicking() override; | 70 void StopTicking() override; |
| 71 void SetPlaybackRate(float rate) override; | 71 void SetPlaybackRate(double rate) override; |
| 72 void SetMediaTime(base::TimeDelta time) override; | 72 void SetMediaTime(base::TimeDelta time) override; |
| 73 base::TimeDelta CurrentMediaTime() override; | 73 base::TimeDelta CurrentMediaTime() override; |
| 74 base::TimeTicks GetWallClockTime(base::TimeDelta time) override; | 74 base::TimeTicks GetWallClockTime(base::TimeDelta time) override; |
| 75 | 75 |
| 76 // AudioRenderer implementation. | 76 // AudioRenderer implementation. |
| 77 void Initialize(DemuxerStream* stream, | 77 void Initialize(DemuxerStream* stream, |
| 78 const PipelineStatusCB& init_cb, | 78 const PipelineStatusCB& init_cb, |
| 79 const SetDecryptorReadyCB& set_decryptor_ready_cb, | 79 const SetDecryptorReadyCB& set_decryptor_ready_cb, |
| 80 const StatisticsCB& statistics_cb, | 80 const StatisticsCB& statistics_cb, |
| 81 const BufferingStateCB& buffering_state_cb, | 81 const BufferingStateCB& buffering_state_cb, |
| (...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 266 | 266 |
| 267 // NOTE: Weak pointers must be invalidated before all other member variables. | 267 // NOTE: Weak pointers must be invalidated before all other member variables. |
| 268 base::WeakPtrFactory<AudioRendererImpl> weak_factory_; | 268 base::WeakPtrFactory<AudioRendererImpl> weak_factory_; |
| 269 | 269 |
| 270 DISALLOW_COPY_AND_ASSIGN(AudioRendererImpl); | 270 DISALLOW_COPY_AND_ASSIGN(AudioRendererImpl); |
| 271 }; | 271 }; |
| 272 | 272 |
| 273 } // namespace media | 273 } // namespace media |
| 274 | 274 |
| 275 #endif // MEDIA_RENDERERS_AUDIO_RENDERER_IMPL_H_ | 275 #endif // MEDIA_RENDERERS_AUDIO_RENDERER_IMPL_H_ |
| OLD | NEW |