Add clock to ACM config struct
The purpose is to clean up the ACM interface a bit. This is a
follow-up of a comment in http://review.webrtc.org/13379004/.
R=turaj@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/16389005
git-svn-id: http://webrtc.googlecode.com/svn/trunk@6006 4adac7df-926f-26a2-2b94-8c16560cd09d
diff --git a/webrtc/modules/audio_coding/main/acm2/acm_receiver.cc b/webrtc/modules/audio_coding/main/acm2/acm_receiver.cc
index 8b1c5dc..5e51ba8 100644
--- a/webrtc/modules/audio_coding/main/acm2/acm_receiver.cc
+++ b/webrtc/modules/audio_coding/main/acm2/acm_receiver.cc
@@ -117,7 +117,7 @@
} // namespace
-AcmReceiver::AcmReceiver(const AudioCodingModule::Config& config, Clock* clock)
+AcmReceiver::AcmReceiver(const AudioCodingModule::Config& config)
: id_(config.id),
neteq_(NetEq::Create(config.neteq_config)),
last_audio_decoder_(-1), // Invalid value.
@@ -128,11 +128,12 @@
current_sample_rate_hz_(config.neteq_config.sample_rate_hz),
nack_(),
nack_enabled_(false),
- clock_(clock),
+ clock_(config.clock),
av_sync_(false),
initial_delay_manager_(),
missing_packets_sync_stream_(),
late_packets_sync_stream_() {
+ assert(clock_);
for (int n = 0; n < ACMCodecDB::kMaxNumCodecs; ++n) {
decoders_[n].registered = false;
}