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

Side by Side Diff: webrtc/video/rtp_stream_receiver.cc

Issue 2460533002: Simplify {,Set}UlpfecConfig interface. (Closed)
Patch Set: git cl format. Created 4 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
« no previous file with comments | « webrtc/modules/rtp_rtcp/source/rtp_sender_video.cc ('k') | webrtc/video/video_send_stream.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 /* 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 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 VideoCodec red_codec = {}; 171 VideoCodec red_codec = {};
172 red_codec.codecType = kVideoCodecRED; 172 red_codec.codecType = kVideoCodecRED;
173 strncpy(red_codec.plName, "red", sizeof(red_codec.plName)); 173 strncpy(red_codec.plName, "red", sizeof(red_codec.plName));
174 red_codec.plType = config_.rtp.ulpfec.red_payload_type; 174 red_codec.plType = config_.rtp.ulpfec.red_payload_type;
175 RTC_CHECK(SetReceiveCodec(red_codec)); 175 RTC_CHECK(SetReceiveCodec(red_codec));
176 if (config_.rtp.ulpfec.red_rtx_payload_type != -1) { 176 if (config_.rtp.ulpfec.red_rtx_payload_type != -1) {
177 rtp_payload_registry_.SetRtxPayloadType( 177 rtp_payload_registry_.SetRtxPayloadType(
178 config_.rtp.ulpfec.red_rtx_payload_type, 178 config_.rtp.ulpfec.red_rtx_payload_type,
179 config_.rtp.ulpfec.red_payload_type); 179 config_.rtp.ulpfec.red_payload_type);
180 } 180 }
181 181 // TODO(brandtr): It doesn't seem that |rtp_rtcp_| is used for sending any
182 rtp_rtcp_->SetUlpfecConfig(true, config_.rtp.ulpfec.red_payload_type, 182 // RTP packets. Investigate if this is the case, and if so, remove this
183 // call, since there are no RTP packets to protect with RED+ULPFEC.
184 rtp_rtcp_->SetUlpfecConfig(config_.rtp.ulpfec.red_payload_type,
183 config_.rtp.ulpfec.ulpfec_payload_type); 185 config_.rtp.ulpfec.ulpfec_payload_type);
184 } 186 }
185 187
186 if (config_.rtp.rtcp_xr.receiver_reference_time_report) 188 if (config_.rtp.rtcp_xr.receiver_reference_time_report)
187 rtp_rtcp_->SetRtcpXrRrtrStatus(true); 189 rtp_rtcp_->SetRtcpXrRrtrStatus(true);
188 190
189 // Stats callback for CNAME changes. 191 // Stats callback for CNAME changes.
190 rtp_rtcp_->RegisterRtcpStatisticsCallback(receive_stats_proxy); 192 rtp_rtcp_->RegisterRtcpStatisticsCallback(receive_stats_proxy);
191 193
192 process_thread_->RegisterModule(rtp_rtcp_.get()); 194 process_thread_->RegisterModule(rtp_rtcp_.get());
(...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after
536 const std::string& extension, int id) { 538 const std::string& extension, int id) {
537 // One-byte-extension local identifiers are in the range 1-14 inclusive. 539 // One-byte-extension local identifiers are in the range 1-14 inclusive.
538 RTC_DCHECK_GE(id, 1); 540 RTC_DCHECK_GE(id, 1);
539 RTC_DCHECK_LE(id, 14); 541 RTC_DCHECK_LE(id, 14);
540 RTC_DCHECK(RtpExtension::IsSupportedForVideo(extension)); 542 RTC_DCHECK(RtpExtension::IsSupportedForVideo(extension));
541 RTC_CHECK(rtp_header_parser_->RegisterRtpHeaderExtension( 543 RTC_CHECK(rtp_header_parser_->RegisterRtpHeaderExtension(
542 StringToRtpExtensionType(extension), id)); 544 StringToRtpExtensionType(extension), id));
543 } 545 }
544 546
545 } // namespace webrtc 547 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/rtp_rtcp/source/rtp_sender_video.cc ('k') | webrtc/video/video_send_stream.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698