Fix default disk_io_chunk_frames for diskstream so that it
isn't larger than the default playback buffer size when starting Ardour without a previous ~/.config; having disk_io_chunk_frames larger violates basic design assumptions and causes phantom underruns in playback (#4308). git-svn-id: svn://localhost/ardour2/branches/3.0@10079 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
@@ -1021,6 +1021,10 @@ AudioDiskstream::_do_refill (Sample* mixdown_buffer, float* gain_buffer)
|
||||
|
||||
at higher speeds, just do it because the sync between butler
|
||||
and audio thread may not be good enough.
|
||||
|
||||
Note: it is a design assumption that disk_io_chunk_frames is smaller
|
||||
than the playback buffer size, so this check should never trip when
|
||||
the playback buffer is empty.
|
||||
*/
|
||||
|
||||
if ((total_space < disk_io_chunk_frames) && fabs (_actual_speed) < 2.0f) {
|
||||
|
||||
@@ -70,7 +70,7 @@ using namespace PBD;
|
||||
* default from configuration_vars.h). 0 is not a good value for
|
||||
* allocating buffer sizes..
|
||||
*/
|
||||
ARDOUR::framecnt_t Diskstream::disk_io_chunk_frames = 1024 * 256;
|
||||
ARDOUR::framecnt_t Diskstream::disk_io_chunk_frames = 1024 * 256 / sizeof (Sample);
|
||||
|
||||
PBD::Signal0<void> Diskstream::DiskOverrun;
|
||||
PBD::Signal0<void> Diskstream::DiskUnderrun;
|
||||
|
||||
Reference in New Issue
Block a user