Wav class

A WAV file, containing audio, and metadata.

Constructors

Wav(List<Float64List> channels, int samplesPerSecond, [WavFormat format = WavFormat.pcm16bit])
Constructs a Wav directly from audio data.

Properties

channels List<Float64List>
Audio data, as a list of channels.
final
duration double
Returns the duration of the Wav in seconds.
no setter
format WavFormat
The format of the WAV file.
final
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
samplesPerSecond int
The sampling frequency of the audio data, in Hz.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toMono() Float64List
Mix the audio channels down to mono.
toString() String
A string representation of this object.
inherited
write() Uint8List
Write the Wav to a byte buffer.
writeFile(String filename) Future<void>
Write the Wav to a file.

Operators

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

Static Methods

read(Uint8List bytes) Wav
Read a Wav from a byte buffer.
readFile(String filename) Future<Wav>
Read a Wav from a file.