Playback of slurred notes

• Feb 18, 2011 - 04:00
Type
Functional
Frequency
Many
Severity
S5 - Suggestion
Status
active
Regression
No
Workaround
Yes
Project

I know slur playback has been discussed before, and I gather it's better than in the past, but in my estimation, it's still the single biggest problem in the playback system. Especially in the trunk, which seems to add some nice new capabilities for controlling playback of various elements. I saw some of the previous discussion, and my impressions is that using the legato controller is the way to go here. Is that feasible? Does it depend on support for this in the specific soundfont being used?


Comments

Status (old) duplicate active

Unless you have some ideas on implementing these together, I would say these are *not* there same thing.

16887 is about the *length* of notes slurred versus not. But what I am talking about here isn't note length at all, it's the *attack* of each note. On wind instruments, non-slurred notes are produce using the tongue for each note: "ta-ta-ta-ta". Surred notes get a tongue on the first note only: "ta-ah-ah-ah". I believe the way this is implemented for at least some synths is to turn on the legato cotnroller after the first note on, which should cause the synth to suppress the "attack" portion of subsequent notes. Other implementations might actually switch to do a different set of samples for the slurred notes. I have no idea if fluidsynth supports either of these "out of the box" or if the soundfonts themselves need to be set up to support it, or if it's implemented at all, but that's how I've seen or heard of it working in other programs.

This isn't just winds, btw - it's also for strings. Non-slurred notes are normally played with a change of bow direction for each note: "down-up-down-up". You can mark the to all be played with a down bow, but that means a full stroke for each note, which actually makes them more detached as you have to take the bow of the string between each note to reset: "down (up) down (up) down (up) down". Whereas slurred notes would be played on a single bow motion: "doooowwwwnnnn". The effect on the sound is similar to what it is for winds: less attack, leading to smoother sound. There is not necessarily any difference in note length between down-up-down-up and dooowwwwnnnn; it's all about the attack.

Note length is good to get right too of course, but it's really separate from the note attack issue. This might sound like a subtle distinction, but it's really not. Hearing an eighth or sixteenth note line in winds played tongued sounds very unrealistic. my opinion remains as stated above: this is probably the single biggest issue remaining with MuseScore's playback, I'd rank this above playback of rit, for instance, since that at least can be faked. On the other hand, I have no idea is actually overlapping the notes on playback would create a convincing simulation of slurring, by "covering up" the attack a bit, and maybe that's what you had in mind?

BTW, a complicating aspect of this is that while slur marks in wind music virtually always are supposed to be interpreted as "don't tongue", slur marks in string music are also sometimes used to indicate phrasing in more or less the same way as in piano music. A string player can only play a small handful of notes on a single bow. So if you see a slur across two or three notes, it's a bowing instruction. But if you see a slur marked over two entire measures, you need to realize it isn't really telling you about bowing - you'll still need to bow notes individually or in smaller groups - but it is really telling you the same thing it is telling a pianist, which is more the subtle stuff about note length and the final note of the phrase in particular. I think what this means is that it should be possible for the user to turn off the legato controller effect for any given slur.

Status (old) patch (code needs review) active

I think the way you are proposing implementing slur playback for piano is very sound (although as noted elsewhere, I actually think this should be defeated by default - only users who ask to have non-slurred notes played non-legato should get that effect).

Unfortunately, this issue isn't about piano - it is about winds. Winds are totally different. Slurring for winds isn't a question of note length; it is a question of attack. Slurred notes should have no attack (or only a minimal one) - the tongue is not used.

My understanding is that sending a "legato controller on" message is supposed to achieve this in a synth. But I tried hacking this up once in rendermidi.cpp (replacing pedal on events with legato on) and nothing happened, so I gave up.

@Marc Sabatella > Legato mode...
for legato, in Midi (my version) : Mono Mode Required.

CC 5 (Portamento Time) : 0
CC 126 (Mono) On: 0 (Channel Mode Message; value is not important; Poly=Off, Mono On Switch )
CC 65 (Portamento On) : 127
... Slurred / Legato / Tenuto Notes Here ... (Attention: Minimum 1 tick overlap required.)
CC 65 (Portamento Off) : 0
CC 127 (Poly) On: 0 (Channel Mode Message; value is not important; Mono=Off, Poly On Switch )

result: after first note, just sustained part plays (no attack, no decay) for following notes.

in attachment: 1. normal playing, 2. legato playing, 3. Normal playing again.

Attachment Size
Legato2-.mid 349 bytes

In reply to by Marc Sabatella

I just saw this as I was looking up ways to get a real legato style guitar sound, and recall an earlier post I had made re: velocity.

I believe, and I could be misremembering, that velocity for a midi sound was always about the attack, and had nothing to really do with volume which is now unfortunately the case in far too many soundfont midi playback engines, including musescore. I remember, way back when I was running windows 98 and sonar 4 or 5? that I was able to get a great guitar legato sound with the midi keyboard (or mapping a regular lkeyboard with midi controllers), the wheel, and the velocity triggers. That was all it took. Turn the velocity of the attack down and VOILA! instant legato. The notes literally slurred together, as by the time the ear registered the sound it had smoothly risen in volume without the sharp attack that seems to haunt every single soundfont i've heard played back in musescore.

lets hope they get it right. Even at ppp levels on the piano, the attack is way too sharp and fast and there is almost no way to duplicate a really gently press on the keys, or a smooth legato run with hammer and pulloffs on the guitar.

In reply to by ptrtool1999

Piano doesn’t use single note dynamics, so it responds to velocity the old-fashioned way that was indeed common back in 1998 - it controls both the sample used (and hence the attack) as well as the volume. If the particular soundfont you are using does not sample ppp at differently than fff, you can simply try different soundfont that does.

In theory, those instruments that do support SND could take slur playback the way you describe - using a very low velocity to get the subtlest attack, then immediately ramping up the volume. Realistically, thats not all there is to slur on most instruments, I’m hoping to see a more sophisticated implementation for MuseScore 4.

In reply to by Marc Sabatella

thanks Marc. as usual, your replies are spot-on.

Ques - in your experience, which piano soundfont would you say comes closest to being able to replicate a gentle pressing of the keys while also not distorting if changing to, say, fff? Ive tried out the Salamander and one of the others, but I found a general distorted sound at higher volume levels.

Granted, there could be a way to mitigate using one of the built in effects, but i've not tried.

thanks - any advice much appreciated.

The default soundfont works well enough for me. I haven't really experimented with different soundfonts that much, so far I haven't found any general purpose ones that I like better overall than the default (well, except maybe the HQ variant), and managing different soundfonts for different instruments is more than I have time/patience for. Of course, as a developer, I'm constantly messing with my settings to try to reproduce various user-reported issues, and then wanting to easily get back to defaults, so I tend to just prefer defaults over anything that takes work to set up.