#include <IAgoraRtcEngine.h>
Public Member Functions | |
virtual bool | onInitialize ()=0 |
virtual bool | onStart ()=0 |
virtual void | onStop ()=0 |
virtual void | onDispose ()=0 |
virtual agora::media::ExternalVideoFrame::VIDEO_BUFFER_TYPE | getBufferType ()=0 |
virtual agora::media::ExternalVideoFrame::VIDEO_PIXEL_FORMAT | getPixelFormat ()=0 |
virtual void | onRenderPixelBuffer (CVPixelBufferRef pixelBuffer, int rotation)=0 |
virtual void | onRenderRawData (uint8_t *rawData, int width, int height, int rotation)=0 |
The IVideoSink class, which can set up a custom video renderer.
During a real-time audio and video interaction, the Agora SDK enables the default renderer to render local and remote video. The IVideoSink class can customize the video renderer. You can implement this interface first, and then customize the video renderer that you want by calling setLocalVideoRenderer or setRemoteVideoRenderer.
|
pure virtual |
Notification for initializing the custom video renderer.
The SDK triggers this callback to remind you to initialize the custom video renderer. After receiving this callback, you can do some preparation, and then use the return value to tell the SDK whether the custom video renderer is prepared. The SDK takes the corresponding behavior based on the return value.
|
pure virtual |
Notification for starting the custom video source.
The SDK triggers this callback to remind you to start the custom video source for capturing video. After receiving this callback, you can do some preparation, and then use the return value to tell the SDK whether the custom video renderer is started. The SDK takes the corresponding behavior based on the return value.
|
pure virtual |
Notification for stopping rendering the video.
The SDK triggers this callback to remind you to stop rendering the video. This callback informs you that the SDK is about to stop sending video data to the custom video renderer.
|
pure virtual |
Notification for disabling the custom video renderer.
The SDK triggers this callback to remind you to disable the custom video renderer.
|
pure virtual |
Gets the video frame type.
Before you initialize the custom video renderer, the SDK triggers this callback to query the data type of the video frame that you want to process. You must specify the data type of the video frame in the return value of this callback and then pass it to the SDK.
|
pure virtual |
Gets the video frame pixel format.
Before you initialize the custom video renderer, the SDK triggers this callback to query the pixel format of the video frame that you want to process. You must specify a pixel format for the video frame in the return value of this callback and then pass it to the SDK.
|
pure virtual |
Notification for rendering the video in the pixel data type.
The SDK triggers this callback after capturing video in the pixel data type to alter the custom video renderer to process the video data.
pixelBuffer | The video data in the pixel data type. |
rotation | The clockwise rotation angle of the video. |
|
pure virtual |
Notification for rendering the video in the raw data type.
The SDK triggers this callback after capturing video in the raw data type to alter the custom video renderer to process the video data.
rawData | The video data in the raw data type. |
width | The width (px) of the video. |
height | The height (px) of the video. |
rotation | The clockwise rotation angle of the video. |