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

Side by Side Diff: webrtc/modules/audio_coding/main/acm2/audio_coding_module_impl.cc

Issue 1429943004: AcmReceiver::InsertPacket and NetEq::InsertPacket: Take ArrayView arguments (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Fix log message Created 5 years, 1 month 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
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 593 matching lines...) Expand 10 before | Expand all | Expand 10 after
604 // Get current received codec. 604 // Get current received codec.
605 int AudioCodingModuleImpl::ReceiveCodec(CodecInst* current_codec) const { 605 int AudioCodingModuleImpl::ReceiveCodec(CodecInst* current_codec) const {
606 CriticalSectionScoped lock(acm_crit_sect_.get()); 606 CriticalSectionScoped lock(acm_crit_sect_.get());
607 return receiver_.LastAudioCodec(current_codec); 607 return receiver_.LastAudioCodec(current_codec);
608 } 608 }
609 609
610 // Incoming packet from network parsed and ready for decode. 610 // Incoming packet from network parsed and ready for decode.
611 int AudioCodingModuleImpl::IncomingPacket(const uint8_t* incoming_payload, 611 int AudioCodingModuleImpl::IncomingPacket(const uint8_t* incoming_payload,
612 const size_t payload_length, 612 const size_t payload_length,
613 const WebRtcRTPHeader& rtp_header) { 613 const WebRtcRTPHeader& rtp_header) {
614 return receiver_.InsertPacket(rtp_header, incoming_payload, payload_length); 614 return receiver_.InsertPacket(
615 rtp_header,
616 rtc::ArrayView<const uint8_t>(incoming_payload, payload_length));
615 } 617 }
616 618
617 // Minimum playout delay (Used for lip-sync). 619 // Minimum playout delay (Used for lip-sync).
618 int AudioCodingModuleImpl::SetMinimumPlayoutDelay(int time_ms) { 620 int AudioCodingModuleImpl::SetMinimumPlayoutDelay(int time_ms) {
619 if ((time_ms < 0) || (time_ms > 10000)) { 621 if ((time_ms < 0) || (time_ms > 10000)) {
620 WEBRTC_TRACE(webrtc::kTraceError, webrtc::kTraceAudioCoding, id_, 622 WEBRTC_TRACE(webrtc::kTraceError, webrtc::kTraceAudioCoding, id_,
621 "Delay must be in the range of 0-1000 milliseconds."); 623 "Delay must be in the range of 0-1000 milliseconds.");
622 return -1; 624 return -1;
623 } 625 }
624 return receiver_.SetMinimumDelay(time_ms); 626 return receiver_.SetMinimumDelay(time_ms);
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
783 return receiver_.LeastRequiredDelayMs(); 785 return receiver_.LeastRequiredDelayMs();
784 } 786 }
785 787
786 void AudioCodingModuleImpl::GetDecodingCallStatistics( 788 void AudioCodingModuleImpl::GetDecodingCallStatistics(
787 AudioDecodingCallStats* call_stats) const { 789 AudioDecodingCallStats* call_stats) const {
788 receiver_.GetDecodingCallStatistics(call_stats); 790 receiver_.GetDecodingCallStatistics(call_stats);
789 } 791 }
790 792
791 } // namespace acm2 793 } // namespace acm2
792 } // namespace webrtc 794 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698