Agora Java API Reference for Android
Public Member Functions | Public Attributes | List of all members
io.agora.rtc2.video.EncodedVideoFrameInfo Class Reference

Information about externally encoded video frames. More...

Public Member Functions

 EncodedVideoFrameInfo (int codecType, int width, int height, int framesPerSecond, int frameType, int rotation, int trackId, long captureTimeMs, long decodeTimeMs, int streamType)
 
int getCodecType ()
 
int getWidth ()
 
int getHeight ()
 
int getFramesPerSecond ()
 
int getFrameType ()
 
int getRotation ()
 
int getTrackId ()
 
long getCaptureTimeMs ()
 
long getDecodeTimeMs ()
 
int getStreamType ()
 
String toString ()
 

Public Attributes

int codecType
 
int width
 
int height
 
int framesPerSecond
 
int frameType
 
int rotation
 
int trackId
 
long captureTimeMs
 
long decodeTimeMs
 
int streamType
 

Detailed Description

Information about externally encoded video frames.

Member Data Documentation

◆ codecType

int io.agora.rtc2.video.EncodedVideoFrameInfo.codecType

The codec type of the video:

  • VIDEO_CODEC_VP8 (1): VP8.
  • VIDEO_CODEC_H264 (2): H.264.
  • VIDEO_CODEC_H265 (3): (Default) H.265.
    Note
    In certain scenarios, such as low resolution of the captured video stream or limited device performance, the SDK automatically adjusts to the H.264 encoding format.

◆ width

int io.agora.rtc2.video.EncodedVideoFrameInfo.width

Width (pixel) of the video frame.

◆ height

int io.agora.rtc2.video.EncodedVideoFrameInfo.height

Height (pixel) of the video frame.

◆ framesPerSecond

int io.agora.rtc2.video.EncodedVideoFrameInfo.framesPerSecond

The number of video frames per second. When this parameter is not 0, you can use it to calculate the Unix timestamp of externally encoded video frames.

◆ frameType

int io.agora.rtc2.video.EncodedVideoFrameInfo.frameType

The video frame type.

  • 0: (Default) VIDEO_FRAME_TYPE_BLANK_FRAME, a blank frame.
  • 3: VIDEO_FRAME_TYPE_KEY_FRAME, a key frame.
  • 4: VIDEO_FRAME_TYPE_DELTA_FRAME, a Delta frame.
  • 5: VIDEO_FRAME_TYPE_B_FRAME, a B frame.
  • 6: VIDEO_FRAME_TYPE_UNKNOW, an unknown frame.

◆ rotation

int io.agora.rtc2.video.EncodedVideoFrameInfo.rotation

Rotation information of the video frame, as the following:

  • 0: (Default) 0 degree.
  • 90: 90 degrees.
  • 180: 180 degrees.
  • 270: 270 degrees.

◆ trackId

int io.agora.rtc2.video.EncodedVideoFrameInfo.trackId

Reserved for future use.

◆ captureTimeMs

long io.agora.rtc2.video.EncodedVideoFrameInfo.captureTimeMs

The Unix timestamp (ms) for capturing the external encoded video frames.

◆ decodeTimeMs

long io.agora.rtc2.video.EncodedVideoFrameInfo.decodeTimeMs

This is a output parameter which means timestamp for decoding the video frame.

◆ streamType

int io.agora.rtc2.video.EncodedVideoFrameInfo.streamType

The type of video streams.