View Single Post
Old 04-17-2020, 02:37 PM   #263
Hermenator
Human being with feelings
 
Join Date: Apr 2020
Posts: 5
Default

Hi Time Waster,

Making Music, ah, that's what its all for, isn't it!?

Sure you can use the code, glad to be of help! In the attached file I've changed the bit for resonance/sweep too. It produces the same harmonics as your original. If you decide you do need lower harmonics, there are some comments in the code about what to remove.

As for the DC offset of the Pulse wave: I think it depends on what you consider 'zero DC content'. I meant it as in 'The sum/average of the signal over time to be zero', wheras you seem to mean 'The sum/average of the min and max signal to be zero'. A quick search on the web revealed only one source shedding some light on the issue: A book called "Designing Software Synthesizer Plugins in C++" by Will C. Pirkle. Link to Google Books: (see p207-p208)
https://books.google.nl/books?id=oaY...0offset&f=true

However, following my interpretation, the disadvantage of 'zero dc-offset' is that the min/max signal will clip sooner, which is also not good in a digital environment. And, since the trapezium wave follows the same logic, let's just leave it as you suggested. One can always use the 'dc remover plugin' in Reaper.

I agree with you that the standard JSFX UI is very, very limited. If only we had checkboxes, buttons, knobs and vertical sliders, one could be much more screen-space efficient. To make buttons, I often use the triggers, but they don't have a label, so no one else knows what they do if they don't read the manual
Tip: Instead of making yet another slider, a suggestion would be to make a variable 'FULL_RESOLUTION' in the file, which the user could set to 1 or 0 (and is by default what you intend it to be). (They WOULD have to read the manual, of course

Another thing, if you don't need the resolution but you don't want the steppiness, you can have an integer slider, but smooth its value in @sample, like
Code:
 val += 0.01*(slider1-val);
or linearly, like I have seen in your code. Bottom line, you don't need 44100 control values per sec to have sample smooth control, in my opinion. But I must admit I'm only just starting with synth programming, and I bet other people have other wishes. I'm going to do a lot of reading in over the next few days, and let my thoughts dwell on the issues you mention. An interesting source I've found so far is VCV Rack: https://vcvrack.com/

Even if you don't download the software (free), its manual is a good read. The software itself may give you some ideas about the desired level of modularity. My ideal synth would be the freedom of VCV Rack without the spaghetti of the patch-cables. In Reaper, these cables are hidden as audio or MIDI signals, just waiting to be used for whatever we wish them to be.

Rounding up now. Have fun making music!
Regards,

Hermenator

PS: The note scope you made is pretty awesome! I use it all the time to compare my mod against you original. One little thingy: It displays the wave upside down compared to the scope in the oscillator (you can notice with a Pulse wave with pw>0.5)
Attached Files
File Type: txt TimeWaster_ReaRack2 Oscillator-Additive Mod.txt (17.8 KB, 184 views)
Hermenator is offline   Reply With Quote