summaryrefslogtreecommitdiff
path: root/synth/programs.cpp
diff options
context:
space:
mode:
authorFlorian Jung <flo@thinkpad.(none)>2011-01-16 18:18:39 +0100
committerFlorian Jung <flo@thinkpad.(none)>2011-01-16 18:30:53 +0100
commit12f20783b7ec8804825282fd04d9333ec83e31eb (patch)
treeaae39218ace9c7c12c14cf1246cd2485bf1323f1 /synth/programs.cpp
parent527e7400f227703b9f0932b685f2bf7f2c2c005b (diff)
Added waveforms and noise, changed foo++ into ++foo
List of waveforms: 0=sin 1=abssin 2=half_sin 3=pulse-sin 4=square 5=sawtooth 6=pyramid 7=white noise
Diffstat (limited to 'synth/programs.cpp')
-rw-r--r--synth/programs.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/synth/programs.cpp b/synth/programs.cpp
index 0f675d6..23da924 100644
--- a/synth/programs.cpp
+++ b/synth/programs.cpp
@@ -66,7 +66,7 @@ void program_t::cleanup()
{
if (osc_settings)
{
- for (unsigned int i=0;i<n_osc;i++)
+ for (unsigned int i=0;i<n_osc;++i)
delete [] osc_settings[i].fm_strength;
delete [] osc_settings;
}
@@ -79,7 +79,7 @@ void program_t::cleanup()
delete [] pfactor.freq_env_amount;
if (pfactor.fm)
{
- for (unsigned int i=0;i<n_osc;i++)
+ for (unsigned int i=0;i<n_osc;++i)
delete [] pfactor.fm[i];
delete [] pfactor.fm;
}
@@ -99,7 +99,7 @@ program_t& program_t::operator=(const program_t &that)
this->cleanup();
- for (i=0;i<(sizeof(controller_affects)/sizeof(*controller_affects));i++)
+ for (i=0;i<(sizeof(controller_affects)/sizeof(*controller_affects));++i)
this->controller_affects[i]=that.controller_affects[i];
this->formula=that.formula;
this->n_osc=that.n_osc;
@@ -126,7 +126,7 @@ program_t& program_t::operator=(const program_t &that)
memcpy(this->pfactor.freq_env_amount, that.pfactor.freq_env_amount, sizeof(param_factor_t)*n_osc);
this->pfactor.fm=new param_factor_t* [n_osc];
- for (i=0;i<n_osc;i++)
+ for (i=0;i<n_osc;++i)
{
this->pfactor.fm[i]=new param_factor_t [n_osc];
memcpy(this->pfactor.fm[i], that.pfactor.fm[i], sizeof(param_factor_t)*n_osc);