MediaFormat class

Constructors

MediaFormat.detail({@required String name, int sampleRate = 16000, int numChannels = 1, int bitRate = 16000})
const

Properties

bitRate int
final
extension String
Returns the commonly used file extension for this MediaFormat e.g. 'mp3'
read-only
hashCode int
The hash code for this object.
read-only, inherited
isNativeDecoder Future<bool>
Only MediaFormats that natively supported decoding (playback) by the current platform should return true.
read-only
isNativeEncoder Future<bool>
Only MediaFormats that natively supported encoding (recording) by the current platform should return true.
read-only
name String
The name of the MediaFormat. The name MUST be of the form container/codec (not all lower case) e.g. ogg/vorbis
final
numChannels int
final
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
sampleRate int
final

Methods

getDuration(String path) Future<Duration>
Returns the duration of the audio file at the given path. The audio file at the given path MUST be the of the same MediaFormat otherwise the result is undefined.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(covariant MediaFormat other) bool
The equality operator.
override