MediaDevices class

The interface provides access to connected media input devices like cameras and microphones, as well as screen sharing. In essence, it lets you obtain access to any hardware source of media data.

EventTarget

MediaDevices

Implemented types
Available extensions
Annotations
  • @JS()
  • @staticInterop

Constructors

MediaDevices()
factory

Properties

hashCode int
The hash code for this object.
no setterinherited
oncaptureaction EventHandlerNonNull<Event>?

Available on MediaDevices, provided by the PropsMediaDevices extension

getter/setter pair
ondevicechange EventHandlerNonNull<Event>?

Available on MediaDevices, provided by the PropsMediaDevices extension

getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

addEventListener(String type, EventListener? callback, [dynamic options]) → void

Available on EventTarget, provided by the PropsEventTarget extension

dispatchEvent(Event event) bool

Available on EventTarget, provided by the PropsEventTarget extension

enumerateDevices() Future<Iterable<MediaDeviceInfo>>

Available on MediaDevices, provided by the PropsMediaDevices extension

getDisplayMedia([DisplayMediaStreamOptions? options]) Future<MediaStream>

Available on MediaDevices, provided by the PropsMediaDevices extension

getSupportedConstraints() MediaTrackSupportedConstraints

Available on MediaDevices, provided by the PropsMediaDevices extension

getUserMedia([MediaStreamConstraints? constraints]) Future<MediaStream>

Available on MediaDevices, provided by the PropsMediaDevices extension

getViewportMedia([ViewportMediaStreamConstraints? constraints]) Future<MediaStream>

Available on MediaDevices, provided by the PropsMediaDevices extension

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
removeEventListener(String type, EventListener? callback, [dynamic options]) → void

Available on EventTarget, provided by the PropsEventTarget extension

selectAudioOutput([AudioOutputOptions? options]) Future<MediaDeviceInfo>

Available on MediaDevices, provided by the PropsMediaDevices extension

setCaptureHandleConfig([CaptureHandleConfig? config]) → void

Available on MediaDevices, provided by the PropsMediaDevices extension

setSupportedCaptureActions(Iterable<String> actions) → void

Available on MediaDevices, provided by the PropsMediaDevices extension

toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited