|
libfluidsynth 2.5.4
|
Low-level access to synthesis voices. More...
Functions | |
| fluid_voice_t * | fluid_synth_alloc_voice (fluid_synth_t *synth, fluid_sample_t *sample, int channum, int key, int vel) |
| Allocate a synthesis voice. | |
| void | fluid_synth_get_voicelist (fluid_synth_t *synth, fluid_voice_t *buf[], int bufsize, int ID) |
| Get list of currently playing voices. | |
| int | fluid_synth_start (fluid_synth_t *synth, unsigned int id, fluid_preset_t *preset, int audio_chan, int midi_chan, int key, int vel) |
| Create and start voices using an arbitrary preset and a MIDI note on event. | |
| void | fluid_synth_start_voice (fluid_synth_t *synth, fluid_voice_t *voice) |
| Activate a voice previously allocated with fluid_synth_alloc_voice(). | |
| int | fluid_synth_stop (fluid_synth_t *synth, unsigned int id) |
| Stop notes for a given note event voice ID. | |
Low-level access to synthesis voices.
| fluid_voice_t * fluid_synth_alloc_voice | ( | fluid_synth_t * | synth, |
| fluid_sample_t * | sample, | ||
| int | chan, | ||
| int | key, | ||
| int | vel ) |
Allocate a synthesis voice.
| Synthesizer | FluidSynth instance |
| sample | Sample to assign to the voice |
| chan | MIDI channel number (0 to MIDI channel count - 1) |
| key | MIDI note number for the voice (0-127) |
| vel | MIDI velocity for the voice (0-127) |
This function is called by a SoundFont's preset in response to a noteon event. The returned voice comes with default modulators and generators. A single noteon event may create any number of voices, when the preset is layered.
| void fluid_synth_get_voicelist | ( | fluid_synth_t * | synth, |
| fluid_voice_t * | buf[], | ||
| int | bufsize, | ||
| int | id ) |
Get list of currently playing voices.
| Synthesizer | FluidSynth instance |
| buf | Array to store voices to (NULL terminated if not filled completely) |
| bufsize | Count of indexes in buf |
| id | Voice ID to search for or < 0 to return list of all playing voices |
| int fluid_synth_start | ( | fluid_synth_t * | synth, |
| unsigned int | id, | ||
| fluid_preset_t * | preset, | ||
| int | audio_chan, | ||
| int | chan, | ||
| int | key, | ||
| int | vel ) |
Create and start voices using an arbitrary preset and a MIDI note on event.
Using this function is only supported when the setting synth.dynamic-sample-loading is false!
| Synthesizer | FluidSynth instance |
| id | Voice group ID to use (can be used with fluid_synth_stop()). |
| preset | Preset to synthesize |
| audio_chan | Unused currently, set to 0 |
| chan | MIDI channel number (0 to MIDI channel count - 1) |
| key | MIDI note number (0-127) |
| vel | MIDI velocity number (1-127) |
| void fluid_synth_start_voice | ( | fluid_synth_t * | synth, |
| fluid_voice_t * | voice ) |
Activate a voice previously allocated with fluid_synth_alloc_voice().
| Synthesizer | FluidSynth instance |
| voice | Voice to activate |
This function is called by a SoundFont's preset in response to a noteon event. Exclusive classes are processed here.
| int fluid_synth_stop | ( | fluid_synth_t * | synth, |
| unsigned int | id ) |
Stop notes for a given note event voice ID.
| Synthesizer | FluidSynth instance |
| id | Voice note event ID |