Replies: 3 comments 2 replies
-
Well, I'm not really convinced. The original use-case in #1214 was described as:
So essentially what happens in your proposal is that Instead, the modulator would indeed result in a sudden increase of the release time whenever CC64 becomes >64, highly depending on the amount that was given for that modulator, which you have left unspecified. So if that's the solution you're looking for, you're free to specify those modulators. The need for this |
Beta Was this translation helpful? Give feedback.
-
Hello @derselbst
This doesn't seem to make sense, but... When the pedal is depressed, the modulator adds 4s to the release time.
I didn't specify the amont value because each instrument can use different values. In this example amont value is 4800.
The idea is to use the pedal to increase the release time using the modulator. While the notes are in sustain, the effect of increasing the release time does not occur. If I release the pedal, the voice enters the release phase, but the modulator also returns the release time to the initial phase, in our example 0.3 s. That's why I suggested creating the In addition to the expected effect, we have doubled the creative ability to create sounfonts. It would be grand! |
Beta Was this translation helpful? Give feedback.
-
SUSTAIN STUFSHello @ybungalobill, @derselbst, @cghawthorne, @atsushieno I still think we should continue trying to achieve the result with the sustain pedal. The idea is to increase the release time using the sustain pedal, making the voice have a smooth fall, a kind of fadeout, so that it doesn't sound indefinitely. In some situations, we can also use the sustain pedal to function as a sostenuto.
NOTE:We do not check the flags because the index values (64, 65, 66, 67,68, 69) do not have correspondences in the General Controller, therefore, these will be Continuous Controller. see SF Specs 8.2.1 Source Enumerator Controller Palettes. As a stuck crit I suggest using: A. source1 = CC64 (Sustain switch) and source2 = CC69 (Hold2_switch) and target VolEnvRelease to ignore sustain B. source1 = CC64 (Sustain switch) and source2 = CC66 (Sostenuto_switch) and amount = 0 to function as sostenuto Logically, the soundfont programmer should use direction 1 in the second source:
insert influid_voice.c void fluid_voice_noteoff(fluid_voice_t *voice)
|
Beta Was this translation helpful? Give feedback.
-
I propose to use the sustain pedal to increase the release time using a modulator.
Would be like this:
When the synthesizer reads the modulators and checks for a modulator using source1 == CC-64 and destination volume envelope release, then it would mark the voice to cancel the hold effect.
This way we can have two types of presets with the same instrument:
one instrument would hold the notes until the pedal is released and another would just increase the release time.
With the release time increased, the effect mentioned by @ybungalobill would be achieved.
We would also have guitars, organs and strings that would be tuned.
It will be nice to use piano with pads and strings, like on a real keyboard. (I use a Yamaha PSR-SX900).
This would be similar to using Sustain as a soft pedal without having to use routers, as the modulators are already present in the soundfont.
This is functionality that fluidsynth lacks.
In the SF2 specifications 1.5 Future Enhancements to the SoundFont 2.
The SoundFont 2 standard is designed to allow for enhancements based on future wavetable synthesis
technology capabilities by additional enumerations of generators and modulators.
Note that this change does not need to be made to the soundfont, as it already has modulators.
It only needs minor synth changes.
How I think this:
(fluid_voice.h) struct _fluid_voice_t add:
char cancel_default_hold;
(fluid_voice.c) fluid_voice_calculate_runtime_synthesis_parameters: (Add in line 607)
voice->cancel_default_hold = 0;
While adding the modulators, check if one of them meets the criteria:
if it meets the criteria, we mark the cancel_default_hold parameter as true:
(fluid_voice.c) fluid_voice_calculate_runtime_synthesis_parameters (add in line 615 inside the for structure):
if(mod->src1 == SUSTAIN_SWITCH && mod->dest == GEN_VOLENVRELEASE)
{
VOICE->cancel_default_hold = 1;
}
in the noteoff event, we hold the notes only if the cancel_default_hold parameter is false:
(fluid_voice.c) fluid_voice_noteoff check condition for hold the voice (change line 1367)
else if(fluid_channel_sustained(channel) && voice->cancel_default_hold == 0)
{
voice->status = FLUID_VOICE_SUSTAINED;
}
Dear @derselbst, please check these proposed changes.
Thanks.
Beta Was this translation helpful? Give feedback.
All reactions