2

LilyPond documentation lists several different drum notation styles (like agostini, weinberg).

These are to be selected by setting the drumStyleTable in context DrumVoice. I would like to use the weinberg-drums-style.

I am currently using the shorthand \drums command, instead of \new DrumStaff.

Where exactly should I put something like:

\set DrumStaff.drumStyleTable = #(alist->hash-table weinberg-drums-style)

And what would be the most convenient syntax?

I've seen different examples in the Cookbook, the documentation, and the mailing lists but had no luck so far using any of those with v2.23.12.

I would like to stick with the \drums syntax, if possible.

2 Answers 2

1

Place the \set command inside the block it is referring to.

But, you don't need to call a hash-table explicitly because you aren't using a custom drumStyleTable; theweinberg-drums-style is predefined.

So you should get something like this:

\drums {
    \set DrumStaff.drumStyleTable = #weinberg-drums-style
        bd4 hh sn hh |
}

which is equivalent to:

\new DrumStaff {
    \set DrumStaff.drumStyleTable = #weinberg-drums-style
    \drummode {
        bd4 hh sn hh |
     }
}
3
  • 2
    More precisely, it's equivalent to \new DrumStaff \drummode { \set ... }, with \set inside drum mode. It doesn't matter in this example, but if the value the property is being set to is something like a drum name, it can matter. Aug 31, 2022 at 18:20
  • @ABOUSAMRAJean - really? Okay, good point. Aug 31, 2022 at 18:27
  • Excellent! Thank you! So simple. I obviously missed something in my experiments. Embarrassingly, I'm the one who implemented the weinberg style but never knew how to activate it and kept using my custom definition file until I finally found some time to convert the sheets. Sep 1, 2022 at 9:55
2

Since you appear to want this as a global setting, you'd place it in the respective \layout block, such as:

\layout {
  \context {
    \DrumStaff
    drumStyleTable = #(alist->hash-table weinberg-drums-style)
  }
}

Indeed, your statement can actually also be used directly there as:

\layout {
  \set DrumStaff.drumStyleTable = #(alist->hash-table weinberg-drums-style)
}

but the meaning is subtly different since this variant will also affect all contexts that contain an \alias "DrumStaff" declaration.

1
  • How many individual drum kits are you scoring for? Sep 1, 2022 at 18:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.