Home Reference Source
import {ManagedStream} from '@quobis/sippojs'
public class | source

ManagedStream

This class provides access to media control functions during a call This class must never be directly instantiated

Method Summary

Public Methods
public

Creates a StreamRecorder object that will allow recording the stream

public

Provides access to the audio tracks of the managed stream

public

Provides access to the video tracks that are not a screen of the managed stream

public

The id of this stream

public

Provides access to the underlying WebRTC MediaStream object

public

Provides access to the screen tracks of the managed stream

public

Provides access to all the tracks of the managed stream

public

Provides access to the video tracks of the managed stream

public

Allows to know if the managed stream has audio tracks

public

Allows to know if the managed stream has camera tracks

public

Allows to know if the managed stream has screen tracks

public

Allows to know if the managed stream has video tracks

public

Indicates if every audio track is muted

public

Indicates if this managed stream is local.

public

Indicates if this managed stream is remote.

public

Indicates if every screen track is muted

public

Indicates if every video track is muted

public

Mutes or unmutes audio tracks of this stream

public

Mutes or unmutes screen tracks of this stream

public

Mutes or unmutes video tracks of this stream

public

Stops every track of the underlying MediaStream

public

Allows taking captures of the video tracks of this stream

Public Methods

public createStreamRecorder(): StreamRecorder source

Creates a StreamRecorder object that will allow recording the stream

Return:

StreamRecorder

public getAudioTracks(): MediaStreamTrack[] source

Provides access to the audio tracks of the managed stream

Return:

MediaStreamTrack[]

public getCameraTracks(): MediaStreamTrack[] source

Provides access to the video tracks that are not a screen of the managed stream

Return:

MediaStreamTrack[]

public getId(): boolean source

The id of this stream

Return:

boolean

public getMediaStream(): MediaStream source

Provides access to the underlying WebRTC MediaStream object

Return:

MediaStream

public getScreenTracks(): MediaStreamTrack[] source

Provides access to the screen tracks of the managed stream

Return:

MediaStreamTrack[]

public getTracks(): MediaStreamTrack[] source

Provides access to all the tracks of the managed stream

Return:

MediaStreamTrack[]

public getVideoTracks(): MediaStreamTrack[] source

Provides access to the video tracks of the managed stream

Return:

MediaStreamTrack[]

public hasAudioTracks(): boolean source

Allows to know if the managed stream has audio tracks

Return:

boolean

A boolean value indicating if the managed stream has at least one audio track

public hasCameraTracks(): boolean source

Allows to know if the managed stream has camera tracks

Return:

boolean

A boolean value indicating if the managed stream has at least one camera track

public hasScreenTracks(): boolean source

Allows to know if the managed stream has screen tracks

Return:

boolean

A boolean value indicating if the managed stream has at least one screen track

public hasVideoTracks(): boolean source

Allows to know if the managed stream has video tracks

Return:

boolean

A boolean value indicating if the managed stream has at least one video track

public isAudioMuted(): boolean source

Indicates if every audio track is muted

Return:

boolean

public isLocal(): boolean source

Indicates if this managed stream is local. This means that its sources are local devices of this machine and that it was obtained of a getUserMedia call and not from a RTCPeerConnection

Return:

boolean

public isRemote(): boolean source

Indicates if this managed stream is remote. This means that its sources are not local devices of this machine and that it was obtained from a RTCPeerConnection and not from a getUserMedia call

Return:

boolean

public isScreenMuted(): boolean source

Indicates if every screen track is muted

Return:

boolean

public isVideoMuted(): boolean source

Indicates if every video track is muted

Return:

boolean

public muteAudio(mute: boolean) source

Mutes or unmutes audio tracks of this stream

Params:

NameTypeAttributeDescription
mute boolean
  • optional

If true disables audio tracks, if false enables them If not argument is provided it toggles the mute state on audio tracks

public muteScreen(mute: boolean) source

Mutes or unmutes screen tracks of this stream

Params:

NameTypeAttributeDescription
mute boolean
  • optional

If true disables screen tracks, if false enables them If not argument is provided it toggles the mute state on screen tracks

public muteVideo(mute: boolean) source

Mutes or unmutes video tracks of this stream

Params:

NameTypeAttributeDescription
mute boolean
  • optional

If true disables video tracks, if false enables them If not argument is provided it toggles the mute state on video tracks

public stop(): ManagedStream source

Stops every track of the underlying MediaStream

Return:

ManagedStream

public takePhotos(): Promise<Blob[]> source

Allows taking captures of the video tracks of this stream

Return:

Promise<Blob[]>

A promise containing an array of Blobs with a capture of the video. One Blob for each video track of this stream