Closed amithilbuch closed 5 years ago
To my mind, there is no particular advantage in signalling the resolution, bitrate or framerate on a send rid. Those are parameters that the sender can decide unilaterally. It makes sense to be able to signal those parameters on a recv rid, because it indicates what the receiver is capable of receiving on those rids. The parameters in send_encodings control what the sender is going to send, and can change (using setParameters) over the course of a call, without any new negotiation. So the fact that some of them match RID syntax should not drive the design of what to signal.
@alvestrand Agree that there is no advantage in signaling (any) restrictions on a send rid. While I can see the value of allowing a receiver to indicate "preferred" stream characteristics, draft-ietf-mmusic-rid describes a more traditional Offer/Answer framework. For example, with respect to signaling them in a receive rid, draft-ietf-mmusic-rid Section 6.3 says:
The answerer MAY choose to modify specific "a=rid" restriction
values in the answer SDP. In such a case, the modified value
MUST be more restrictive than the ones specified in the offer.
The answer MUST NOT include any restrictions that were not
present in the offer.
My interpretation is that if a conference server sends an offer with a recv rid and restrictions and the browser responds (even without modifying the restriction), this implies agreement by the Answerer to maintain the restriction. So for example, if the Offer with a recv rid contained max-br
or max-fps
restrictions and the browser responds without modifying the restrictions, has the browser agreed to set limits on what the sender can set maxBitrate
and maxFramerate
values to in the future?
With respect to current unsupported restrictions, or future potential restrictions, Section 6.2.2 of draft-ietf-mmusic-rid does not allow unsupported restrictions to be ignored:
If the "direction" field is "recv", the answerer ensures that the
specified "a=rid" restrictions are supported. In the case of an
unsupported restriction, the "a=rid" line is discarded.
@juberti Were rid restrictions discussed during the development of JSEP?
Consensus from the January 22, 2019 virtual interim is that restrictions are not supported (see PR https://github.com/w3c/webrtc-pc/pull/2075 )
There is a mismatch between how clients set up streams and how they communicate the created state. This is relevant to the case of Unified Plan and RIDs and is highlighted in the case of simulcast.
A client sets up their streams with a call to
addTransceiver()
in which they provide 'RTPEncodingParameters' also known assend_encodings
. These encodings describe the layers. Some of the parameters insend_encodings
(such asmax_bitrate_bps
andmax_framerate
) match RID restrictions (such asmax-br
andmax-fr
). However some of the parameters do not match. Specifically the parameters that indicate the resolution of the layer, which are of utmost importance to the simulcast scenario do not match. In the RID description, they aremax-width
andmax-height
but in thesend_encodings
they arescale_resolution_down_by
. This makes communicating the setup during negotiation harder than it needs to be. This is even harder when the offer is coming from the SFU which does not necessarily know the resolution of the imaging device on the other end. In such a case, there could also be performance impact from choosing "bad" values.Some possible options to resolve (in no particular order):