is-opus
Check if a Buffer/Uint8Array is an OPUS audio file.
Install
$ npm install --save is-opus
Usage
Node.js
var readChunk = ; // npm install read-chunkvar isOpus = ;var buffer = readChunk; ;//=> true
Browser
var xhr = ;xhr;xhrresponseType = 'arraybuffer'; xhr { ; //=> true}; xhr;
API
isOpus(buffer)
Accepts a Buffer (Node.js) or Uint8Array.
It only needs the first 36 bytes.
License
MIT © t1st3