[Asterisk-code-review] rtp: Add REMB RTP property and set it on PJSIP video RTP. (asterisk[master])

Jenkins2 asteriskteam at digium.com
Wed Mar 21 10:38:32 CDT 2018


Jenkins2 has submitted this change and it was merged. ( https://gerrit.asterisk.org/8573 )

Change subject: rtp: Add REMB RTP property and set it on PJSIP video RTP.
......................................................................

rtp: Add REMB RTP property and set it on PJSIP video RTP.

This change adds a property to RTP instances to indicate that
REMB support is enabled and that sending/receiving should be
passed through.

This also enables it on video RTP instances in PJSIP if
WebRTC support is enabled.

Finally the goog-remb extension is added to the SDP using
the rtcp-fb attribute to indicate our support for it.

Details about REMB can be found on the draft document for it:
https://tools.ietf.org/html/draft-alvestrand-rmcat-remb-03

Change-Id: I1902dda1c0882bd1a0d71b2f120684b44b97e789
---
M include/asterisk/rtp_engine.h
M res/res_pjsip_sdp_rtp.c
2 files changed, 6 insertions(+), 0 deletions(-)

Approvals:
  George Joseph: Looks good to me, but someone else must approve
  Benjamin Keith Ford: Looks good to me, but someone else must approve
  Kevin Harwell: Looks good to me, approved
  Jenkins2: Approved for Submit



diff --git a/include/asterisk/rtp_engine.h b/include/asterisk/rtp_engine.h
index 3812cb1..4e32d6b 100644
--- a/include/asterisk/rtp_engine.h
+++ b/include/asterisk/rtp_engine.h
@@ -126,6 +126,8 @@
 	AST_RTP_PROPERTY_RETRANS_RECV,
 	/*! Enable packet retransmission for sent packets */
 	AST_RTP_PROPERTY_RETRANS_SEND,
+	/*! Enable REMB sending and receiving passthrough support */
+	AST_RTP_PROPERTY_REMB,
 
 	/*!
 	 * \brief Maximum number of RTP properties supported
diff --git a/res/res_pjsip_sdp_rtp.c b/res/res_pjsip_sdp_rtp.c
index 9f0cdd3..03d3765 100644
--- a/res/res_pjsip_sdp_rtp.c
+++ b/res/res_pjsip_sdp_rtp.c
@@ -222,6 +222,7 @@
 	} else if (session_media->type == AST_MEDIA_TYPE_VIDEO) {
 		ast_rtp_instance_set_prop(session_media->rtp, AST_RTP_PROPERTY_RETRANS_RECV, session->endpoint->media.webrtc);
 		ast_rtp_instance_set_prop(session_media->rtp, AST_RTP_PROPERTY_RETRANS_SEND, session->endpoint->media.webrtc);
+		ast_rtp_instance_set_prop(session_media->rtp, AST_RTP_PROPERTY_REMB, session->endpoint->media.webrtc);
 		if (session->endpoint->media.tos_video || session->endpoint->media.cos_video) {
 			ast_rtp_instance_set_qos(session_media->rtp, session->endpoint->media.tos_video,
 					session->endpoint->media.cos_video, "SIP RTP Video");
@@ -1092,6 +1093,9 @@
 	 */
 	attr = pjmedia_sdp_attr_create(pool, "rtcp-fb", pj_cstr(&stmp, "* ccm fir"));
 	pjmedia_sdp_attr_add(&media->attr_count, media->attr, attr);
+
+	attr = pjmedia_sdp_attr_create(pool, "rtcp-fb", pj_cstr(&stmp, "* goog-remb"));
+	pjmedia_sdp_attr_add(&media->attr_count, media->attr, attr);
 }
 
 /*! \brief Function which negotiates an incoming media stream */

-- 
To view, visit https://gerrit.asterisk.org/8573
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I1902dda1c0882bd1a0d71b2f120684b44b97e789
Gerrit-Change-Number: 8573
Gerrit-PatchSet: 3
Gerrit-Owner: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Benjamin Keith Ford <bford at digium.com>
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Jenkins2
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Kevin Harwell <kharwell at digium.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20180321/820dcc66/attachment.html>


More information about the asterisk-code-review mailing list