-
-
Notifications
You must be signed in to change notification settings - Fork 69
Smoothers and smoothcc
#181
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
Conversation
Can you elaborate on what is the distinction between log and linear? Also why's not simplest form of LPF not adequate, and why it's needed to tabulate the power function? (given smoothcc is supposed to be fixed?) (sorry for lots of questions) |
As a remember when things are working, xfin_smoothccXX and xfout_smoothccXX would be great, even though they are not supported by LinuxSampler (which arguably is the most complete implementation on Linux to date), and maybe even not by ARIA/Sforzando. |
edited out @FrnchFrgg this is linked to #22, and I added a gain smoother here which has this function more or less, but having smooth crossfades is one of the goal of this PR 🙂 |
I don't find the filter to match to the RE'd specification. |
This formula matches it exactly.
|
No I was planning to check it out now so thanks :) |
In the end it should reduce to this:
|
Yes; in addition you can group all constants together.
Do we need to tabulate this? I thought the smoothcc are set once and never changed. |
Well the filters belong to the voices, so the have to adapt to the currently played region for all |
If I understand this correctly..
None of these belong to DSP processing, hence why care to save a small fraction of processing time? |
No, it's changed when starting a voice, but I'll remove it and benchmark later if this creates problems. |
Feel free to cherry-pick 272b195, a test jack client |
7dae185
to
7dfb98b
Compare
You can use this to do further work on modulation if you wish. |
src/sfizz/Voice.cpp
Outdated
|
||
const auto events = resources.midiState.getPitchEvents(); | ||
const auto bendLambda = [this](float bend) { | ||
return region->getBendInCents(bend); |
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.
@paulfd, I'm trying to rebase this.
This function name is misleading. It returns a factor not cents.
Move modifiers and their helpers in their own files Add an enum class for modifiers and facilities to iterate over all possible targets Add smoothers to the voices and preallocate them Iterate over smoothers and modifiers jointly in the voices for each target
I seem to have trouble with the following patch. When smoothcc is set and the note is keyed on, pan is going to start at the right and it will take a delay until the pan value establishes itself at center.
|
I have no computer to try this until tomorrow, sorry. You mean that the value always start on the left on key presd even though the cc value is not changed?
If so it's a problem, it means the panning value does not properly query the CC state at some point yeah.
Jun 20, 2020 17:25:29 JP Cimalando <notifications@github.com>:
… I seem to have trouble with the following patch.
It's set to control panning left and right using a midi controller change.
When smoothcc is set and the note is keyed on, pan is going to start at the right and it will take a delay until the pan value establishes itself at center.
<control> set_hdcc16=0.5 <region> sample=*sine ampeg_attack=0.02 ampeg_release=0.1 pan=-100 pan_oncc16=200 pan_smoothcc16=100—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub[#181 (comment)], or unsubscribe[https://github.com/notifications/unsubscribe-auth/ADUFWQM2TCFRHVALIQNTTY3RXTIFDANCNFSM4MG7ML5Q]. [https://github.com/notifications/beacon/ADUFWQJ5UMNW42ACOI7JWPTRXTIFDA5CNFSM4MG7ML52YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOE2IJIVQ.gif]
|
It appears the initialization of the filter which is incorrect. I 'll check it. |
The modulated unit has been changed to % after rebase, but the initialization had not followed. |
This implements a linear and multiplicative smoother, trying to match a reasonable mix of behaviors between ARIA and consorts. The linear smoother uses a VA one-pole filter. The smoothing cutoff is a function of the sample rate, and it is quantized/tabulated between a minimum (a smoothing value of 1 with the default sample rate at 48 kHz) to a maximum (a smoothing value of 100 with a max sample rate of 192 kHz). We'd have to evaluate if this is enough.
smoothcc
value and some tests.bend_smooth
opcodes and add a bend smoother for the pitch bend in the Voices.Closes #48, #22, #153