Circumvent Fluidsynth Pitch Adjustment (Play Same Pitch on with Two Different Key Assignments)
System setup:
OS: Windows 10 (10.0), Arch.: x86_64, MuseScore version (64-bit): 3.5.2.311459983, revision: 465e7b6
Attachments: (zip file inclusions)
instruments_pb.xml
PB_Soundfont.sf2
Test_for_left_right_pitch_match.mscz
References:
https://musescore.org/en/node/86526
https://github.com/FluidSynth/fluidsynth/issues/26
https://musescore.org/en/node/87066
Background: in pipe bands, drummers use the berger uniline system is used to indicate sticking (right above and left below the line) on a uniline staff.
I have previously hacked this for snare drum playback by using two different drums for left and right. Pitch is imprecise so it works fine until I record a better sample to use.
Now, I've made a custom soundfont for pitched tenor drums (used both in bass clef for multi-voice and uniline for solo) and on a uniline staff, I'm trying to circumvent fluidsynth pitch adjustment and make both notes played by both left and right hand to sound the same in playback.
The test file (Scale Tune Test 1.mscz) in the thread below works correctly
https://musescore.org/en/node/87066
with the included soundfile from that thread (Scale Tune Test 1.sf2)
So it is probably not a Fluidsynth issue and something I'm not doing right.
Things I've tried:
- Setting Scale tuning to 0 in instrument and preset (no change)
- Setting root key to 60 and scale tuning to zero (no change)
- Changing the tuning of one of the notes to lower by 1 semi-tone in the soundfont instrument setting (no change)
- Changing the keys that are used for the notes - adjusted in only sount font (no change)
- Changing the keys that are used for the notes - adjusted in sountfont and instruments file (no change)
- Duplicating the sample, lowering pitch on new sample, adding new sample as right hand (key 56). (no change)
- Copying the preset from Scale Tune Test 1.sf2 into my sound file and replacing the sample with my own sample (result: notes sound different when they should sound the same).
My test file is Test_for_left_right_pitch_match.mscz
The PB Solo Tenor custom instrument is the one I'm trying to improve.
PB Tenors (bass staff) is for pitch comparison: the solo tenor should match the A2 pitch on the PB tenors staff. These notes should all play back at the same pitch when I get this working.
Attachment | Size |
---|---|
PB4Musescore v2.0.zip | 1.61 MB |
Comments
I might be overlooking something, and I'm likely not giving the answer you were hoping for, but here goes:
If all you're looking for is a way to have a snare drum berger uniline staff, then consider the following:
Fix to line
" option underNote
in the Inspector and give it a value of-1
If done correctly, pasting the notehead will not change the duration of the already entered notes. As both notes above and below the staff are still the same pitch and only visually displaced; playback will use the same sound for them.
In reply to I might be overlooking… by jeetee
Thanks so much for your response. I've already solved it for snares by editing the drumset to link -1 to one type of snare sound (marching I think: drumpitch=38) and +1 to another (electronic drumpitch=40). For Tenor (and Bass) drums, though, doing the same thing (two different samples) results in them being re-tuned a whole tone apart.
I'm going to look into your suggestion for tenor drums (pitched, but on berger uniline and with a custom soundfont). Ideally I want to write a plugin to do what you've suggested, since I typeset a lot of complex music on uniline staves and I'm trying to set up a process that's straightforward for the band members that I teach to use themselves when they are typesetting things.
Ideally I'm hoping there is a way to make it "just work" since there must be an adjustment I can make in the soundfont (or the instrument.xml file?) to stop fluidsynth from re-tuning the sample it plays.
In reply to Thanks so much for your… by Kate.Dudek
> "Now select that notehead again. Make sure you select only the notehead, so no blue rectangle!"
And copy it (was missing from the instruction)
In reply to > "Now select that notehead… by jeetee
nod. thanks
.
I have solved this issue. I'm actually not 100% certain what the issue was, but I was fiddling with tuning in my soundfont, and then when I tested it in musescore (didn't work), my A3 tenor drum note still wasn't working, but I impulsively decided to try using the instrument/preset I had set up previously for E2. To my surprise, the left and right (above/below the line) notes matched - it behaved as expected.
So I duplicated that instrument and preset and replaced the sample with my A3 sample (kept scale tuning = 0), and the result was the pitch was the same within the instrument, but a semitone flat (transposition required because this in bagpipe key - bagpipe is a Bb instrument in musescore).
So, I set tuning (semi-tones) to 1, and this solved the issue.
Thanks to everyone for reading and supporting and hopefully this helps someone in the future.