Re: How to direct audio/vido streams from HTML5 media element to PeerConnection?

On 02/01/2013 05:14 PM, LiLi (Z) wrote:
> I agree with Travis and Adam that retrieving MediaStream from HTMLMediaElement is better.
> I also found something similar in MediaStream Processing API [1]:
>
> partial interface HTMLMediaElement {
>    readonly attribute MediaStream stream;
>   
>    MediaStream captureStream();
>    MediaStream captureStreamUntilEnded();
>    readonly attribute boolean audioCaptured;
>
>    attribute any src;
> };

That solves it....

>
> But I think this interface:
>
> partial interface HTMLMediaElement {
>    readonly attribute MediaStream stream;
> };
>
> should be included in this spec to make it complete, so a browser doesn't have to implement the entire MediaStream Processing API in order to support this feature.

I dislike attributes for this. They carry the implicit promise that you 
will get the same thing every time you query it; the captureStream() API 
doesn't carry that implication - captureStream() called twice would seem 
to return two streams.

>
> Thanks,
> Li
>
> [1] https://dvcs.w3.org/hg/audio/raw-file/tip/streams/StreamProcessing.html
>
>> -----Original Message-----
>> From: Dominique Hazael-Massieux [mailto:dom@w3.org]
>> Sent: Friday, February 01, 2013 4:24 AM
>> To: LiLi (Z)
>> Cc: Travis Leithead; public-media-capture@w3.org
>> Subject: Re: How to direct audio/vido streams from HTML5 media element
>> to PeerConnection?
>>
>> Le jeudi 31 janvier 2013 à 19:07 +0000, LiLi (Z) a écrit :
>>> I guess you meant to add an attribute to theHTMLMediaElement
>>> interface:
>>> interface HTMLMediaElement : HTMLElement {
>>>      …
>>>      readonly attribute MediaStream mediaStream;
>>> };
>>>
>>> Given that this part has reached CR, I’m not sure how easy it is to
>>> propose new changes.
>> If we wanted to follow that path, I think we could do it through an
>> "HTML Extension Specification" (or simply request it to be added in
>> HTML
>> 5.1).
>>
>> Dom
>>

Received on Saturday, 2 February 2013 10:54:34 UTC