Public Member Functions | |
RecordingConfig () | |
Public Attributes | |
boolean | isAudioOnly |
boolean | isVideoOnly |
boolean | isMixingEnabled |
MIXED_AV_CODEC_TYPE | mixedVideoAudio |
String | mixResolution |
String | decryptionMode |
String | secret |
String | appliteDir |
String | recordFileRootDir |
String | cfgFilePath |
VIDEO_FORMAT_TYPE | decodeVideo |
AUDIO_FORMAT_TYPE | decodeAudio |
int | lowUdpPort |
int | highUdpPort |
int | idleLimitSec |
int | captureInterval |
int | audioIndicationInterval |
CHANNEL_PROFILE_TYPE | channelProfile |
REMOTE_VIDEO_STREAM_TYPE | streamType |
int | triggerMode |
int | proxyType |
String | proxyServer |
int | audioProfile |
String | defaultVideoBgPath |
String | defaultUserBgPath |
boolean | autoSubscribe |
boolean | enableCloudProxy |
String | subscribeVideoUids |
String | subscribeAudioUids |
boolean | enableIntraRequest |
boolean | enableH265Support |
io.agora.recording.common.RecordingConfig.RecordingConfig | ( | ) |
boolean io.agora.recording.common.RecordingConfig.isAudioOnly |
Sets whether or not to record audio only:
Used together with isVideoOnly:
boolean io.agora.recording.common.RecordingConfig.isVideoOnly |
Sets whether or not to record video only:
Used together with isAudioOnly:
boolean io.agora.recording.common.RecordingConfig.isMixingEnabled |
Sets whether or not to enable the audio- or video-composite mode.
MIXED_AV_CODEC_TYPE io.agora.recording.common.RecordingConfig.mixedVideoAudio |
If you set isMixingEnabled as true, mixedVideoAudio allows you to mix the audio and video in an MP4 file in real time. For more information, see MIXED_AV_CODEC_TYPE.
String io.agora.recording.common.RecordingConfig.mixResolution |
If you set isMixingEnabled as true, mixResolution allows you to set the video profile, including the width, height, frame rate, and bitrate. The default setting is 360 x 640, 15 fps, 500 Kbps.
See the Video Profile Table.
String io.agora.recording.common.RecordingConfig.decryptionMode |
When the whole channel is encrypted, the recording SDK uses decryptionMode to enable the built-in decryption function:
The default value is NULL.
String io.agora.recording.common.RecordingConfig.secret |
The decryption password when decryption mode is enabled. The default value is NULL.
String io.agora.recording.common.RecordingConfig.appliteDir |
Sets the path of AgoraCoreService. The default path of AgoraCoreService is Agora_Recording_SDK_for_Linux_FULL/bin/.
String io.agora.recording.common.RecordingConfig.recordFileRootDir |
Sets the path of the recorded files. The default value is NULL.
After setting recordFileRootDir
, the subdirectory will be automatically generated according to the date of the recording.
String io.agora.recording.common.RecordingConfig.cfgFilePath |
Sets the path of the configuration file. The default value is NULL
. The content in the configuration file must be in JSON format. You can configure the following parameters:
Recording_Dir
: The absolute directory of the output. The recording service does not automatically create a subdirectory.Chunk_Time_Span
: Time interval, in seconds, between two successive recorded files. Only in an individual recording session can you set Chunk_Time_Span
, which must be ≥ 10.In the following example, the recording service creates a file every 10 seconds, and stores these files in the targeted directory:
{"Recording_Dir": "/home/guest/recording_dir/", "Chunk_Time_Span": 10}
VIDEO_FORMAT_TYPE io.agora.recording.common.RecordingConfig.decodeVideo |
Sets the video decoding format. See VIDEO_FORMAT_TYPE.
AUDIO_FORMAT_TYPE io.agora.recording.common.RecordingConfig.decodeAudio |
Sets the audio decoding format. See AUDIO_FORMAT_TYPE.
int io.agora.recording.common.RecordingConfig.lowUdpPort |
Sets the lowest UDP port. The default value is 0. Ensure that the value of highUdpPort - lowUdpPort ≥ 6.
int io.agora.recording.common.RecordingConfig.highUdpPort |
Sets the highest UDP port. The default value is 0. Ensure that the value of highUdpPort - lowUdpPort ≥ 6.
int io.agora.recording.common.RecordingConfig.idleLimitSec |
Sets a time period. The value must be ≥ 3 seconds. The default value is 300 seconds.
When the Agora Recording SDK is recording, if there is no user in the channel after a time period of idleLimitSec
, it automatically stops recording and leaves the channel.
idleLimitSec
), the recording service automatically stops and leaves the channel. int io.agora.recording.common.RecordingConfig.captureInterval |
Sets the interval of the screen capture. The interval must be longer than 1 second and the default value is 5 seconds.
captureInterval
is only valid when decodeVideo is set as 3, 4 or 5. int io.agora.recording.common.RecordingConfig.audioIndicationInterval |
Sets whether or not to detect the users who speak.
CHANNEL_PROFILE_TYPE io.agora.recording.common.RecordingConfig.channelProfile |
Sets the channel mode. See CHANNEL_PROFILE_TYPE.
REMOTE_VIDEO_STREAM_TYPE io.agora.recording.common.RecordingConfig.streamType |
streamType
takes effect only when the Agora Native SDK/Web SDK enables the dual-stream mode (high stream by default). See REMOTE_VIDEO_STREAM_TYPE.
int io.agora.recording.common.RecordingConfig.triggerMode |
Sets whether to start the recording automatically or manually:
If you wish to call startService and stopService, then choose Manually.
int io.agora.recording.common.RecordingConfig.proxyType |
Sets the type of the proxy server:
After setting the proxyType
parameter, you need to set the proxyServer
parameter. See Use Cloud Proxy for details.
String io.agora.recording.common.RecordingConfig.proxyServer |
Sets the IP address (domain) and port of the proxy server for a recording within the intranet according to the type of the proxy server that you choose with the proxyType
parameter.
proxyType
is 0
, set it as "<ip>:<port>"
. proxyType
is 1
, set it as "<domain>:<port>"
. proxyType
is 2
, set it as "<ip1>,<ip2>,...,<ipx>:<port>"
. See Use Cloud Proxy for details.
int io.agora.recording.common.RecordingConfig.audioProfile |
If you set isMixingEnabled as true, mixResolution allows you to set the audio profile of the recording file:
String io.agora.recording.common.RecordingConfig.defaultVideoBgPath |
Sets the path of the default background image of the canvas in composite recording mode.
If defaultVideoBgPath
is not set, the canvas displays the background color.
String io.agora.recording.common.RecordingConfig.defaultUserBgPath |
Sets the path of the default background image of users in composite recording mode.
The background image is displayed when a user is online and does not send any video stream.
If defaultUserBgPath
is not set, the user region displays the background color.
boolean io.agora.recording.common.RecordingConfig.autoSubscribe |
Sets whether to record the streams of all users or specified users.
autoSubscribe
as false, you should set subscribeVideoUids or subscribeAudioUids to specify users whose video or audio you want to record. boolean io.agora.recording.common.RecordingConfig.enableCloudProxy |
Sets whether or not to enable the cloud proxy:
See Use Cloud Proxy for details.
String io.agora.recording.common.RecordingConfig.subscribeVideoUids |
An array of UIDs whose video streams you want to record.
If you set autoSubscribe as false, subscribeVideoUids
enables you to record the video streams of specified users.
String io.agora.recording.common.RecordingConfig.subscribeAudioUids |
An array of UIDs whose audio streams you want to record.
If you set autoSubscribe as false, subscribeAudioUids
enables you to record the audio streams of specified users.
boolean io.agora.recording.common.RecordingConfig.enableIntraRequest |
Sets whether to enable the keyframe request. The default value is true
, which can improve the audio and video quality under poor network conditions. To play the video file recorded in individual recording mode from a specified position, you must set enableIntraRequest
as false.
boolean io.agora.recording.common.RecordingConfig.enableH265Support |
Sets whether to enable recording video stream in H.265 format: