libretro-prboom/deps/fluidlite
2021-11-06 18:46:41 +01:00
..
include fluidlite cleanups 2021-10-08 18:58:45 +02:00
libogg-1.3.2 Cleanups 2021-11-06 18:46:41 +01:00
libvorbis-1.3.5 Cleanups 2021-11-06 18:46:41 +01:00
src Cleanups 2021-10-08 19:02:01 +02:00
CMakeLists.txt Move dependencies to deps/ 2016-09-08 01:03:51 +02:00
fluidlite.pc.in Move dependencies to deps/ 2016-09-08 01:03:51 +02:00
LICENSE Move dependencies to deps/ 2016-09-08 01:03:51 +02:00
README.md Move dependencies to deps/ 2016-09-08 01:03:51 +02:00

FLUIDLITE 1.0 (c) 2016 Robin Lobel

FluidLite is a very light version of FluidSynth designed to be hardware, platform and external dependency independant. It only uses standard C libraries.

It also adds support for SF3 files (SF2 files compressed with ogg vorbis) and an additional setting to remove the constraint of channel 9 (drums): fluid_settings_setstr(settings, "synth.drums-channel.active", "no"); you can still select bank 128 on any channel to use drum kits.

FluidLite keeps very minimal functionnalities (settings and synth), therefore MIDI file reading, realtime MIDI events and audio output must be implemented externally.

Usage:

include "fluidlite.h"

fluid_settings_t* settings=new_fluid_settings();
fluid_synth_t* synth=new_fluid_synth(settings);
fluid_synth_sfload(synth, "soundfont.sf3",1);

float* buffer=new float[44100*2];

FILE* file=fopen("float32output.pcm","wb");

fluid_synth_noteon(synth,0,60,127);
fluid_synth_write_float(synth, 44100,buffer, 0, 2, buffer, 1, 2);
fwrite(buffer,sizeof(float),44100*2,file);

fluid_synth_noteoff(synth,0,60);
fluid_synth_write_float(synth, 44100,buffer, 0, 2, buffer, 1, 2);
fwrite(buffer,sizeof(float),44100*2,file);

fclose(file);

delete_fluid_synth(synth);
delete_fluid_settings(settings);