summaryrefslogtreecommitdiff
path: root/synth/parser.cpp
diff options
context:
space:
mode:
authorFlorian Jung <flo@thinkpad.(none)>2011-01-15 17:35:25 +0100
committerFlorian Jung <flo@thinkpad.(none)>2011-01-15 17:41:03 +0100
commit65381f7f64aacad7023b74c3f20293e8eca5fa22 (patch)
treee97756eeff8d15e3525a8969b1ae8b7a1aa02498 /synth/parser.cpp
parent550497e9b09894a79c1c9888901bbbf4949a614b (diff)
Added pfactor-influence for freq_env_amount
Diffstat (limited to 'synth/parser.cpp')
-rw-r--r--synth/parser.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/synth/parser.cpp b/synth/parser.cpp
index a6f27cb..cd4ed02 100644
--- a/synth/parser.cpp
+++ b/synth/parser.cpp
@@ -238,6 +238,7 @@ void init_filter(filter_params_t &filter)
void init_pfactors(int n_osc, pfactor_formula_t &pfactor)
{
pfactor.out=new param_factor_t [n_osc];
+ pfactor.freq_env_amount=new param_factor_t [n_osc];
pfactor.fm=new param_factor_t* [n_osc];
pfactor.filter_env.offset=ONE;
@@ -254,6 +255,9 @@ void init_pfactors(int n_osc, pfactor_formula_t &pfactor)
pfactor.out[i].offset=0;
pfactor.out[i].vel_amount=ONE;
+ pfactor.freq_env_amount[i].offset=0;
+ pfactor.freq_env_amount[i].vel_amount=ONE;
+
pfactor.fm[i]=new param_factor_t [n_osc];
for (int j=0;j<n_osc;j++)
{
@@ -611,6 +615,10 @@ program_t parse(string fn)
case FILTER_OFFSET:
pfactor.filter_offset=parse_pfactor(strval);
break;
+
+ case FREQ_ENV_AMOUNT:
+ pfactor.freq_env_amount[ind]=parse_pfactor(strval);
+ break;
default:
throw string("velocity cannot influence parameter '"+array+"'");