Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

MediaStreamTrack

A single media track within a stream; typically, these are audio or video tracks, but other track types may exist as well.

interface MediaStreamTrack extends EventTarget {
contentHint: string;
enabled: boolean;
readonly id: string;
readonly kind: string;
readonly label: string;
readonly muted: boolean;
onended: ((this: MediaStreamTrack, ev: Event) => any) | null;
onmute: ((this: MediaStreamTrack, ev: Event) => any) | null;
onunmute: ((this: MediaStreamTrack, ev: Event) => any) | null;
readonly readyState: MediaStreamTrackState;
addEventListener<K extends keyof MediaStreamTrackEventMap>(
type: K,
listener: (this: MediaStreamTrack, ev: MediaStreamTrackEventMap[K]) => any,
options?: boolean | AddEventListenerOptions,
): void;
addEventListener(
type: string,
options?: boolean | AddEventListenerOptions,
): void;
applyConstraints(constraints?: MediaTrackConstraints): Promise<void>;
getCapabilities(): MediaTrackCapabilities;
getConstraints(): MediaTrackConstraints;
getSettings(): MediaTrackSettings;
removeEventListener<K extends keyof MediaStreamTrackEventMap>(
type: K,
listener: (this: MediaStreamTrack, ev: MediaStreamTrackEventMap[K]) => any,
options?: boolean | EventListenerOptions,
): void;
removeEventListener(
type: string,
options?: boolean | EventListenerOptions,
): void;
stop(): void;
}
var MediaStreamTrack: {
prototype: MediaStreamTrack;
}
;

§Extends

§Properties

§
contentHint: string
[src]
§
enabled: boolean
[src]
§
readonly id: string
[src]
§
readonly kind: string
[src]
§
readonly label: string
[src]
§
readonly muted: boolean
[src]
§
onended: ((this: MediaStreamTrack, ev: Event) => any) | null
[src]
§
onmute: ((this: MediaStreamTrack, ev: Event) => any) | null
[src]
§
onunmute: ((this: MediaStreamTrack, ev: Event) => any) | null
[src]
§
readonly readyState: MediaStreamTrackState
[src]

§Methods

§
addEventListener<K extends keyof MediaStreamTrackEventMap>(
type: K,
listener: (this: MediaStreamTrack, ev: MediaStreamTrackEventMap[K]) => any,
options?: boolean | AddEventListenerOptions,
): void
[src]
§
addEventListener(
type: string,
options?: boolean | AddEventListenerOptions,
): void
[src]
§
applyConstraints(constraints?: MediaTrackConstraints): Promise<void>
[src]
§
removeEventListener<K extends keyof MediaStreamTrackEventMap>(
type: K,
listener: (this: MediaStreamTrack, ev: MediaStreamTrackEventMap[K]) => any,
options?: boolean | EventListenerOptions,
): void
[src]
§
removeEventListener(
type: string,
options?: boolean | EventListenerOptions,
): void
[src]
§
stop(): void
[src]