The MediaTrackConstraints dictionary is used to describe a set of capabilities and the value or values each can take on. A constraints dictionary is passed into applyConstraints() to allow a script to establish a set of exact (required) values or ranges and/or preferred values or ranges of values for the track, and the most recently-requested set of custom constraints can be retrieved by calling getConstraints().

Documentation MediaTrackConstraints by Mozilla Contributors, licensed under CC-BY-SA 2.5.

See also:

Fields

@:optionaloptionalwidth:Null<EitherType<Int, ConstrainLongRange>>

@:optionaloptionalviewportWidth:Null<EitherType<Int, ConstrainLongRange>>

@:optionaloptionalviewportOffsetY:Null<EitherType<Int, ConstrainLongRange>>

@:optionaloptionalviewportOffsetX:Null<EitherType<Int, ConstrainLongRange>>

@:optionaloptionalviewportHeight:Null<EitherType<Int, ConstrainLongRange>>

@:optionaloptionalscrollWithPage:Null<Bool>

@:optionaloptionalnoiseSuppression:Null<EitherType<Bool, ConstrainBooleanParameters>>

@:optionaloptionalmediaSource:Null<String>

@:optionaloptionalheight:Null<EitherType<Int, ConstrainLongRange>>

@:optionaloptionalframeRate:Null<EitherType<Float, ConstrainDoubleRange>>

@:optionaloptionalfacingMode:Null<EitherType<String, EitherType<Array<String>, ConstrainDOMStringParameters>>>

@:optionaloptionalechoCancellation:Null<EitherType<Bool, ConstrainBooleanParameters>>

@:optionaloptionaldeviceId:Null<EitherType<String, EitherType<Array<String>, ConstrainDOMStringParameters>>>

@:optionaloptionalchannelCount:Null<EitherType<Int, ConstrainLongRange>>

@:optionaloptionalbrowserWindow:Null<Int>

@:optionaloptionalautoGainControl:Null<EitherType<Bool, ConstrainBooleanParameters>>

@:optionaloptionaladvanced:Null<Array<MediaTrackConstraintSet>>