W3C home > Mailing lists > Public > public-media-capture@w3.org > December 2012

Re: Proposal for device "enumeration"

From: Adam Bergkvist <adam.bergkvist@ericsson.com>
Date: Fri, 7 Dec 2012 06:51:05 +0100
Message-ID: <50C183C9.4090302@ericsson.com>
To: Martin Thomson <martin.thomson@gmail.com>
CC: "public-media-capture@w3.org" <public-media-capture@w3.org>
On 2012-12-06 18:57, Martin Thomson wrote:
> As discussed on the call, and as no doubt Travis is already typing up,
> here is what I think we need for device enumeration:
>
> VideoStreamSource and AudioStreamSource each have a static method
> (invoked on the constructor, not an instance) that produces a sequence
> of device identifiers.
>
>    typedef DOMString DeviceId;
>    partial interface VideoStreamSource {
>      static sequence<DeviceId> getDeviceIds();
>    }
>    partial interface AudioStreamSource {
>      static sequence<DeviceId> getDeviceIds();
>    }

Is the gain of enumerating the deviceIds that high that it's worth the 
finger printing surface?

Couldn't you solve the use case of requesting a specific specific camera 
(you have used before and know works) by only exposing the deviceId on 
that source and having a constraint to request that particular device 
again with getUserMedia()? The app could create and persist something 
similar to getDeviceIds() (above) itself, but only with ids of devices 
it has been granted access to. The latter could be a rule for the native 
  getDeviceIds() functions as well, but it complicates things a bit.

/Adam
Received on Friday, 7 December 2012 05:52:13 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 16:26:13 UTC