Very small changes... most are code cleanups and removed a to talkative trace output.

pull/1/head
root 7 years ago
parent ca476751eb
commit 1d6239f89d
  1. 4
      src/dexed.cpp
  2. 6
      src/msfa/dx7note.cc

@ -36,6 +36,7 @@ Dexed::Dexed(double rate) : lvtk::Synth<DexedVoice, Dexed>(p_n_ports, p_midi_in)
{ {
uint8_t i; uint8_t i;
TRACE("--------------------------------------------------------------------------------");
TRACE("Hi"); TRACE("Hi");
Exp2::init(); Exp2::init();
@ -123,6 +124,7 @@ Dexed::~Dexed()
} }
TRACE("Bye"); TRACE("Bye");
TRACE("--------------------------------------------------------------------------------");
} }
void Dexed::activate(void) void Dexed::activate(void)
@ -511,7 +513,7 @@ void Dexed::GetSamples(uint32_t n_samples, float* buffer)
// this voice is a carrier! // this voice is a carrier!
op_carrier_num++; op_carrier_num++;
TRACE("Voice[%2d] OP [%d] amp=%ld,amp_step=%d,pitch_step=%d",i,op,voiceStatus.amp[op],voiceStatus.ampStep[op],voiceStatus.pitchStep); //TRACE("Voice[%2d] OP [%d] amp=%ld,amp_step=%d,pitch_step=%d",i,op,voiceStatus.amp[op],voiceStatus.ampStep[op],voiceStatus.pitchStep);
if(voiceStatus.amp[op]<=1069 && voiceStatus.ampStep[op]==4) // this voice produces no audio output if(voiceStatus.amp[op]<=1069 && voiceStatus.ampStep[op]==4) // this voice produces no audio output
op_amp++; op_amp++;

@ -138,7 +138,6 @@ Dx7Note::Dx7Note() {
} }
} }
//void Dx7Note::init(const uint8_t patch[156], int midinote, int velocity, int fb_depth) {
void Dx7Note::init(const uint8_t patch[167], int midinote, int velocity) { void Dx7Note::init(const uint8_t patch[167], int midinote, int velocity) {
int rates[4]; int rates[4];
int levels[4]; int levels[4];
@ -191,8 +190,9 @@ void Dx7Note::compute(int32_t *buf, int32_t lfo_val, int32_t lfo_delay, const Co
pmod_2 = abs(pmod_2); pmod_2 = abs(pmod_2);
int32_t pitch_mod = max(pmod_1, pmod_2); int32_t pitch_mod = max(pmod_1, pmod_2);
pitch_mod = pitchenv_.getsample() + (pitch_mod * (senslfo < 0 ? -1 : 1)); pitch_mod = pitchenv_.getsample() + (pitch_mod * (senslfo < 0 ? -1 : 1));
uint32_t pitchbend = ctrls->values_[kControllerPitch]; // ---- PITCH BEND ----
int pitchbend = ctrls->values_[kControllerPitch];
int32_t pb = (pitchbend - 0x2000); int32_t pb = (pitchbend - 0x2000);
if (pb != 0) { if (pb != 0) {
if (ctrls->values_[kControllerPitchStep] == 0) { if (ctrls->values_[kControllerPitchStep] == 0) {

Loading…
Cancel
Save