W3C home > Mailing lists > Public > public-media-capture@w3.org > November 2014

Capabilities vs SupportedConstraints

From: Rob Manson <roBman@buildAR.com>
Date: Sat, 01 Nov 2014 12:12:09 +1100
Message-ID: <54543369.5070207@buildAR.com>
To: "public-media-capture@w3.org" <public-media-capture@w3.org>

this might be a stupid question...but what's the real difference between 
Capabilities and SupportedConstraints.

I can see that getSupportedConstraints() is attached at the MediaDevices 
level and getCapabilities() is attached at the MST level.

And I can see that the data structures returned are different because 
getSupportedConstraints(kind) returns a dictionary with only true 
values, while getCapabilities() returns a Constraints structure where 
the values are either ranges or enums. (e.g. getCapabilities returns 

It seems to me that under the hood Capabilities and SupportedConstraints 
are effectively the same concept.

I can see why there might be some fingerprinting/privacy issues if the 
method that hung off MediaDevices returned the full set of 
SupportedConstraints (e.g. before the stream permissions were granted, 
etc.). But calling these two things by completely different (but 
somewhat interchangeable) names seems a bit confusing.

I really like the conceptual clarity of the ConstrainablePattern model, 
but my mind is having trouble parsing this aspect of it.

Or have I misunderstood this in some way?

Received on Saturday, 1 November 2014 01:05:41 UTC

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