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

Side by Side Diff: media/renderers/audio_renderer_impl.h

Issue 1094783002: Switch to double for time calculations using playback rate. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Making changes at chromecast side to fix trybots Created 5 years, 8 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
« no previous file with comments | « media/mojo/services/mojo_renderer_service.cc ('k') | media/renderers/audio_renderer_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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
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
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_
OLDNEW
« no previous file with comments | « media/mojo/services/mojo_renderer_service.cc ('k') | media/renderers/audio_renderer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698