From 65fe359eb034d8e4a4a7f4d673af6f473ef27ff8 Mon Sep 17 00:00:00 2001 From: Florian Jung Date: Sun, 9 Jan 2011 13:06:58 +0100 Subject: envelope_update_frames can now be set via CLI and config file --- synth/cli.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'synth/cli.cpp') diff --git a/synth/cli.cpp b/synth/cli.cpp index 376edc3..eb52c95 100644 --- a/synth/cli.cpp +++ b/synth/cli.cpp @@ -44,6 +44,8 @@ void parse_args(int argc, char** argv) {"max-portamento-time", required_argument, 0, 303}, {"filter-update-freq", required_argument, 0, 305}, {"lfo-update-freq", required_argument, 0, 306}, + {"env-update-freq", required_argument, 0, 307}, + {"envelope-update-freq", required_argument, 0, 307}, {"no-connect-audio-out", no_argument, 0, 'a'}, {"no-connect-audio", no_argument, 0, 'a'}, {"dont-connect-audio-out", no_argument, 0, 'a'}, @@ -164,6 +166,14 @@ void parse_args(int argc, char** argv) else output_warning("WARNING: not a number in --lfo-update-freq option. ignoring it..."); break; + case 307: if (isfloat(optarg)) + if (atoi(optarg)<=0) + output_warning("WARNING: envelope-update-freq must be positive. ignoring it..."); + else + envelope_update_freq_hz=atof(optarg); + else + output_warning("WARNING: not a number in --envelope-update-freq option. ignoring it..."); + break; default: cout << "ERROR: invalid command line options. try the --help switch" << endl; exit(1); -- cgit v1.2.3