diff --git a/src/extensions/wavesurfer.view.js b/src/extensions/wavesurfer.view.js index 2707d7a..2b24fe0 100644 --- a/src/extensions/wavesurfer.view.js +++ b/src/extensions/wavesurfer.view.js @@ -162,7 +162,15 @@ fn.prototype=WaveSurferView.prototype={ //计算绘制占用长度 var pcmDuration=pcmData.length*1000/sampleRate; var pcmWidth=pcmDuration*width/set.duration; - var pointCount=Math.max(1,Math.floor(pcmWidth/lineWidth)); + pcmWidth+=This.drawLoss||0; + var pointCount=0; + if(pcmWidth