MediaRecorder class abstract

Used for recording audio and video on the client. MediaRecorder can record the following: The audio captured by the local microphone and encoded in AAC format. The video captured by the local camera and encoded by the SDK.

Constructors

MediaRecorder()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
releaseRecorder() Future<void>
Releases the MediaRecorder object. This method releases the RtcEngine object and all the other resources used by MediaRecorder . After calling this method, if you want to enable the recording again, you must call getMediaRecorder to get the MediaRecorder first.
startRecording(MediaRecorderConfiguration config) Future<void>
Starts recording the local audio and video. After successfully getting the object, you can all this method to enable the recoridng of the local audio and video. This method can record the following content: The audio captured by the local microphone and encoded in AAC format. The video captured by the local camera and encoded by the SDK. The SDK can generate a recording file only when it detects the recordable audio and video streams; when there are no audio and video streams to be recorded or the audio and video streams are interrupted for more than five seconds, the SDK stops recording and triggers the onRecorderStateChanged (Error, NoStream) callback. Call this method after joining the channel.
stopRecording() Future<void>
Stops recording the local audio and video After calling startRecording , if you want to stop the recording, you must call this method; otherwise, the generated recording files may not be playable.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

getMediaRecorder(RtcEngine engine, {MediaRecorderObserver? callback}) MediaRecorder
Gets the MediaRecorder object. Call this method after initializing the RtcEngine object.