Closed shahul-vm closed 2 years ago
Yes, it should be possible to use JSON directly:
const myWaveformData = {
sample_rate: 44100,
samples_per_pixel: 256,
bits: 8,
length: 4,
data: [0,3,0,3,-1,6,-8,11]
};
const options = {
// other options as needed
waveformData: {
json: myWaveformData
}
};
Peaks.init(options, (err, peaks) => {
// etc
});
Does peak.js work with raw JSON objects not the data URI data directly?