W3C home > Mailing lists > Public > public-webrtc@w3.org > November 2012

Re: [ACTION-59] Introduce lookup by id structures for streams and tracks.

From: Harald Alvestrand <harald@alvestrand.no>
Date: Tue, 06 Nov 2012 11:52:17 +0100
Message-ID: <5098EBE1.1040504@alvestrand.no>
To: Adam Bergkvist <adam.bergkvist@ericsson.com>
CC: Martin Thomson <martin.thomson@gmail.com>, "public-webrtc@w3.org" <public-webrtc@w3.org>
On 11/06/2012 11:14 AM, Adam Bergkvist wrote:
> On 2012-11-05 16:59, Martin Thomson wrote:
>> On 5 November 2012 14:12, Harald Alvestrand <harald@alvestrand.no> 
>> wrote:
>>> I like simplicity.
>>> I'd like to introduce three operators on a MediaStream:
>>>
>>> sequence<MediaStreamTrack> videoTracks()
>>> sequence<MediaStreamTrack> audioTracks()
>>> sequence<MediaStreamTrack> allTracks()
>>
>> That would be my preference.
>>
>> Add a "MediaStreamTrack? getTrackById(DOMString id)" and we're good.
>>
>
> There's more to it. We need to move the 
> add(MediaStreamTrack)/remove(...) functions and the event handler 
> attributes as well.
>
> I think the track lists should be attributes on MediaStream similar to 
> the track lists on the media elements; it's not possible with 
> sequences. A sequence is also about order which is the thing we want 
> to move away from.
>
> /Adam
Apologies for the earlier confusion; I was writing MediaStreamTrack 
where I should be writing MediaStreamTrackList. That's the level of 
hierarchy I don't see the need for any more; since a MediaStream holds a 
bag of MediaStreamTracks, there doesn't seem to need to be any separate 
lists any more - and with access operators, we can get the subset of 
tracks we need when we need them.

But given my inability to type straight, perhaps I'll see it later.

I'd like more people to think about this and offer opinions.
Received on Tuesday, 6 November 2012 10:52:49 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 6 November 2012 10:52:49 GMT