peaks.js icon indicating copy to clipboard operation
peaks.js copied to clipboard

minimum width for a visualized overview?

Open EZWrighter opened this issue 1 year ago • 3 comments

When my data length is under 3.5 seconds the visualization behaves incorrectly. Showing the 3.5 second timeline as a minimum but only showing the waveform as a portion of that. Not displaying it as an overview at 100% of the canvas.

image

EZWrighter avatar Dec 15 '23 23:12 EZWrighter

This is because the waveform data doesn't have enough pixels to fit the canvas width. The easiest solution is to create the waveform with a lower number of samples per pixel. Or we could change Peaks.js to stretch the waveform.

chrisn avatar Dec 16 '23 09:12 chrisn

Or we could change Peaks.js to stretch the waveform.

This seems like a more robust way of handling it, although, would that make the visual wonky?

rafeautie avatar Mar 28 '24 00:03 rafeautie