Subject:programmatically set parameters
Posted by: JimEE
Date:8/29/2013 3:03:38 PM
I am trying to create a C# script to generate a sine wave. I have used one of the example scripts to create the framework using the "Simple Synthesis" effect. The example however, displays a dialog box for the user to select the parameters for creating the sine wave or allows the user to select preset. How do I programmatically, in C#, set the parameters such as Start Frequency, End Frequency, Length, etc? Thanks, Jim |
Subject:RE: programmatically set parameters
Reply by: roblesinge
Date:8/29/2013 4:22:32 PM
Can you post your code in some code tags? You may have to create a preset and then pass that preset into the Synthesis effect using DoEffect or something like that. Rob. |
Subject:RE: programmatically set parameters
Reply by: JimEE
Date:8/30/2013 8:33:49 AM
|
Subject:RE: programmatically set parameters
Reply by: JimEE
Date:8/30/2013 8:40:21 AM
I am really hoping to not use a preconfigured (vs created on the fly by the script) preset for two reasons. I really want the C# function to be fully self contained and not have any dependencies. I also don’t want to manage converting the presets to newer SF versions as they become available. There are quite a few wave forms I am trying to create, so I’d rather not have a huge library of presets to manage. Jim |
Subject:RE: programmatically set parameters
Reply by: roblesinge
Date:8/30/2013 9:36:53 AM
Jim, Unfortunately, I don't think you can access the fields in the Simple Synthesis dialog to create a preset on the fly. I'd recommend you investigate creating Sine waves on your own. Check out the "Generate a tone.cs" or "Generate a constantly falling tone.cs" in the SDK sample scripts. Or just Google how to do it and implement the algorithm in a SF script. Rob. |
Subject:RE: programmatically set parameters
Reply by: JimEE
Date:9/3/2013 9:25:15 AM
Thanks! |