Media.Track
Media stream tracks.
module State : sig ... end
Track state enumeration.
module Kind : sig ... end
Track kind enumeration.
module Prop : sig ... end
Track properties
The type for MediaStreamTrack
objects.
val as_target : t -> Brr.Ev.target
as_target t
is t
as an event target.
id t
is the unique identifier of t
.
val isolated : t -> bool
isolated t
is the isolation status of t
.
val muted : t -> bool
muted t
is true
if t
is muted. Use set_enabled
to manually mute and unmute a track. Use events Ev.mute
and Ev.unmute
to monitor mute status.
val enabled : t -> bool
enabled t
is true
if the track is allowed to render the source and false
if it's not. Use set_enabled
to control this.
val set_enabled : t -> bool -> unit
set_enabled t b
sets the track enabled
status to b
. If the track has been disconnected this has no effect.
val get_capabilities : t -> Capabilities.t
get_capabilities t
are the capabilities of t
.
val get_constraints : t -> Constraints.t
get_constraints t
are the constraints of t
.
val apply_constraints : t -> Constraints.t option -> unit Fut.or_error
apply_contraints t
applies the applies the given contraints. Constraints unspecified are restored to their default value. If no contraints are given all contraints are restored to their defaults.
val get_settings : t -> Settings.t
get_settings t
are the settings of t
.
module Ev : sig ... end
Track events.