IVideoEncodedFrameObserver

Class used to receive encoded video frames.

onEncodedVideoFrameReceived

Reports that a remote encoded video frame has been received.

onEncodedVideoFrameReceived?(
    channelId: string,
    uid: number,
    imageBuffer: Uint8Array,
    length: number,
    videoEncodedFrameInfo: EncodedVideoFrameInfo
  ): void;

When you call setRemoteVideoSubscriptionOptions and set encodedFrameOnly to true, the SDK triggers this callback locally to report the received encoded video frame information.

Parameters

channelId
Channel name.
uid
Remote user ID.
imageBuffer
Video image buffer.
length
Length of the video image data.
videoEncodedFrameInfo
Encoded video frame information. See EncodedVideoFrameInfo.