lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Avoid double beaming


From: Valentin Petzel
Subject: Re: Avoid double beaming
Date: Mon, 20 Feb 2023 11:08:56 +0100

Hi Jogchum,

the reason for your issues is that you are using voice 2 (i.e. lowest voice) 
with a \stemUp, which will cause issues to resolve collision. Generally you 
should avoid using \stemUp and \stemDown unless you really need to use it and 
rather use the correct Voice.

If you were to use \voiceThree instead (which is the second highest voice) the 
Lilypond will properly resolve collision:

\version "2.24.0"

global = {
  \key c \major
  \time 3/4
}

sopranoVoice = \relative c'' {
  \global
  \dynamicUp
  <<
    \new Voice {
      \voiceOne
      r8 a^\p a4. g8 \time 2/4
      f g a a
    }
    \new Voice {
      \voiceThree
      r8 f f4.(e8)
      d e f f
    }
  >>
}

\score {
  \new Staff \with {
    instrumentName = "Sopraan"
    shortInstrumentName = "S."
  } { \sopranoVoice }
  \layout { }
}


But in your case I suppose you do not actually want to have two voices but 
chords:

\version "2.24.0"

global = {
  \key c \major
  \time 3/4
}

sopranoVoice = \relative c'' {
  \global
  \dynamicUp
  <<
    {
      r8 a^\p a4. g8 \time 2/4
      f g a a
    }
    {
      r8 f f4.(e8)
      d e f f
    }
  >>
}

\score {
  \new Staff \with {
    instrumentName = "Sopraan"
    shortInstrumentName = "S."
  } { \sopranoVoice }
  \layout { }
}

Cheers,
Valentin

Am Montag, 20. Februar 2023, 10:43:40 CET schrieb Jogchum Reitsma:
> Hi,
> 
> In below snippet, lilypond renders two beams for the two voices, and,
> because I want the stems to have the same direction,
> the result for the 8th-notes is that they seem to be 16th notes.
> 
> Is there a way to avoid this, and to join the two beams to one?
> 
> Thanks in advance!,
> 
> regards, Jogchum
> 
> \version "2.24.0"
> 
> global = {
>    \key c \major
>    \time 3/4
> }
> 
> sopranoVoice = \relative c'' {
>    \global
>    \dynamicUp
> <<
>      \new Voice { << { \voiceOne
>                        r8 a^\p a4. g8 \time 2/4
>                        f g a a
> 
> 
>                      }
>                      \new Voice { \voiceTwo
>                                   \stemUp
>                                   r8 f f4.(e8)
>                                   d e f f
>                      }
>                   >>
>                   \oneVoice
>      }
> 
> }
> 
> \score {
>    \new Staff \with {
>      instrumentName = "Sopraan"
>      shortInstrumentName = "S."
>    } { \sopranoVoice }
>    \layout { }
>    }

Attachment: signature.asc
Description: This is a digitally signed message part.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]