- From: Jan-Ivar Bruaroey <jib@mozilla.com>
- Date: Tue, 10 Dec 2013 10:10:36 -0500
- To: Martin Thomson <martin.thomson@gmail.com>, "public-media-capture@w3.org" <public-media-capture@w3.org>
On 12/9/13 12:03 PM, Martin Thomson wrote: > Regarding the use of dictionaries for constraints, specifically > mandatory constraints. Here's where I think that the status of the > debate is at: > > Jan-Ivar doesn't want to use something that looks like a dictionary, but isn't. > > Harald and Gili are certain that they want a particular behaviour. > > (I don't believe that we are completely agreed that mandatory is a > good idea, but let's pretend that it is.) > > I think that though the arguments are frequently misleading, both > groups are fundamentally right. They don't want strictly opposing > things. So let me propose a solution. > > var c = new ConstraintSet(); > c.set('width', 1280); > c.set('height', 720); > navigator.getUserMedia({ audio: true, video: { mandatory: c } }, > successCb, failureCb); > > Done. > > The idea that a dictionary is appropriate here is, at best, a stretch. > Don't look at every problem and assume that your hammer will work. A > dictionary is not appropriate for this use case, and pretending that > it is does no favours to anyone. Thank you Martin for pointing this out and moving the discussion forward! This takes the vaseline off the lens. Seeing the true colors of this construct is helpful. .: Jan-Ivar :. PS: About the positions you paraphrased, let me clarify again that I'm not limiting any behavior. We're arguing over default "unknowns for dummies" behavior. I happen to think mine is both webAPI friendly AND less harmful.
Received on Tuesday, 10 December 2013 15:11:07 UTC