webrtcbin: Enforce m-line restrictions when creating offer
authorOlivier Crête <olivier.crete@collabora.com>
Fri, 26 Mar 2021 22:15:50 +0000 (18:15 -0400)
committerOlivier Crête <olivier.crete@collabora.com>
Mon, 12 Apr 2021 21:55:07 +0000 (17:55 -0400)
commit08dd305a205060ed50182f9c903d493d559633eb
tree931bc5e5bd073d9126ccc7784251a43de267e800
parented1f0f33a236a3cc83f522b628d259b14d05cc9c
webrtcbin: Enforce m-line restrictions when creating offer

First fail the offer creation if the mid of an existing offer doesn't
match a forced m-mline.

Then, for all newly added mlines, first look for a transceiver that
forces this m-line, then add a "floating" one, then the data channel.
And repeat this until we're out of transceivers.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/-/merge_requests/2104>
ext/webrtc/gstwebrtcbin.c
ext/webrtc/utils.h