rtsp-server: Switch around sendonly/recvonly attributes

They are wrong in the ONVIF streaming spec. The backchannel should be
recvonly and the normal media should be sendonly: direction is always
from the point of view of the SDP offerer (the server) according to
RFC 3264.
This commit is contained in:
Sebastian Dröge 2018-01-22 12:46:34 +02:00
parent 72dc8acd86
commit 3d275b1345

View file

@ -135,12 +135,12 @@ gst_rtsp_onvif_media_setup_sdp (GstRTSPMedia * media, GstSDPMessage * sdp,
if (sinkpad) {
GstRTSPOnvifMedia *onvif_media = GST_RTSP_ONVIF_MEDIA (media);
gst_sdp_media_add_attribute (smedia, "sendonly", "");
gst_sdp_media_add_attribute (smedia, "recvonly", "");
if (onvif_media->priv->backchannel_bandwidth > 0)
gst_sdp_media_add_bandwidth (smedia, GST_SDP_BWTYPE_AS,
onvif_media->priv->backchannel_bandwidth);
} else {
gst_sdp_media_add_attribute (smedia, "recvonly", "");
gst_sdp_media_add_attribute (smedia, "sendonly", "");
}
}
}