VideoEffectsFeature interface

API interface for the VideoEffects feature

Extends

Properties

activeEffects

List of current active effects

Inherited Properties

name

The feature name.

Methods

isSupported(VideoEffectProcessor)

Method to check if an effect is supported in the current environment.

off("effectsError", VideoEffectsFeatureErrorListener)

Unsubscribe functions - effectsError

off("effectsStarted", VideoEffectsFeatureListener)

Unsubscribe functions - effectsStarted

off("effectsStopped", VideoEffectsFeatureListener)

Unsubscribe functions - effectsStopped

off("fpsWarningThresholdReached", VideoEffectsFeatureListener)

Unsubscribe functions - fpsWarningThresholdReached

off("timeForEffectsWarningReached", VideoEffectsFeatureListener)

Unsubscribe functions - timeForEffectsWarningReached

on("effectsError", VideoEffectsFeatureErrorListener)

Subscribe functions - fires on error while using effects

on("effectsStarted", VideoEffectsFeatureListener)

Subscribe functions - fires when effects are started

on("effectsStopped", VideoEffectsFeatureListener)

Subscribe functions - fires when effects are stopped

on("fpsWarningThresholdReached", VideoEffectsFeatureListener)

Subscribe functions - fires when the stream fps is equal to/less than 'fpsWarningThreshold' value

on("timeForEffectsWarningReached", VideoEffectsFeatureListener)

Subscribe functions - fires when the time taken to start effects is more than the 'effectInitTimeThresholdInMs' value

startEffects(VideoEffectProcessor)

Start effects

stopEffects()

Stop effects

Inherited Methods

dispose()

Property Details

activeEffects

List of current active effects

activeEffects: VideoEffectName[]

Property Value

Inherited Property Details

name

The feature name.

name: string

Property Value

string

Inherited From BaseFeature.name

Method Details

isSupported(VideoEffectProcessor)

Method to check if an effect is supported in the current environment.

function isSupported(effect: VideoEffectProcessor): Promise<boolean>

Parameters

effect
VideoEffectProcessor

Instance of the effect to check support of.

Returns

Promise<boolean>

true if effect is supported in the current environment.

off("effectsError", VideoEffectsFeatureErrorListener)

Unsubscribe functions - effectsError

function off(event: "effectsError", listener: VideoEffectsFeatureErrorListener)

Parameters

event

"effectsError"

Event of type VideoEffectsFeatureEvent

listener
VideoEffectsFeatureErrorListener

A listener callback

off("effectsStarted", VideoEffectsFeatureListener)

Unsubscribe functions - effectsStarted

function off(event: "effectsStarted", listener: VideoEffectsFeatureListener)

Parameters

event

"effectsStarted"

Event of type VideoEffectsFeatureEvent

listener
VideoEffectsFeatureListener

A listener callback

off("effectsStopped", VideoEffectsFeatureListener)

Unsubscribe functions - effectsStopped

function off(event: "effectsStopped", listener: VideoEffectsFeatureListener)

Parameters

event

"effectsStopped"

Event of type VideoEffectsFeatureEvent

listener
VideoEffectsFeatureListener

A listener callback

off("fpsWarningThresholdReached", VideoEffectsFeatureListener)

Unsubscribe functions - fpsWarningThresholdReached

function off(event: "fpsWarningThresholdReached", listener: VideoEffectsFeatureListener)

Parameters

event

"fpsWarningThresholdReached"

Event of type VideoEffectsFeatureEvent

listener
VideoEffectsFeatureListener

A listener callback

off("timeForEffectsWarningReached", VideoEffectsFeatureListener)

Unsubscribe functions - timeForEffectsWarningReached

function off(event: "timeForEffectsWarningReached", listener: VideoEffectsFeatureListener)

Parameters

event

"timeForEffectsWarningReached"

Event of type VideoEffectsFeatureEvent

listener
VideoEffectsFeatureListener

A listener callback

on("effectsError", VideoEffectsFeatureErrorListener)

Subscribe functions - fires on error while using effects

function on(event: "effectsError", listener: VideoEffectsFeatureErrorListener)

Parameters

event

"effectsError"

Event of type VideoEffectsFeatureEvent

listener
VideoEffectsFeatureErrorListener

A listener callback

on("effectsStarted", VideoEffectsFeatureListener)

Subscribe functions - fires when effects are started

function on(event: "effectsStarted", listener: VideoEffectsFeatureListener)

Parameters

event

"effectsStarted"

Event of type VideoEffectsFeatureEvent

listener
VideoEffectsFeatureListener

A listener callback

on("effectsStopped", VideoEffectsFeatureListener)

Subscribe functions - fires when effects are stopped

function on(event: "effectsStopped", listener: VideoEffectsFeatureListener)

Parameters

event

"effectsStopped"

Event of type VideoEffectsFeatureEvent

listener
VideoEffectsFeatureListener

A listener callback

on("fpsWarningThresholdReached", VideoEffectsFeatureListener)

Subscribe functions - fires when the stream fps is equal to/less than 'fpsWarningThreshold' value

function on(event: "fpsWarningThresholdReached", listener: VideoEffectsFeatureListener)

Parameters

event

"fpsWarningThresholdReached"

Event of type VideoEffectsFeatureEvent

listener
VideoEffectsFeatureListener

A listener callback

on("timeForEffectsWarningReached", VideoEffectsFeatureListener)

Subscribe functions - fires when the time taken to start effects is more than the 'effectInitTimeThresholdInMs' value

function on(event: "timeForEffectsWarningReached", listener: VideoEffectsFeatureListener)

Parameters

event

"timeForEffectsWarningReached"

Event of type VideoEffectsFeatureEvent

listener
VideoEffectsFeatureListener

A listener callback

startEffects(VideoEffectProcessor)

Start effects

function startEffects(effect: VideoEffectProcessor): Promise<void>

Parameters

effect
VideoEffectProcessor

Instance of the effect

Returns

Promise<void>

stopEffects()

Stop effects

function stopEffects(): Promise<void>

Returns

Promise<void>

Inherited Method Details

dispose()

function dispose()

Inherited From Disposable.dispose