Re: webidl types left to be inferred around constraints

On 8/25/14 6:44 AM, Harald Alvestrand wrote:
>>
>>      staticDictionary getSupportedConstraints  (DOMString  kind);
>
> I like the idea of returning a MediaTrackConstraintSet.
>
>> Capabilities and Settings are not defined in this use ofthe 
>> Constrainable pattern. To implement this, we'd need something like:
>>
>>    dictionary MediaTrackSettingSet {
>>        long            width;
>>        long            height;
>>        double          aspectRatio;
>>        double          frameRate;
>>        VideoFacingMode facingMode;
>>        double          volume;
>>        long            sampleRate;
>>        long            sampleSize;
>>        boolean         echoCancelation;
>>        DOMString       sourceId;
>>        DOMString       groupId;
>>        //basically a bare-value rehash of MediaTrackConstraintSet
>>    };
>>
>>    interfaceMediaStreamTrack  :EventTarget  {
>>        ...
>>        MediaTrackConstraintSet  getCapabilities ();
>>        MediaTrackConstraints   getConstraints ();
>>        MediaTrackSettingSet     getSettings ();
>>
>> or simply:
>>    interfaceMediaStreamTrack  :EventTarget  {
>>        ...
>>        MediaTrackConstraintSet  getCapabilities ();
>>        MediaTrackConstraints   getConstraints ();
>>        MediaTrackConstraintSet  getSettings ();
>>
>> since UAs can return bare values in MediaTrackConstraintSet just fine!
>
> I thought bare values was what we had decided on for Settings. I guess 
> we didn't capture itin text.

Since we're on a roll, why not reuse MediaTrackConstraintSet here as 
well? The sole user is the UA, which would never return anything but 
bare values.

> Does ConstrainBoolean make sense? Would we ever want to say 
> "echoCancelation: {exact: false}"?

Yes, (sadly) we need that now. Good catch.

.: Jan-Ivar :.

Received on Monday, 25 August 2014 20:07:19 UTC