MediaStreamTrack behaviuor

Hi,
I am a bit confused regarding the latest draft regarding how
MediaStreamTracks should behave when they are part of more than one
MediaStream.

It used to be that when a MediaStream was created with a list of Tracks one
created new tracks that had the same underlying data source as the input
tracks. Basically one cloned the tracks.

Now the draft says that the new MediaStream should add the same Tracks to
its lists. That means that the same Track can now belong to more than one
MediaStream. This has an unfortunate effect that if one disables a Track,
the Track gets disabled in all MediaStreams. It is no longer possible to
have independent enabled stated, and for example this basic use case is
impossible:

A LocalMediaStream is created by getUserMedia. The user creates a new
MediaStream with the video track from the LMS. The LMS is attached to a
video tag for self view, and the MS is added to a PeerConnection. The user
wants to implement a video mute function for outgoing video and therefore
disables the video track in the MS. This now disables the video track in
the LMS as well whereas before this was doing the right thing.

What is the reasoning behind this change?

/Tommy

-- 
Tommy Widenflycht, Senior Software Engineer
Google Sweden AB, Kungsbron 2, SE-11122 Stockholm, Sweden
Org. nr. 556656-6880
And yes, I have to include the above in every outgoing email according to
EU law.

Received on Wednesday, 4 July 2012 12:36:24 UTC