Timeline: When waiting for peaks, only check again every 500ms.
This commit is contained in:
parent
ad3d826493
commit
6a0b2d2069
|
@ -420,7 +420,7 @@ Audio_Region::peaks_pending_cb ( Peaks_Redraw_Request *r )
|
||||||
delete r;
|
delete r;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Fl::repeat_timeout( 0.1f, &Audio_Region::peaks_pending_cb, (void*)r );
|
Fl::repeat_timeout( 0.5f, &Audio_Region::peaks_pending_cb, (void*)r );
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -614,7 +614,7 @@ Audio_Region::draw ( void )
|
||||||
if ( peaks < loop_peaks_needed )
|
if ( peaks < loop_peaks_needed )
|
||||||
{
|
{
|
||||||
/* couldn't read peaks--perhaps they're being generated. Try again later. */
|
/* couldn't read peaks--perhaps they're being generated. Try again later. */
|
||||||
Fl::add_timeout( 0.1f, &Audio_Region::peaks_pending_cb,
|
Fl::add_timeout( 0.5f, &Audio_Region::peaks_pending_cb,
|
||||||
new Peaks_Redraw_Request( this, start + timeline->x_to_ts( peaks ), end ) );
|
new Peaks_Redraw_Request( this, start + timeline->x_to_ts( peaks ), end ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue