• WANTED: Happy members who like to discuss audio and other topics related to our interest. Desire to learn and share knowledge of science required as is 20 years of participation in forums (not all true). Come here to have fun, be ready to be teased and not take online life too seriously. We now measure and review equipment for free! Click here for details.

Asking for input on a VST Harmonic Distortion plugin

Would you like a VST plugin to tune in an arbitrary amount of harmonic distortion?

  • Yes, I'd love such a plugin and I'm willing to pay for it

    Votes: 10 45.5%
  • Yes, I'd like to play with it but only if it's free

    Votes: 8 36.4%
  • Yes, but I don't use Windows

    Votes: 1 4.5%
  • No, I couldn't care less about adding any amount of distortion to my system

    Votes: 3 13.6%

  • Total voters
    22

pozz

Data Ordinator
Forum Donor
Editor
Joined
May 21, 2019
Messages
3,746
Likes
5,862
The other thing I was going to mention was to perhaps focus on envelope as much as harmonic spectrum. My interpretation is that the former is actually more important perceptually.
By envelope do you mean controlling onset of a distortion profile by defining an amplitude threshold and attack/sustain/release times? The next logical step would be allowing frequency specific bands as well.

FX envelopes can be specified (somewhat) by mapping the VST settings through MIDI to the built-in automation of the DAW as well.
 

andreasmaaan

Master Contributor
Forum Donor
Joined
Jun 19, 2018
Messages
6,652
Likes
9,119
Aren't the various EQ plugins already doing exactly this? Here are a few that came up at the top of my search, don't know anything about them:

https://www.musicradar.com/news/the-best-vst-eq-plugins-2020-the-finest-equalisers-for-your-daw

These dynamic EQs essentially act as narrowband compressors, so yes, there must be nonlinear distortion produced as a byproduct.

But what I had in mind was more akin to saturation than compression, that is, distortion that rises in percentage and/or harmonic order as the level of the signal rises.

Does that make sense?
 

andreasmaaan

Master Contributor
Forum Donor
Joined
Jun 19, 2018
Messages
6,652
Likes
9,119
By envelope do you mean controlling onset of a distortion profile by defining an amplitude threshold and attack/sustain/release times? The next logical step would be allowing frequency specific bands as well.

FX envelopes can be specified (somewhat) by mapping the VST settings through MIDI to the built-in automation of the DAW as well.

Yes, this would take it even further than the mere saturation-type distortion I described in the previous post.
 
OP
pkane

pkane

Major Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
2,496
Likes
4,063
Location
North-East
These dynamic EQs essentially act as narrowband compressors, so yes, there must be nonlinear distortion produced as a byproduct.

But what I had in mind was more akin to saturation than compression, that is, distortion that rises in percentage and/or harmonic order as the level of the signal rises.

Does that make sense?

I think compression works that way, also, if I understand what you're asking. The transfer curve is what defines at what signal level the distortion changes. Here's signal at 0db level with a compressor:

1607531174794.png



And here's the same transfer curve, but with a -10dB signal:

1607531271959.png
 

andreasmaaan

Master Contributor
Forum Donor
Joined
Jun 19, 2018
Messages
6,652
Likes
9,119
I think compression works that way, also, if I understand what you're asking. The transfer curve is what defines at what signal level the distortion changes. Here's signal at 0db level with a compressor:

View attachment 98229


And here's the same transfer curve, but with a -10dB signal:

View attachment 98231

Yeh, absolutely. The thing with a compressor is that, kinda as @pozz described in his post above, there are configurable settings for attack, release and threshold etc.

Moreover though (and more importantly IMO), the only harmonics added to a signal under compression will be odd-order.

What I had in mind was more akin to saturation, i.e. the effect I described a couple of posts back.
 

lashto

Addicted to Fun and Learning
Forum Donor
Joined
Mar 8, 2019
Messages
581
Likes
296
Just as an update, I've started work on a VST plugin. I have plans for a few other plugins that I'd like to build for myself, so this will be the first in a series.

