Public Member Functions | |
boolean | onCaptureVideoFrame (VideoFrame videoFrame) |
boolean | onRenderVideoFrame (int uid, RtcConnection connection, VideoFrame videoFrame) |
boolean io.agora.rtc2.video.IVideoFrameObserver.onCaptureVideoFrame | ( | VideoFrame | videoFrame | ) |
Occurs each time the SDK receives a video frame captured by the local camera.
After you successfully register the video frame observer, the SDK triggers this callback each time a video frame is received. In this callback, you can get the video data captured by the local camera. You can then pre-process the data according to your scenarios.
After pre-processing, you can send the processed video data back to the SDK by setting the videoFrame
parameter in this callback.
videoFrame | A pointer to the video frame. |
boolean io.agora.rtc2.video.IVideoFrameObserver.onRenderVideoFrame | ( | int | uid, |
RtcConnection | connection, | ||
VideoFrame | videoFrame | ||
) |
Occurs each time the SDK receives a video frame sent by the remote user.
After you successfully register the video frame observer, the SDK triggers this callback each time a video frame is received. In this callback, you can get the video data sent by the remote user. You can then post-process the data according to your scenarios.
After post-processing, you can send the processed data back to the SDK by setting the videoFrame
parameter in this callback.
uid | ID of the remote user who sends the current video frame. |
connection | ID of the connection. |
videoFrame | A pointer to the video frame. |