VideoStreamRenderer class

The renderer for a video stream

Constructors

VideoStreamRenderer(LocalVideoStream | RemoteVideoStream)

Create a Renderer for a local camera preview or remote video stream. Future APIs: getStats(): Promise; // Helpful in debugging; should be included onNextFrame((IFrame) -> void) // to allow app to fetch raw frames - to be implemented later captureFrame(timeoutMs: number, bufferName?: string): Promise; // This can come in later events/delegates are provided by IRendererEvents

VideoStreamRenderer(LocalVideoStream | RemoteVideoStream)

Create a Renderer for a local camera preview or remote video stream. Future APIs: getStats(): Promise; // Helpful in debugging; should be included onNextFrame((IFrame) -> void) // to allow app to fetch raw frames - to be implemented later captureFrame(timeoutMs: number, bufferName?: string): Promise; // This can come in later events/delegates are provided by IRendererEvents

VideoStreamRenderer(LocalVideoStream | RemoteVideoStreamCommon)

Create a Renderer for a local camera preview or remote video stream. Future APIs: getStats(): Promise; // Helpful in debugging; should be included onNextFrame((IFrame) -> void) // to allow app to fetch raw frames - to be implemented later captureFrame(timeoutMs: number, bufferName?: string): Promise; // This can come in later events/delegates are provided by IRendererEvents

Properties

size

This API has been deprecated. Do not use it.

  • To get the size of the local video stream, please use MediaStats Call feature API (MediaStats.stats.videoSendFrameWidthSent and MediaStats.stats.videoSendFrameHeightSent).
  • To get the size of a remote video stream, please use RemoteVideoStream.size API.

Methods

createView(CreateViewOptions)

Create the view for the video stream.

dispose()

Dispose of this Renderer

Constructor Details

VideoStreamRenderer(LocalVideoStream | RemoteVideoStream)

Note

This API is in Beta and provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

Create a Renderer for a local camera preview or remote video stream. Future APIs: getStats(): Promise; // Helpful in debugging; should be included onNextFrame((IFrame) -> void) // to allow app to fetch raw frames - to be implemented later captureFrame(timeoutMs: number, bufferName?: string): Promise; // This can come in later events/delegates are provided by IRendererEvents

new VideoStreamRenderer(videoStream: LocalVideoStream | RemoteVideoStream)

Parameters

videoStream

LocalVideoStream | RemoteVideoStream

The video stream to render

VideoStreamRenderer(LocalVideoStream | RemoteVideoStream)

Create a Renderer for a local camera preview or remote video stream. Future APIs: getStats(): Promise; // Helpful in debugging; should be included onNextFrame((IFrame) -> void) // to allow app to fetch raw frames - to be implemented later captureFrame(timeoutMs: number, bufferName?: string): Promise; // This can come in later events/delegates are provided by IRendererEvents

new VideoStreamRenderer(videoStream: LocalVideoStream | RemoteVideoStream)

Parameters

videoStream

LocalVideoStream | RemoteVideoStream

The video stream to render

VideoStreamRenderer(LocalVideoStream | RemoteVideoStreamCommon)

Note

This API is in Beta and provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

Create a Renderer for a local camera preview or remote video stream. Future APIs: getStats(): Promise; // Helpful in debugging; should be included onNextFrame((IFrame) -> void) // to allow app to fetch raw frames - to be implemented later captureFrame(timeoutMs: number, bufferName?: string): Promise; // This can come in later events/delegates are provided by IRendererEvents

new VideoStreamRenderer(videoStream: LocalVideoStream | RemoteVideoStreamCommon)

Parameters

videoStream

LocalVideoStream | RemoteVideoStreamCommon

The video stream to render

Property Details

size

Warning

This API is now deprecated.

This API has been deprecated. Do not use it.

  • To get the size of the local video stream, please use MediaStats Call feature API (MediaStats.stats.videoSendFrameWidthSent and MediaStats.stats.videoSendFrameHeightSent).
  • To get the size of a remote video stream, please use RemoteVideoStream.size API.
size: StreamSize

Property Value

Method Details

createView(CreateViewOptions)

Create the view for the video stream.

function createView(options?: CreateViewOptions): Promise<VideoStreamRendererView>

Parameters

options
CreateViewOptions

Renderer options.

Returns

dispose()

Dispose of this Renderer

function dispose()