Cloud recording supports recording audio, video streams, and whiteboard files, which is multi-sector recording. And this mode can be used in conjunction with the single-stream and mixed-stream recording modes. In single-stream recording mode, the whiteboard recording will be generated into a single video file. In the mixed-stream recording mode, the whiteboard recording, audio, and video streams will be generated into a file.
We currently support the following image file formats: JPG, JPEG, PNG, BMP.
This document describes how to implement multi-sector recording by using cloud recording APIs.
To record the whiteboard, set the HasWhiteboard
to true
when calling the StartRecord
method.
The Whiteboard
is an array in JSON format that consists of the configurations of the whiteboard. You can only configure one whiteboard for now.
HorizontalRatio
and VerticalRatio
parameters indicate the aspect ratio of the original whiteboard region and are required.Width
and Height
parameters indicate the resolution of the outputted whiteboard video in single-stream recording mode. While you don't need to set these two parameters in mixed-stream recording mode.WhiteboardId
parameter indicates the ID of the whiteboard that is being recorded.To change a whiteboard, call the UpdateWhiteboard
method, and set the WhiteboardId
parameter with the ID of the whiteboard you want to change to.
Content-type
: application/json; charset=utf-8
The request example of enabling whiteboard recording in mixed-stream recording mode is as follows:
{
"RoomId": "xxxx",
"RecordInputParams": {
"RecordMode": 2,
"StreamType": 3,
"HasWhiteboard": true,
"Whiteboard": [
{
"HorizontalRatio": 16,
"VerticalRatio": 9,
"Width": 1280,
"Height": 720,
"WhiteboardId": "0000"
}
],
"MaxIdleTime": 60,
"MixConfig": {
"MixMode": 3,
"MixOutputStreamId": "mix",
"MixOutputVideoConfig": {
"Width": 1280,
"Height": 720,
"Fps": 15,
"Bitrate": 1130000
}
}
},
"RecordOutputParams": {
"OutputFileFormat": "mp4",
"OutputFolder": "record/"
},
"StorageParams": {
"Vendor": 2,
"Region": "oss-xxxx",
"Bucket": "xxxx",
"AccessKeyId": "xxxx",
"AccessKeySecret": "xxxx"
}
}