libfluidsynth
1.1.11
|
Virtual SoundFont preset. More...
Data Fields | |
void * | data |
User supplied data. | |
fluid_sfont_t * | sfont |
Parent virtual SoundFont. | |
int(* | free )(fluid_preset_t *preset) |
Method to free a virtual SoundFont preset. More... | |
char *(* | get_name )(fluid_preset_t *preset) |
Method to get a virtual SoundFont preset name. More... | |
int(* | get_banknum )(fluid_preset_t *preset) |
Method to get a virtual SoundFont preset MIDI bank number. More... | |
int(* | get_num )(fluid_preset_t *preset) |
Method to get a virtual SoundFont preset MIDI program number. More... | |
int(* | noteon )(fluid_preset_t *preset, fluid_synth_t *synth, int chan, int key, int vel) |
Method to handle a noteon event (synthesize the instrument). More... | |
int(* | notify )(fluid_preset_t *preset, int reason, int chan) |
Virtual SoundFont preset notify method. More... | |
Virtual SoundFont preset.
int(* _fluid_preset_t::free) (fluid_preset_t *preset) |
Method to free a virtual SoundFont preset.
preset | Virtual SoundFont preset |
Referenced by fluid_ramsfont_create_sfont().
char*(* _fluid_preset_t::get_name) (fluid_preset_t *preset) |
Method to get a virtual SoundFont preset name.
preset | Virtual SoundFont preset |
Referenced by fluid_ramsfont_create_sfont().
int(* _fluid_preset_t::get_banknum) (fluid_preset_t *preset) |
Method to get a virtual SoundFont preset MIDI bank number.
preset | Virtual SoundFont preset |
return | The bank number of the preset |
Referenced by fluid_ramsfont_create_sfont().
int(* _fluid_preset_t::get_num) (fluid_preset_t *preset) |
Method to get a virtual SoundFont preset MIDI program number.
preset | Virtual SoundFont preset |
return | The program number of the preset |
Referenced by fluid_ramsfont_create_sfont().
int(* _fluid_preset_t::noteon) (fluid_preset_t *preset, fluid_synth_t *synth, int chan, int key, int vel) |
Method to handle a noteon event (synthesize the instrument).
preset | Virtual SoundFont preset |
synth | Synthesizer instance |
chan | MIDI channel number of the note on event |
key | MIDI note number (0-127) |
vel | MIDI velocity (0-127) |
This method may be called from within synthesis context and therefore should be as efficient as possible and not perform any operations considered bad for realtime audio output (memory allocations and other OS calls).
Call fluid_synth_alloc_voice() for every sample that has to be played. fluid_synth_alloc_voice() expects a pointer to a fluid_sample_t structure and returns a pointer to the opaque fluid_voice_t structure. To set or increment the values of a generator, use fluid_voice_gen_set() or fluid_voice_gen_incr(). When you are finished initializing the voice call fluid_voice_start() to start playing the synthesis voice. Starting with FluidSynth 1.1.0 all voices created will be started at the same time.
Referenced by fluid_ramsfont_create_sfont().
int(* _fluid_preset_t::notify) (fluid_preset_t *preset, int reason, int chan) |
Virtual SoundFont preset notify method.
preset | Virtual SoundFont preset |
reason | FLUID_PRESET_SELECTED or FLUID_PRESET_UNSELECTED |
chan | MIDI channel number |
Implement this optional method if the preset needs to be notified about preset select and unselect events.
This method may be called from within synthesis context and therefore should be as efficient as possible and not perform any operations considered bad for realtime audio output (memory allocations and other OS calls).
Referenced by fluid_ramsfont_create_sfont().