Agora Java API Reference for Android
Classes | Public Member Functions | Public Attributes | Static Public Attributes | List of all members
io.agora.rte.media.video.AgoraRteVideoEncoderConfiguration Class Reference

Classes

enum  ORIENTATION_MODE
 
enum  VIDEO_MIRROR_MODE_TYPE
 
class  VideoDimensions
 

Public Member Functions

 AgoraRteVideoEncoderConfiguration (VideoDimensions dimensions, int frameRate, int bitrateInKbps, ORIENTATION_MODE orientationMode, VIDEO_MIRROR_MODE_TYPE mirrorModeType)
 
 AgoraRteVideoEncoderConfiguration (int width, int height, int frameRate, int bitrateInKbps, ORIENTATION_MODE orientationMode, VIDEO_MIRROR_MODE_TYPE mirrorModeType)
 
int getWidth ()
 
int getHeight ()
 
int getFramerate ()
 
int getBitrate ()
 
int getOrientationMode ()
 
int getMirrorModeType ()
 
String toString ()
 

Public Attributes

VideoDimensions dimensions
 
int frameRate
 
int bitrateInKbps
 
VIDEO_MIRROR_MODE_TYPE mirrorModeType
 
ORIENTATION_MODE orientationMode
 

Static Public Attributes

static final int FRAME_RATE_FPS_1 = 1
 
static final int FRAME_RATE_FPS_7 = 7
 
static final int FRAME_RATE_FPS_10 = 10
 
static final int FRAME_RATE_FPS_15 = 15
 
static final int FRAME_RATE_FPS_24 = 24
 
static final int FRAME_RATE_FPS_30 = 30
 
static final int FRAME_RATE_FPS_60 = 60
 
static final int STANDARD_BITRATE = 0
 

Member Data Documentation

◆ FRAME_RATE_FPS_1

final int io.agora.rte.media.video.AgoraRteVideoEncoderConfiguration.FRAME_RATE_FPS_1 = 1
static

The frame rate of the video. 1: 1 fps.

◆ FRAME_RATE_FPS_7

final int io.agora.rte.media.video.AgoraRteVideoEncoderConfiguration.FRAME_RATE_FPS_7 = 7
static

7: 7 fps.

◆ FRAME_RATE_FPS_10

final int io.agora.rte.media.video.AgoraRteVideoEncoderConfiguration.FRAME_RATE_FPS_10 = 10
static

10: 10 fps.

◆ FRAME_RATE_FPS_15

final int io.agora.rte.media.video.AgoraRteVideoEncoderConfiguration.FRAME_RATE_FPS_15 = 15
static

15: 15 fps.

◆ FRAME_RATE_FPS_24

final int io.agora.rte.media.video.AgoraRteVideoEncoderConfiguration.FRAME_RATE_FPS_24 = 24
static

24: 24 fps.

◆ FRAME_RATE_FPS_30

final int io.agora.rte.media.video.AgoraRteVideoEncoderConfiguration.FRAME_RATE_FPS_30 = 30
static

30: 30 fps.

◆ FRAME_RATE_FPS_60

final int io.agora.rte.media.video.AgoraRteVideoEncoderConfiguration.FRAME_RATE_FPS_60 = 60
static

Not supported.

◆ STANDARD_BITRATE

final int io.agora.rte.media.video.AgoraRteVideoEncoderConfiguration.STANDARD_BITRATE = 0
static

0: The standard bitrate mode.

◆ dimensions

VideoDimensions io.agora.rte.media.video.AgoraRteVideoEncoderConfiguration.dimensions

The video frame dimensions (px), which is used to specify the video quality and measured by the total number of pixels along a frame's width and height. The default value is 640 × 360. Users can either set the resolution manually or choose from the following options:

Note
  • The value of the dimension does not indicate the orientation mode of the output ratio. For how to set the video orientation, see ORIENTATION_MODE.
  • Whether 720p+ can be supported depends on the device. If the device cannot support 720p, the frame rate will be lower than the one listed in the table.

◆ frameRate

int io.agora.rte.media.video.AgoraRteVideoEncoderConfiguration.frameRate

The video frame rate (fps). The default value is 15. Users can either set the frame rate manually or choose from the following options. We do not recommend setting this to a value greater than 30.

◆ bitrateInKbps

int io.agora.rte.media.video.AgoraRteVideoEncoderConfiguration.bitrateInKbps

The bitrate of the video (Kbps). Refer to the table below and set your bitrate. If you set a bitrate beyond the proper range, the SDK automatically adjusts it to a value within the range. You can also choose from the following options:

  • STANDARD_BITRATE(0): (Recommended) The standard bitrate mode.

Video Bitrate Table

Resolution Frame rate(fps) Standard Bitrate (Kbps)
160 × 120 15 130
120 × 120 15 100
320 × 180 15 280
180 × 180 15 200
240 × 180 15 240
320 × 240 15 400
240 × 240 15 280
424 × 240 15 440
640 × 360 15 800
360 × 360 15 520
640 × 360 30 1200
360 × 360 30 800
480 × 360 15 640
480 × 360 30 980
640 × 480 15 1000
480 × 480 15 800
640 × 480 30 1500
480 × 480 30 1200
848 × 480 15 1220
848 × 480 30 1860
640 × 480 10 800
1280 × 720 15 2260
1280 × 720 30 3420
960 × 720 15 1820
960 × 720 30 2760
Note
We recommend setting the bitrate mode as STANDARD_BITRATE = 0.

◆ orientationMode

ORIENTATION_MODE io.agora.rte.media.video.AgoraRteVideoEncoderConfiguration.orientationMode

The orientation mode. See ORIENTATION_MODE.