This is designed for Windows, so I'm not sure how or if it'll run on any other platform. Still a lot of work remaining, and a lot of testing, but the basic plugin appears to be functional. I'm tentatively calling it PKHarmonic, and have not decided on any commercial considerations (price, if any, distribution, etc.) Here's a screen shot of it working inside JRiver:

View attachment 98216

And here's JRiver output playing 1kHz sine wave file using PKHarmonic plugin, captured by REW:
View attachment 98218
That already looks production-ready :)
I would rotate the sliders 90 degrees. Vertical sliders should look more intuitive (will look ~like the THD graph)
PKHarmonic is a pretty good name too. Maybe try PKHarmonizer, with a bit more 'commercial ring'
 

paulraphael

Active Member
Joined
Dec 18, 2020
Messages
223
Likes
325
Location
Brooklyn, NY
How hard is it to release something like this in other plugin formats (like Audio Units) after you've built it?
 

KSTR

Major Contributor
Joined
Sep 6, 2018
Messages
1,453
Likes
3,014
Location
Berlin, Germany
VST plug sure is a nice and very convenient starting point, thanks for all your effort.
As for other formats to add later, maybe simple command line filter versions (linux/win, 32/64bit) reading from stdin and outputting to stdout? That would very standalone and universal, plus no special libraries needed if one would restrict the I/O-format to plain (stereo) array of double. Together with SoX to prep input and final outputs format that would be a killer solution.

Just thinking out loud here for future options, would there be a away to make the distortion dynamic via a side-chain "DC" input (at the same sample freq) whose value is used to do linear morphs between distortion characteristics? Two of those "operating points" A and B would suffice for a start. My motivation for this is that I've always found a truly static distortion per simple lookup-table from generated polynoms, time-invariant, is way more tolerable than one that wanders around with the signal and its history in some way (notably speaker do this). Static distortion sure adds "roughness" and compression or peaking but the mechanism for it is as stable in itself as it gets, and I have a feeling our hearing can more easily tolerate this.
 
OP
pkane

pkane

Major Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
2,496
Likes
4,063
Location
North-East
How hard is it to release something like this in other plugin formats (like Audio Units) after you've built it?

AU will require a complete rewrite for Core Audio/Apple, so not an easy task since most of the libraries and code I've written is for Windows. Not impossible, but unlikely given the amount of effort needed.
 
OP
pkane

pkane

Major Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
2,496
Likes
4,063
Location
North-East
VST plug sure is a nice and very convenient starting point, thanks for all your effort.
As for other formats to add later, maybe simple command line filter versions (linux/win, 32/64bit) reading from stdin and outputting to stdout? That would very standalone and universal, plus no special libraries needed if one would restrict the I/O-format to plain (stereo) array of double. Together with SoX to prep input and final outputs format that would be a killer solution.

Just thinking out loud here for future options, would there be a away to make the distortion dynamic via a side-chain "DC" input (at the same sample freq) whose value is used to do linear morphs between distortion characteristics? Two of those "operating points" A and B would suffice for a start. My motivation for this is that I've always found a truly static distortion per simple lookup-table from generated polynoms, time-invariant, is way more tolerable than one that wanders around with the signal and its history in some way (notably speaker do this). Static distortion sure adds "roughness" and compression or peaking but the mechanism for it is as stable in itself as it gets, and I have a feeling our hearing can more easily tolerate this.


Very good ideas, @KSTR ! What format should the stdin/stdout data be? WAV file or just straight binary samples? Not sure what other utilities of this type might normally use as input/output.

As to a side-chain control channel... Sure, that might work, but a dynamic distortion is often frequency and/or level related, I think a more sophisticated control channel might be needed. I've thought about it, but have not come up with the right approach yet :)
 
OP
pkane

pkane

Major Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
2,496
Likes
4,063
Location
North-East
The VST plugin is fully functional, but requires a bit of work to make into a released product. I'm having problems packaging it into an installable setup, as it's using some very recent versions of .NET and other libraries. That's the price I'm paying for using the latest, just released components :)

1609702042438.png
 

KSTR

