fluid-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[fluid-dev] Instance creation


From: Anuj Deshpande
Subject: [fluid-dev] Instance creation
Date: Sun, 26 Mar 2017 06:00:55 +0000

Hi

I am trying to create a new instance of fluidsynth from a C program -


#include "../fluidsynth-1.1.6/include/fluidsynth.h"

void fs_init(){

  printf("### Begin fs_init ### \r\n");
  fluid_settings_t* settings;
  fluid_synth_t* synth;
  fluid_audio_driver_t* adriver;
  settings = new_fluid_settings();

  /* Set the synthesizer settings, if necessary */
  printf("Creating new synth .. \r\n");
  synth = new_fluid_synth(settings);
  printf("Creating new audio driver.. \r\n");
  fluid_settings_setstr(settings, "audio.driver", "coreaudio");
  adriver = new_fluid_audio_driver(settings, synth);

}

My build instruction looks like -


$(CC) -o build/exec -g -Wall src/main.c /usr/local/lib/libfluidsynth.dylib -lm

The program builds fine, but I am not able to see an instance of fluidsynth being created in my processes. 


What would be the correct way to invoke fluidsynth from within another program? Is there a sample code/project available?

-Anuj


reply via email to

[Prev in Thread] Current Thread [Next in Thread]