WaveBuilder class

Build a wave file.

Constructors

WaveBuilder({int bitRate = 16, int frequency = 44100, bool stereo = true})
Construct a wave builder. Supply audio file properties.

Properties

fileBytes List<int>
Finalizes the header sizes and returns bytes
no setter
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

appendFileContents(List<int> fileContents, {bool findDataChunk = true}) → void
Append fileContents read as bytes to our wave file. If findDataChunk is true, searches first to find the file's data chunk. It's recommended to call getDataChunk on the file contents you want to append first, to prevent repeating everytime you add the same file.
appendSilence(int msLength, WaveBuilderSilenceType silenceType) → void
Append msLength milliseconds of silence to our wave file. silenceType determines whether we start the counter for silence from the beginning of the last sample or the end.
getDataChunk(List<int> fileContents) List<int>
Find data chunk content after <data|size> in fileContents
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

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

Constants

AUDIO_FORMAT → const int
BYTE_SIZE → const int
RIFF_CHUNK_SIZE_INDEX → const int
SUB_CHUNK_SIZE → const int