Don't read more peaks than needed for waveform.

pull/3/head
Jonathan Moore Liles 2008-03-26 12:53:36 -05:00
parent b0d5b60a6f
commit 2abf28095c
2 changed files with 4 additions and 1 deletions

View File

@ -48,6 +48,8 @@ Peaks::fill_buffer ( float fpp, int s, int e ) const
{
_fpp = fpp;
printf( "fill_buffer\n" );
/* FIXME: repair this */
// if ( fpp < _peaks->chunksize )
{

View File

@ -460,7 +460,8 @@ Region::draw ( int X, int Y, int W, int H )
Peak *pbuf;
_clip->read_peaks( timeline->fpp(),
_start + offset, min( (_end - _start) - offset, _end),
// _start + offset, min( (_end - _start) - offset, _end),
_start + offset, _start + offset + timeline->x_to_ts( W ),
&peaks, &pbuf, &channels );
assert( pbuf );