The AgoraVideoFrame class, which defines the format of the external video source.
◆ FORMAT_NONE
final int io.agora.rtc2.video.AgoraVideoFrame.FORMAT_NONE = -1 |
|
static |
◆ FORMAT_TEXTURE_2D
final int io.agora.rtc2.video.AgoraVideoFrame.FORMAT_TEXTURE_2D = 10 |
|
static |
10: The video format is TEXTURE_2D.
◆ FORMAT_TEXTURE_OES
final int io.agora.rtc2.video.AgoraVideoFrame.FORMAT_TEXTURE_OES = 11 |
|
static |
11: The video format is TEXTURE_OES.
◆ FORMAT_I420
final int io.agora.rtc2.video.AgoraVideoFrame.FORMAT_I420 = 1 |
|
static |
1: The video format is I420.
◆ FORMAT_BGRA
final int io.agora.rtc2.video.AgoraVideoFrame.FORMAT_BGRA = 2 |
|
static |
2: The video format is BGRA.
◆ FORMAT_NV21
final int io.agora.rtc2.video.AgoraVideoFrame.FORMAT_NV21 = 3 |
|
static |
3: The video format is NV21.
◆ FORMAT_RGBA
final int io.agora.rtc2.video.AgoraVideoFrame.FORMAT_RGBA = 4 |
|
static |
4: The video format is RGBA.
◆ BUFFER_TYPE_NONE
final int io.agora.rtc2.video.AgoraVideoFrame.BUFFER_TYPE_NONE = -1 |
|
static |
◆ BUFFER_TYPE_BUFFER
final int io.agora.rtc2.video.AgoraVideoFrame.BUFFER_TYPE_BUFFER = 1 |
|
static |
1: The buffer type is buffer.
◆ BUFFER_TYPE_ARRAY
final int io.agora.rtc2.video.AgoraVideoFrame.BUFFER_TYPE_ARRAY = 2 |
|
static |
2: The buffer type is array.
◆ BUFFER_TYPE_TEXTURE
final int io.agora.rtc2.video.AgoraVideoFrame.BUFFER_TYPE_TEXTURE = 3 |
|
static |
3: The buffer type is texture.
◆ format
int io.agora.rtc2.video.AgoraVideoFrame.format |
Format of the incoming video frame, which must be specified as one of the following:
◆ timeStamp
long io.agora.rtc2.video.AgoraVideoFrame.timeStamp |
The timestamp (ms) of this frame.
- Note
- Ensure that you set the correct timestamp, or it may cause frame dropping.
◆ stride
int io.agora.rtc2.video.AgoraVideoFrame.stride |
The stride of this frame, which means the number of pixels between two consecutive rows.
- Note
- Set this member is in pixel, not byte.
- If the video format is texture, set this member as the texture width.
◆ height
int io.agora.rtc2.video.AgoraVideoFrame.height |
The height of this frame.
◆ textureID
int io.agora.rtc2.video.AgoraVideoFrame.textureID |
The ID of the texture.
- Note
- Applies to Android texture only.
◆ syncMode
boolean io.agora.rtc2.video.AgoraVideoFrame.syncMode |
Determines whether to enable the sync mode, which means that the SDK waits while the texture is being processed.
- Note
- Applies to Android texture only.
◆ transform
float [] io.agora.rtc2.video.AgoraVideoFrame.transform |
The extra transform for the texture.
- Note
- Applies to Android texture only.
◆ eglContext11
javax.microedition.khronos.egl.EGLContext io.agora.rtc2.video.AgoraVideoFrame.eglContext11 |
EGLContext11.
- Note
- Applies to Android texture only.
◆ eglContext14
android.opengl.EGLContext io.agora.rtc2.video.AgoraVideoFrame.eglContext14 |
EGLContext14.
- Note
- Applies to Android texture only.
◆ buf
byte [] io.agora.rtc2.video.AgoraVideoFrame.buf |
The buffer of this frame.
- Note
- Applies to non-texture frames.
◆ cropLeft
int io.agora.rtc2.video.AgoraVideoFrame.cropLeft |
The number of pixels to crop from the left. Typically, set it as 0.
- Note
- Applies to non-texture frames.
◆ cropTop
int io.agora.rtc2.video.AgoraVideoFrame.cropTop |
The number of pixels to crop from the top. Typically, set it as 0.
- Note
- Applies to non-texture frames.
◆ cropRight
int io.agora.rtc2.video.AgoraVideoFrame.cropRight |
The number of pixels to crop from the right. Typically, set it as the value of (stride - width).
- Note
- Applies to non-texture frames.
◆ cropBottom
int io.agora.rtc2.video.AgoraVideoFrame.cropBottom |
The number of pixels to crop from the bottom. Typically, set it as 0.
- Note
- Applies to non-texture frames.
◆ rotation
int io.agora.rtc2.video.AgoraVideoFrame.rotation |
The rotation information (clockwise) of this frame. Set it as 0, 90, 180, or 270.