Major Contributor
Joined
Sep 6, 2018
Messages
1,453
Likes
3,014
Location
Berlin, Germany
Very good ideas, @KSTR ! What format should the stdin/stdout data be? WAV file or just straight binary samples? Not sure what other utilities of this type might normally use as input/output.
I would think a plain headerless binary format would work best. 64bit floating point would apply, to have headroom in computation precision as well as the ability to process samples larger than 1.0 in absolute value, etc. Single channel would suffice the more I think about it.
I mentioned the SoX tool in the previous post as it would remove any input/output format considerations, sample rate, channel count, .... SoX would be use to extract -- and maybe even pre-process -- a channel of audio from a *.wav (or flac, or any input SoX supports) and spit it out as doubles into your distortion engine and the outputs again would be combined and formatted with SoX. So the distorter command-line tool could be extremely simple in structure, the distortion parameters could be simply passed as command line arguments.
 

Peter A

New Member
Joined
Sep 9, 2021
Messages
3
Likes
7
I am interested in a Mac version of the plugin. Always willing to pay for the effort. I intended to build a second harmonic distortion generator in hardware, just to analyse the effect on my 'clean and honest' NC400 based system
 

sarumbear

Major Contributor
Forum Donor
Joined
Aug 15, 2020
Messages
1,400
Likes
1,167
Location
Southampton, UK
Hey folks, asking for your feedback in an informal poll.

If you know about my DISTORT software (https://distortaudio.org) you know that it allows an arbitrary harmonic distortion to be constructed and applied to any test signal or a music track of your choice.

Some have used this capability and liked the sound of certain distortions. It's been suggested that this functionality of applying configurable harmonic distortion to real-time playback using a VST plugin might be useful. Some are even willing to pay to get the ability to configure an arbitrary amount of second and/or third harmonic to their music. And all that without having to pay for a tube preamp, which could run into many thousands of dollars :)

Question I'd like to pose here (vote in the poll or answer in a post, or both) would you be interested in such a plugin, if yes, is this something you'd be willing to pay for, and if interested, what VST host/app would you use it with, and what version of Windows?

If you have an interest in such a plugin, what other functionality would you like to see in it, other than tuning-in the desired level of second/third/fourth/... harmonic?
I am not interested whatsoever but here is the standard go to plugin the professional audio world. The name of the plugin says it all :p

 
OP
pkane

pkane

Major Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
2,496
Likes
4,063
Location
North-East
I am not interested whatsoever but here is the standard go to plugin the professional audio world. The name of the plugin says it all :p


You let me know just in time :) The plugin has been available since the beginning of the year.

Wonder if you can dial in specific harmonics by their dB values in Trash 2...
 
OP
pkane

pkane

Major Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
2,496
Likes
4,063
Location
North-East
I am interested in a Mac version of the plugin. Always willing to pay for the effort. I intended to build a second harmonic distortion generator in hardware, just to analyse the effect on my 'clean and honest' NC400 based system

Unlikely to happen any time soon, I'm afraid. Until I find a reason to build another plugin for the Mac, PKHarmonic will remain Windows-only.
 

sarumbear

Major Contributor
Forum Donor
Joined
Aug 15, 2020
Messages
1,400
Likes
1,167
Location
Southampton, UK
Wonder if you can dial in specific harmonics by their dB values in Trash 2...
I expect so, but I have not used the plugin, hence mine is assumption.
 
OP
pkane

pkane

Major Contributor
Forum Donor
Joined
Aug 18, 2017
Messages
2,496
Likes
4,063
Location
North-East
I expect so, but I have not used the plugin, hence mine is assumption.
I'd love to know, but would not assume so. Music production/recording scene doesn't usually deal with individual harmonics, that's more of an engineering purview... oh, and maybe that of the audiophiledom.
 

sarumbear

Major Contributor
Forum Donor
Joined
Aug 15, 2020
Messages
1,400
Likes
1,167
Location
Southampton, UK
I am interested in a Mac version of the plugin. Always willing to pay for the effort. I intended to build a second harmonic distortion generator in hardware, just to analyse the effect on my 'clean and honest' NC400 based system
Izotope Trash 2 is Mac and Windows compatible.
 
Top Bottom