BASS_CONFIG_MIDI_SAMPLEREAD config option

The amount of sample data to read at a time asynchronously.

BASS_SetConfig(
    BASS_CONFIG_MIDI_SAMPLEREAD,
    DWORD chunk
);

Parameters

chunkThe amount of data to read at a time, in sample frames... 8192 (min) - 2147483647 (max). If the specified value is outside this range, it is automatically capped.

Remarks

When samples are loading asynchronously, they are read in chunks so that they have some data available to play more quickly (they can start playing before they are fully loaded). This option determines the size of those chunks. Smaller chunks may allow more samples to have data available more quickly but it may also mean more seeking, which may be slower if a soundfont is stored on a mechanical drive.

The default setting is 32768. Changes take immediate effect.

Samples are loaded asynchronously when needed during playback, and optionally in advance with BASS_MIDI_FontLoadEx.

See also

BASS_MIDI_FontLoadEx

BASS_GetConfig