-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Distortion effect #10932
Distortion effect #10932
Conversation
This produces some compiler warnings on Ubuntu Focal:
|
Currently our skins are not well prepared for multi stage knobs. Did you consider to add two knobs for this? |
When cuing in the track I have a unwanted loud noise whenever playback starts. |
This is already a fun to play wit this effect. Thank you. Here some thoughts: Compared to this the "soft" using tanh is actually a hard clipping known from transistors. Some guitar player prefer an even softer clipping like coming from tubes. I think the easiest way to achieve this is to cascade more tanh. In classic stomp boxes they intentionally use slow op-amps that act like low pass taking away some of the the high pitch noise added in the current solution. Some have a tone knob to adjust that a bit. Did you consider to add something like this? I have chained a "Filter" effect after this effect. But the Filter stops working and the sounds stops after seeks. My guess is that this is a a bug in the filter effect triggered by this effect. Are you able to reproduce it? The folding effect sounds really crazy. But probably to noisy. |
What do you mean multistage? |
I cannot reproduce. Can you provide step-by-step instructions to reproduce it? |
I've tried this and it actually sounds a bit harsher to me! |
That's a good idea, but let's leave it for another PR. As a workaround you can already place a parametric EQ or filter before/after the distortion effect. |
:O no I couldn't |
I though that I could also ditch the folding algorithms and replace the mode selection with a continuous "shape" parameter that morphs from a super gentle soft curve to hard clipping. What do you think @daschuer ? |
Yes, that would be nice. |
I need to find time to reproduce my issue step by step. Mab it was a float NAN issue or such. |
@daschuer So I removed the folding algorithms, but I haven't implemented the continuous morphing between soft and hard clipping. I'd like to move one to other stuff and maybe implement this in the future. Is this anything else that need to be changed in this PR? |
I need to test again. Mandatory is that follow up effects do not breake. I assume it is cased by a none value that fades not out if the filter memory. |
Unfortunately the effect still produces nan values wen play after pause. I use this patch to visualize it:
output:
|
feenableexcept has proven very useful for debugging this. I think the issue is now fixed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, Thank you.
I implemented a simple distortion effect with 4 modes (or waveshapes).
The input is normalized to a predefined level for each waveshape in order for the action of the drive know to be independent of the level of the signal.
The output is also normalized by matching the rms of the output to the rms of the input. This output normalization can be improved, but I think it is usable enough for now.
There's also a one line fix for effect parameter push button right-click menu not updating the parameter.