|
|
@ -35,6 +35,7 @@ mdaEPiano::mdaEPiano() // mdaEPiano::mdaEPiano(audioMasterCallback audioMaster) |
|
|
|
{ |
|
|
|
{ |
|
|
|
Fs = SAMPLE_RATE; iFs = 1.0f / Fs; //just in case...
|
|
|
|
Fs = SAMPLE_RATE; iFs = 1.0f / Fs; //just in case...
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
programs = new mdaEPianoProgram[NPROGS]; |
|
|
|
programs = new mdaEPianoProgram[NPROGS]; |
|
|
|
if (programs) |
|
|
|
if (programs) |
|
|
|
{ |
|
|
|
{ |
|
|
@ -50,6 +51,7 @@ mdaEPiano::mdaEPiano() // mdaEPiano::mdaEPiano(audioMasterCallback audioMaster) |
|
|
|
fillpatch(i++, "(default)", 0.500f, 0.500f, 0.500f, 0.500f, 0.500f, 0.650f, 0.250f, 0.500f, 1.0f, 0.500f, 0.146f, 0.000f); |
|
|
|
fillpatch(i++, "(default)", 0.500f, 0.500f, 0.500f, 0.500f, 0.500f, 0.650f, 0.250f, 0.500f, 1.0f, 0.500f, 0.146f, 0.000f); |
|
|
|
setProgram(0); |
|
|
|
setProgram(0); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
*/ |
|
|
|
|
|
|
|
|
|
|
|
waves = (short*)epianoDataXfade; |
|
|
|
waves = (short*)epianoDataXfade; |
|
|
|
|
|
|
|
|
|
|
@ -118,7 +120,7 @@ void mdaEPiano::reset_voices(void) // reset all voices |
|
|
|
tl = tr = lfo0 = dlfo = 0.0f; |
|
|
|
tl = tr = lfo0 = dlfo = 0.0f; |
|
|
|
lfo1 = 1.0f; |
|
|
|
lfo1 = 1.0f; |
|
|
|
|
|
|
|
|
|
|
|
guiUpdate = 0; |
|
|
|
//guiUpdate = 0;
|
|
|
|
|
|
|
|
|
|
|
|
vol = VOLUME; |
|
|
|
vol = VOLUME; |
|
|
|
update(); |
|
|
|
update(); |
|
|
@ -162,13 +164,13 @@ mdaEPiano::~mdaEPiano () //destroy any buffers... |
|
|
|
if (programs) delete [] programs; |
|
|
|
if (programs) delete [] programs; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
void mdaEPiano::setProgram(int32_t program) |
|
|
|
void mdaEPiano::setProgram(int32_t program) |
|
|
|
{ |
|
|
|
{ |
|
|
|
curProgram = program; |
|
|
|
curProgram = program; |
|
|
|
update(); |
|
|
|
update(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
*/ |
|
|
|
|
|
|
|
|
|
|
|
void mdaEPiano::setParameter(int32_t index, float value) |
|
|
|
void mdaEPiano::setParameter(int32_t index, float value) |
|
|
|
{ |
|
|
|
{ |
|
|
@ -176,7 +178,7 @@ void mdaEPiano::setParameter(int32_t index, float value) |
|
|
|
update(); |
|
|
|
update(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
void mdaEPiano::fillpatch(int32_t p, char *name, float p0, float p1, float p2, float p3, float p4, |
|
|
|
void mdaEPiano::fillpatch(int32_t p, char *name, float p0, float p1, float p2, float p3, float p4, |
|
|
|
float p5, float p6, float p7, float p8, float p9, float p10, float p11) |
|
|
|
float p5, float p6, float p7, float p8, float p9, float p10, float p11) |
|
|
|
{ |
|
|
|
{ |
|
|
@ -192,6 +194,7 @@ void mdaEPiano::fillpatch(int32_t p, char *name, float p0, float p1, float p2, f |
|
|
|
float mdaEPiano::getParameter(int32_t index) { |
|
|
|
float mdaEPiano::getParameter(int32_t index) { |
|
|
|
return programs[curProgram].param[index]; |
|
|
|
return programs[curProgram].param[index]; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
*/ |
|
|
|
|
|
|
|
|
|
|
|
void mdaEPiano::process(int16_t* outputs_r, int16_t* outputs_l) |
|
|
|
void mdaEPiano::process(int16_t* outputs_r, int16_t* outputs_l) |
|
|
|
{ |
|
|
|
{ |
|
|
|