Miscellaneous utility functions and defines. More...
Defines | |
#define | FLUID_OK (0) |
Value that indicates success, used by most libfluidsynth functions. | |
#define | FLUID_FAILED (-1) |
Value that indicates failure, used by most libfluidsynth functions. | |
Functions | |
FLUIDSYNTH_API int | fluid_is_soundfont (const char *filename) |
Check if a file is a SoundFont file. | |
FLUIDSYNTH_API int | fluid_is_midifile (const char *filename) |
Check if a file is a MIDI file. |
Miscellaneous utility functions and defines.
#define FLUID_OK (0) |
Value that indicates success, used by most libfluidsynth functions.
NOTE: This was not publicly defined prior to libfluidsynth 1.1.0. When writing code which should also be compatible with older versions, something like the following can be used:
#include <fluidsynth.h> #ifndef FLUID_OK #define FLUID_OK (0) #define FLUID_FAILED (-1) #endif
Referenced by fluid_ramsfont_add_izone(), fluid_ramsfont_remove_izone(), fluid_synth_alloc_voice(), fluid_synth_bank_select(), fluid_synth_get_cc(), fluid_synth_get_pitch_bend(), fluid_synth_get_pitch_wheel_sens(), fluid_synth_get_program(), fluid_synth_program_reset(), fluid_synth_set_bank_offset(), fluid_synth_set_gen(), fluid_synth_set_gen2(), fluid_synth_set_interp_method(), fluid_synth_sfont_select(), fluid_synth_sfreload(), fluid_synth_sfunload(), fluid_synth_tuning_dump(), and fluid_voice_optimize_sample().
#define FLUID_FAILED (-1) |
Value that indicates failure, used by most libfluidsynth functions.
NOTE: See FLUID_OK for more details.
Referenced by delete_fluid_midi_router(), fluid_midi_router_add_rule(), fluid_midi_router_clear_rules(), fluid_midi_router_handle_midi_event(), fluid_midi_router_set_default_rules(), fluid_synth_activate_key_tuning(), fluid_synth_activate_octave_tuning(), fluid_synth_activate_tuning(), fluid_synth_add_sfont(), fluid_synth_bank_select(), fluid_synth_cc(), fluid_synth_channel_pressure(), fluid_synth_deactivate_tuning(), fluid_synth_get_active_voice_count(), fluid_synth_get_cc(), fluid_synth_get_channel_info(), fluid_synth_get_gen(), fluid_synth_get_pitch_bend(), fluid_synth_get_pitch_wheel_sens(), fluid_synth_get_polyphony(), fluid_synth_get_program(), fluid_synth_noteoff(), fluid_synth_noteon(), fluid_synth_pitch_bend(), fluid_synth_pitch_wheel_sens(), fluid_synth_program_change(), fluid_synth_program_select(), fluid_synth_program_select_by_sfont_name(), fluid_synth_set_bank_offset(), fluid_synth_set_gen(), fluid_synth_set_gen2(), fluid_synth_set_interp_method(), fluid_synth_set_polyphony(), fluid_synth_sfload(), fluid_synth_sfont_select(), fluid_synth_sfreload(), fluid_synth_sfunload(), fluid_synth_start(), fluid_synth_stop(), fluid_synth_sysex(), fluid_synth_system_reset(), fluid_synth_tune_notes(), fluid_synth_tuning_dump(), and fluid_synth_unset_program().
FLUIDSYNTH_API int fluid_is_soundfont | ( | const char * | filename | ) |
Check if a file is a SoundFont file.
filename | Path to the file to check |
The current implementation only checks for the "RIFF" header in the file. It is useful only to distinguish between SoundFont and MIDI files.
References fluid_is_soundfont().
Referenced by fluid_is_soundfont().
FLUIDSYNTH_API int fluid_is_midifile | ( | const char * | filename | ) |
Check if a file is a MIDI file.
filename | Path to the file to check |
The current implementation only checks for the "MThd" header in the file. It is useful only to distinguish between SoundFont and MIDI files.
References fluid_is_midifile().
Referenced by fluid_is_midifile().