- From: Adam Bergkvist <adam.bergkvist@ericsson.com>
- Date: Fri, 13 Sep 2013 07:33:06 +0200
- To: Martin Thomson <martin.thomson@gmail.com>
- CC: Stefan HÃ¥kansson LK <stefan.lk.hakansson@ericsson.com>, Dominique Hazael-Massieux <dom@w3.org>, "public-media-capture@w3.org" <public-media-capture@w3.org>
On 2013-09-12 17:45, Martin Thomson wrote: > On 11 September 2013 22:26, Adam Bergkvist <adam.bergkvist@ericsson.com> wrote: >> I think it would be easier to send a clone of the MediaStream object (with >> postMessage()) and let the original window remain the owner, instead of >> transferring ownership. > > Yeah, I think that's very confusing. You can only > send^H^H^H^Htransfer Transferable objects with postMessage, so how > would this work? > In addition to transferring objects with postMessage()'s third argument, you can send certain objects (File, FileList, Blob, ...) as the first "message" argument (of type any) [1]. Objects sent that way are cloned, not transferred, and are still usable on the sending side after being sent. This way, we don't have to define what a neutered MediaStream is and "ownership" will always be kept by the page that has done getUserMedia() or contains the PeerConnection instance that feeds a remote stream. /Adam [1] http://dev.w3.org/html5/postmsg/#posting-messages
Received on Friday, 13 September 2013 05:33:32 UTC