Esempio n. 1
0
/*
 * Instantiate /classes/.
 */
static void allocAll () {
  if (! (inst.state = allocRunningConfig())) {
    fprintf (stderr, "FATAL: memory allocation failed for state memory.\n");
    exit(1);
  }
  if (! (inst.progs = allocProgs())) {
    fprintf (stderr, "FATAL: memory allocation failed for program config.\n");
    exit(1);
  }
  if (! (inst.reverb = allocReverb())) {
    fprintf (stderr, "FATAL: memory allocation failed for reverb.\n");
    exit(1);
  }
  if (! (inst.whirl = allocWhirl())) {
    fprintf (stderr, "FATAL: memory allocation failed for whirl.\n");
    exit(1);
  }
  if (! (inst.synth = allocTonegen())) {
    fprintf (stderr, "FATAL: memory allocation failed for tonegen.\n");
    exit(1);
  }
  if (! (inst.midicfg = allocMidiCfg(inst.state))) {
    fprintf (stderr, "FATAL: memory allocation failed for midi config.\n");
    exit(1);
  }
  if (! (inst.preamp = allocPreamp())) {
    fprintf (stderr, "FATAL: memory allocation failed for midi config.\n");
    exit(1);
  }
}
Esempio n. 2
0
File: lv2.c Progetto: aelse/setBfree
void allocSynth(struct b_instance *inst) {
  inst->state = allocRunningConfig();
  inst->progs = allocProgs();
  inst->reverb = allocReverb();
  inst->whirl = allocWhirl();
  inst->midicfg = allocMidiCfg(inst->state);
  inst->synth = allocTonegen();
  inst->preamp = allocPreamp();

  initControllerTable (inst->midicfg);
#if 1
  midiPrimeControllerMapping (inst->midicfg);
#endif

}