mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-29 13:11:06 +00:00
webrtc: add check for negotiation on transceiver direction changes
As required by the webrtc specification. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5045>
This commit is contained in:
parent
639f8a24ae
commit
13f4066580
1 changed files with 11 additions and 0 deletions
|
@ -2434,6 +2434,15 @@ gst_webrtc_bin_attach_tos (GstWebRTCBin * webrtc)
|
|||
gst_webrtc_bin_update_sctp_priority (webrtc);
|
||||
}
|
||||
|
||||
static void
|
||||
on_transceiver_notify_direction (GstWebRTCRTPTransceiver * transceiver,
|
||||
GParamSpec * pspec, GstWebRTCBin * webrtc)
|
||||
{
|
||||
PC_LOCK (webrtc);
|
||||
_update_need_negotiation (webrtc);
|
||||
PC_UNLOCK (webrtc);
|
||||
}
|
||||
|
||||
static WebRTCTransceiver *
|
||||
_create_webrtc_transceiver (GstWebRTCBin * webrtc,
|
||||
GstWebRTCRTPTransceiverDirection direction, guint mline, GstWebRTCKind kind,
|
||||
|
@ -2463,6 +2472,8 @@ _create_webrtc_transceiver (GstWebRTCBin * webrtc,
|
|||
|
||||
g_signal_connect_object (sender, "notify::priority",
|
||||
G_CALLBACK (gst_webrtc_bin_attach_tos), webrtc, G_CONNECT_SWAPPED);
|
||||
g_signal_connect_object (trans, "notify::direction",
|
||||
G_CALLBACK (on_transceiver_notify_direction), webrtc, G_CONNECT_DEFAULT);
|
||||
|
||||
g_ptr_array_add (webrtc->priv->transceivers, trans);
|
||||
|
||||
|
|
Loading…
Reference in a new issue