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

Unified Diff: webrtc/video/rtp_stream_receiver.cc

Issue 2523843002: Send audio and video codecs to RTPPayloadRegistry (Closed)
Patch Set: Change strcpy to strncpy 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/modules/rtp_rtcp/test/testAPI/test_api_video.cc ('k') | webrtc/voice_engine/channel.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/video/rtp_stream_receiver.cc
diff --git a/webrtc/video/rtp_stream_receiver.cc b/webrtc/video/rtp_stream_receiver.cc
index fc8400761086e4851cfdcda9981f23d0ab46f5ec..f02cf3fa30e15fd101e32eca05f10488c2770a3c 100644
--- a/webrtc/video/rtp_stream_receiver.cc
+++ b/webrtc/video/rtp_stream_receiver.cc
@@ -226,15 +226,12 @@ RtpStreamReceiver::~RtpStreamReceiver() {
bool RtpStreamReceiver::SetReceiveCodec(const VideoCodec& video_codec) {
int8_t old_pltype = -1;
- if (rtp_payload_registry_.ReceivePayloadType(
- video_codec.plName, kVideoPayloadTypeFrequency, 0,
- video_codec.maxBitrate, &old_pltype) != -1) {
+ if (rtp_payload_registry_.ReceivePayloadType(video_codec, &old_pltype) !=
+ -1) {
rtp_payload_registry_.DeRegisterReceivePayload(old_pltype);
}
- return rtp_receiver_->RegisterReceivePayload(
- video_codec.plName, video_codec.plType, kVideoPayloadTypeFrequency,
- 0, 0) == 0;
+ return rtp_payload_registry_.RegisterReceivePayload(video_codec) == 0;
}
uint32_t RtpStreamReceiver::GetRemoteSsrc() const {
« no previous file with comments | « webrtc/modules/rtp_rtcp/test/testAPI/test_api_video.cc ('k') | webrtc/voice_engine/channel.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698