-
Notifications
You must be signed in to change notification settings - Fork 245
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
Sequencer event ordering is broken for NoteOn vel=0 events #907
Comments
Since 2.2.0 events that share the same tick are ordered in a special way, see docs of fluid_sequencer_send_at(). This ordering currently considers NoteOn Vel=0 events as real NoteOns by mistake. NoteOns with velocity=0 are always treated as noteoff by the synth. There is more than one way to fix this, I'll need to think about it. |
I think the best way would be to make |
Implemented in #908, feel free to test. |
Thanks for the fix.
I understood that the order of events that have the same timestamp is undefined, but how do you think about 'on-off' effects such as Hold? I wonder that, there may be the case that Hold-off event is followed by Hold-on event with the same timestamp, which assumes it resets sounded notes and turn hold on again at the same time. (If it is a rare or not so good case, the current behavior would be fine.) |
By "hold-event" you mean regular Sustain and Sostenuto events? If yes: Just like other CC events, if you want them to be applied in a special order to achieve a special effect, you would need to use different ticks. |
Yes.
I understood. Thanks for the reply. |
FluidSynth version
(commit hash: 17fb48d )
Describe the bug
With using sequencer (
fluid_sequencer_t
), when sending 'Note on' event immediately after (i.e. same tick of) 'Note on with velocity = 0' event, the first 'Note on' event may sound nothing.Expected behavior
'Note on' should always sound in that case
Steps to reproduce
I attached reproduce source code: main.cpp.zip
(I used VintageDreamsWaves-v2.sf2 Soundfont on reproduce.)
Extract
main.cpp
, build withgcc -o main main.cpp libfluidsynth.a -lglib-2.0 -lstdc++ -lm -fopenmp
, and execute./main
.The WAVE file
out.wav
is generated and it may play something weird sound.Additional context
The text was updated successfully, but these errors were encountered: