Manage RTP and RTCP transports

Looking through recent discussions on handling RTP and RTCP when they are on separate transports, I like the approach in the RTCIceTransportController, where the UA is expected to keep track of the pairing of RTP and RTCP transports internally, and adding an RCTP transport explicitly to the controller will throw exception.
 
A couple thoughts based on that.
 
Do we need the rtcpTransport on the RTCRtpSender and the RTCRtpReceiver explicitly?  If we can track the pairing of RTP and RTCP internally, the interface can be a bit cleaner.

To go one step further, is it possible to keep the RTCP transports as internal to UA?  For example, I wonder if it makes sense to have RTCIceTransport.createAssociatedTransport() just return void and keep the new RTCP RTCIceTransport internal and indicate that with a simple readonly attribute (e.g. boolean associatedTransportCreated, or something like that).  We can add a new attribute for the RTCP transport state or redefine the existing "state" attribute as a combined state.  A similar approach can be applied to the RTCDtlsTransport if this is along the right direction.

Thanks, Shijun 

Received on Saturday, 31 May 2014 14:24:17 UTC