Re: Bare constraint values - KISS

On 9 July 2014 11:02, Jan-Ivar Bruaroey <jib@mozilla.com> wrote:
> screensharing sources would leak into camera lists of existing users

I've been thinking more about this, and I think that perhaps we've
been over-thinking it.  I see two alternatives to Jan-Ivar's proposal,
both of which I think are strictly better.

I think that screwing with constraints further (ekr: feel free to say
"I told you so" now) isn't what we are looking for.  Rather than
contorting to accommodate every new feature, we should take a step
back and look at what the requirements are.

1.

I know that a call pattern like:

...getUserMedia({audio: false, video: false, application: true}, ...)

... might be uncomfortable or inconvenient for us to implement in
Firefox, but I think that it's actually how people think of this.  And
we already need to fix our code.  We can talk about having an
allowance for failure when the sources are disparate if you like.

Another reason that I'm starting to like this is that the basic set of
constraints we apply for camera sources are very different to those
that apply elsewhere.

Since the depth (or range) input folks are already headed in this
direction, I think that this makes even more sense.  This makes the
"audio" and "video" labels a little less good, but I think that we can
probably live with that.

2.

Tim T pointed out a consideration that might be relevant: screen
sharing can also include audio - and some applications actually
support that - but I think that we probably want to be a little
cautious about adding that.  Though that would favour a form that
globally switches mode, rather than something local to a video
constraints:

...getUserMedia({audio: false, video: true, source:
"application|livecapture"}, ...)


My preference tends slightly toward the second option.

Received on Wednesday, 9 July 2014 18:32:45 UTC