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

Side by Side Diff: webrtc/modules/audio_coding/neteq/neteq_impl.cc

Issue 2349973002: Revert of AcmReceiver: Ask NetEq to delete all decoders at once instead of one by one (Closed)
Patch Set: Created 4 years, 3 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 | « webrtc/modules/audio_coding/neteq/neteq_impl.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after
284 if (ret == DecoderDatabase::kOK) { 284 if (ret == DecoderDatabase::kOK) {
285 return kOK; 285 return kOK;
286 } else if (ret == DecoderDatabase::kDecoderNotFound) { 286 } else if (ret == DecoderDatabase::kDecoderNotFound) {
287 error_code_ = kDecoderNotFound; 287 error_code_ = kDecoderNotFound;
288 } else { 288 } else {
289 error_code_ = kOtherError; 289 error_code_ = kOtherError;
290 } 290 }
291 return kFail; 291 return kFail;
292 } 292 }
293 293
294 void NetEqImpl::RemoveAllPayloadTypes() {
295 rtc::CritScope lock(&crit_sect_);
296 decoder_database_->RemoveAll();
297 }
298
299 bool NetEqImpl::SetMinimumDelay(int delay_ms) { 294 bool NetEqImpl::SetMinimumDelay(int delay_ms) {
300 rtc::CritScope lock(&crit_sect_); 295 rtc::CritScope lock(&crit_sect_);
301 if (delay_ms >= 0 && delay_ms < 10000) { 296 if (delay_ms >= 0 && delay_ms < 10000) {
302 assert(delay_manager_.get()); 297 assert(delay_manager_.get());
303 return delay_manager_->SetMinimumDelay(delay_ms); 298 return delay_manager_->SetMinimumDelay(delay_ms);
304 } 299 }
305 return false; 300 return false;
306 } 301 }
307 302
308 bool NetEqImpl::SetMaximumDelay(int delay_ms) { 303 bool NetEqImpl::SetMaximumDelay(int delay_ms) {
(...skipping 1792 matching lines...) Expand 10 before | Expand all | Expand 10 after
2101 } 2096 }
2102 } 2097 }
2103 2098
2104 void NetEqImpl::CreateDecisionLogic() { 2099 void NetEqImpl::CreateDecisionLogic() {
2105 decision_logic_.reset(DecisionLogic::Create( 2100 decision_logic_.reset(DecisionLogic::Create(
2106 fs_hz_, output_size_samples_, playout_mode_, decoder_database_.get(), 2101 fs_hz_, output_size_samples_, playout_mode_, decoder_database_.get(),
2107 *packet_buffer_.get(), delay_manager_.get(), buffer_level_filter_.get(), 2102 *packet_buffer_.get(), delay_manager_.get(), buffer_level_filter_.get(),
2108 tick_timer_.get())); 2103 tick_timer_.get()));
2109 } 2104 }
2110 } // namespace webrtc 2105 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/audio_coding/neteq/neteq_impl.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698