IMediaRecorderObserver

The IMediaRecorderObserver class.

onRecorderStateChanged

Occurs when the recording state changes.

virtual void onRecorderStateChanged(RecorderState state, RecorderErrorCode error) = 0;

When the local audio or video recording state changes, the SDK triggers this callback to report the current recording state and the reason for the change.

Parameters

state
The current recording state. See RecorderState.
error
The reason for the state change. See RecorderErrorCode.

onRecorderInfoUpdated

Occurs when the recording information is updated.

virtual void onRecorderInfoUpdated(const RecorderInfo& info){};

After you successfully enable the local audio and video recording, the SDK periodically triggers this callback based on the value of recorderInfoUpdateInterval set in MediaRecorderConfiguration. This callback reports the file name, duration, and size of the current recording file.

Parameters

info
The information about the file that is recorded. See RecorderInfo.