small streaming parser for flac audio files
npm install flac-parserFLAC Audio File Metadata parser
=====================================
A simple streaming parser for retrieving metadata from an .flac file.
npm install flac-parser
var FLAC = require('flac-parser')
, stream = require('fs').createReadStream('./my-file.flac')
var parser = stream.pipe(new FLAC());
parser.on('data', function(tag){
console.log(tag.type) // => 'samplesInStream'
console.log(tag.value) // => 443520
})
In addition to the normal vorbis comments audio tags metadata the flac parser exposes additional
flace info, from the STREAM_INFO block of the file
- duration
- minBlockSize
- maxBlockSize
- minFrameSize
- maxFrameSize
- channels
- bitsPerSample
- samplesInStream
consult the vorbis parser (used internally for comments)
documentation for more information