Assembly: Bass.Net (in Bass.Net.dll) Version: 184.108.40.206
[DllImportAttribute("bassmidi.dll", CharSet = CharSet.Unicode)] public static bool BASS_MIDI_StreamLoadSamples( int handle )
<DllImportAttribute("bassmidi.dll", CharSet := CharSet.Unicode>] Public Shared Function BASS_MIDI_StreamLoadSamples ( handle As Integer ) As Boolean
public: [DllImportAttribute(L"bassmidi.dll", CharSet = CharSet::Unicode)] static bool BASS_MIDI_StreamLoadSamples( int handle )
[<DllImportAttribute("bassmidi.dll", CharSet = CharSet.Unicode)>] static member BASS_MIDI_StreamLoadSamples : handle : int -> bool
- Type: SystemInt32
The MIDI stream handle.
Return ValueType: Boolean
If successful, is returned, else is returned. Use BASS_ErrorGetCode to get the error code.
Samples are normally loaded as they are needed while rendering a MIDI stream, which can result in CPU spikes, particularly with packed soundfonts. That generally won't cause any problems, but when smooth/constant performance is critical this function can be used to preload the samples before rendering, so avoiding the need to load them while rendering.
Preloaded samples can be compacted/unloaded just like any other samples, so it is probably wise to disable the BASS_CONFIG_MIDI_COMPACT option when preloading samples, to avoid any chance of the samples subsequently being automatically unloaded.
This function should not be used while the MIDI stream is being rendered, as that could interrupt the rendering.
|BASS_ERROR_HANDLE||handle is not valid.|
|BASS_ERROR_NOTAVAIL||The stream is for real-time events only, so it's not possible to know what presets are going to be used. Use BASS_MIDI_FontLoad(Int32, Int32, Int32) instead.|