Skip to content

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

@audio/decode-wav

Decode WAV/RIFF audio in pure JavaScript. Supports PCM, float, A-law, µ-law, IMA ADPCM, and MS ADPCM.

npm install @audio/decode-wav
import decode, { decoder } from '@audio/decode-wav'

let { channelData, sampleRate } = decode(bytes)

let dec = decoder()
let result = dec.decode(chunk)
dec.free()

decode() and decoder() are synchronous. The ./meta subpath reads embedded metadata. The ./audio subpath registers the codec with audio.

License

· MIT