Type alias VideoConstraints

VideoConstraints: MediaTrackConstraints | undefined | ((capabilities) => MediaTrackConstraints | undefined | Promise<MediaTrackConstraints | undefined>)

Media track constraints specific to video tracks.

Can be a MediaTrackConstraints object or a function that returns MediaTrackConstraints. The function is provided with an argument, MediaTrackCapabilities, which reprensents the media track capabilities, and should return either MediaTrackConstraints or a promise that resolves to it.

Unlike MediaTrackSupportedConstraints, MediaTrackCapabilities provides the accurate information of the track capabilities supported by your device.

Type declaration

    • (capabilities): MediaTrackConstraints | undefined | Promise<MediaTrackConstraints | undefined>
    • Parameters

      • capabilities: MediaTrackCapabilities

      Returns MediaTrackConstraints | undefined | Promise<MediaTrackConstraints | undefined>

Generated using TypeDoc