6

I want the note beams to always be horizontal rather than skewed:

bass drum beams not being horizontal

This issue does not occur with snares:

sanre beams being horizontal

My code:

\version "2.24"

\header {
  title = "abc"
}

\drums {
  \clef percussion
  \numericTimeSignature
  \time 4/4
  \set DrumStaff.drumStyleTable = #weinberg-drums-style

  << {
    hh4 4 4 4
  } \\ {
    \stemUp
    \once\override Stem.length-fraction = #1.5

    bd8 8 sn4 s sn8 bd8
  } >>
}

2 Answers 2

6

If you just replace: \once\override Stem.length-fraction = #1.5
with: \override Beam.positions = #'(4.8 . 4.8)
... I think you'll get what you are looking for; all beams at the same height, without any slope.


But, I don't really understand why'd you want to write the notes that way.

  • You could use just a single voice in the code, and use "chords" (with < & >):

    \drums {
      \clef percussion
      \numericTimeSignature
      \time 4/4
      \set DrumStaff.drumStyleTable = #weinberg-drums-style
    
      \stemUp
      \override Beam.positions = #'(4.8 . 4.8)
      <bd hh>8 bd <sn hh>4 hh <sn hh>8 bd |
    }
    

    single voice for hi-hat, snare, and bass drum


  • Or, as you seem to want to coding the voices separately, actually keep the two voices seperate in the score:

    \drums {
      \clef percussion
      \numericTimeSignature
      \time 4/4
      \set DrumStaff.drumStyleTable = #weinberg-drums-style
    
      << 
          {
              hh4 4 4 4 |
          } 
          \\ 
          {
              bd8 8 sn4 r4 8 bd |
          } 
      >>
    }
    

    seperate voices: hi-hat as voice one, snare and bass as voice two
    (I find this much easier to read.)

5

I do agree with Element’s suggestion to either notate this properly the way you intend it using chords, or to keep multiple voices. Entering multiple voices as Chords is a bit tedious. Theoretically you are able to create chords like this \new DrumVoice \drummode << { bd4 bd } { hh4 hh } >> (this needs the explicit \new DrumVoice, this does not work with automatically created contexts!).

This is still a bit tedious since all voices need to have the same rhythm. When they do not the duration of the stem will be determined by the first note in the the current timestep. I’ve done some digging into this wrt. to your previous question, but it is a bit complicated to get this done more nicely.

But back to your original question: I’d advice against manually placing beam positions unless you really want to fine tune everything by hand (manual beam positions will require you to redo the layout if something changes). Rather tell Lilypond what you want. If you look here https://lilypond.org/doc/v2.24/Documentation/internals/beam you’ll see that Lilypond has a (not particularly well documented) dampening parameter for Beams. This parameter will dampend the Beam slope towards 0. So setting this to infinity will tell Lilypond to squash each beam slope to 0:

\version "2.24"

\header {
  title = "abc"
}

\drums {
  \clef percussion
  \numericTimeSignature
  \time 4/4
  \set DrumStaff.drumStyleTable = #weinberg-drums-style

  << {
    hh4 4 4 4
  } \\ {
    \stemUp
    \once\override Stem.length-fraction = #1.5
    \override Beam.damping = #+inf.0
    bd8 8 sn4 s sn8 bd8
  } >>
}

{
  c'8^"default" e' g' c''
  \temporary\override Beam.damping = #+inf.0
  c'8^"dampening" e' g' c''
  \revert Beam.damping
  \transpose c c, {
    c'8^"transposed down" e' g' c''
    \override Beam.damping = #+inf.0
    c'8 e' g' c''
  }
  \revert Beam.damping
  
  c'8^"Using beam positions instead" e' g' c''
  \temporary\override Beam.positions = #'(3 . 3)
  c'8 e' g' c''
  \revert Beam.positions
  \transpose c c, {
    c'8 e' g' c''
    \temporary\override Beam.positions = #'(3 . 3)
    c'8 e' g' c''
  }
}
3
  • One reason for wanting beams to always be horizontal is that a lot of bagpipe music is engraved like that.
    – Frotz
    Commented Dec 3, 2023 at 6:39
  • @Frotz Good to know, but did I in any way question the legitimacy of flat beams?
    – Lazy
    Commented Dec 3, 2023 at 11:24
  • Sorry, I meant to reply to @Elements in Space
    – Frotz
    Commented Dec 3, 2023 at 23:36

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.