|
Agora Java API Reference for Android
|
#include <AgoraMediaBase.h>
Public Member Functions | |
| virtual void | onFrame (const VideoFrame *frame)=0 |
| Occurs each time the player receives a video frame. More... | |
| virtual bool | isExternal () |
| virtual VIDEO_PIXEL_FORMAT | getVideoFormatPreference () |
| Sets the format of the raw video data output by the SDK. More... | |
The IVideoFrameObserver class.
|
pure virtual |
Occurs each time the player receives a video frame.
After registering the video frame observer, the callback occurs every time the player receives a video frame, reporting the detailed information of the video frame.
| frame | The video frame information. See VideoFrame. |
|
virtual |
Sets the format of the raw video data output by the SDK.
You need to register the callback when calling the registerVideoFrameObserver method. After you successfully register the video frame observer, the SDK triggers this callback each time it receives a video frame. You need to set your preferred video data in the return value of this callback.
getVideoFormatPreference, you need to adapt to I420Buffer or TextureBuffer when processing video data. The cases where the video frame type is fixed as I420Buffer include but are not limited to:VIDEO_PIXEL_FORMAT.
1.8.18