2

我想我已经很接近了,但似乎不太可能让两节与一个隐藏的声音对齐 - 因此节奏变化可以通过歌词来近似。

melody = \relative c' {
  \clef treble
  \key c \major
  \time 4/4
  c4 d e f | g f e d |

  <<
 \new Voice = "shown" {
  \relative c' { 
  c4 d c d | e f g2
     }
    }  

  \new Voice = "hidden" {
   \hide { 
  c'8 c d d c c d d | e f g2
     }
    }
  >>
}

text =  \lyricmode {
   Here we have a | li -- tle si -- lly

  <<
    {
      \set stanza = #"1. "
      Si -- lly li -- tle | al -- pha -- bet

    \new Lyrics {
      \set associatedVoice = "hidden"
      \set stanza = #"2. " 
      Si -- ly li -- tle fu -- nny soun -- ding |
      Al -- pha -- bet song.
        }
    }
  >>
  }

\score {
  <<
    \new Voice = "one" { \melody }
    \new Lyrics \lyricsto "one" \text
  >>

  \layout { }
  \midi { }
}

上面显示了声音和它们的“相关”(或不)歌词。

4

2 回答 2

6

您可以NullVoice这样使用上下文:

\version "2.19.15"
\language "english"

\score {
  \new Staff
  <<
    \new Voice = "displayedMusic" \relative c'' {
      b8 c d \times 2/3 {c16 d c}
      b8 a g a
      bf c bf \times 2/3 {a16 bf a}
      g8 f g a
      bf f' e a,
      d cs4.~
      cs1
    }

    \new NullVoice = "hiddenMusic"
    {
      c4 d e f %\break
      g a b8~ b c4 \break
      d e f g a
    }
    \new Lyrics \lyricsto "hiddenMusic" {
      Those words seem to be aligned to the hidden melody or are they?
    }
  >>
}

这将导致:

乐谱片段

于 2015-01-05T23:31:24.493 回答
2

好的。从lilypond 邮件列表中我了解到:

首先,您需要使用\hideNotes,而不是\hide。上述结构也不太有效。让所有歌词上下文从头开始运行通常比从部分开始更容易——它们会从音符中得到它们的位置。这是一种方法,尽管在这种特殊情况下,节号不太合适。

melody = \relative c' {
  \clef treble
  \key c \major
  \time 4/4
  c4 d e f | g f e d |

  <<
    \new Voice = "shown" {
      \relative c' { 
        c4 d c d | e f g2
      }
    }  

    \new Voice = "hidden" {
      \hideNotes {                  % !!
        c'8 c d d c c d d | e f g2
      }
    }
  >>
}

text =  \lyricmode {
   Here we have a | li -- tle si -- lly
}

wordsOne = \lyricmode {
  \set stanza = #"1. "
  Si -- lly li -- tle | al -- pha -- bet
}

wordsTwo = \lyricmode {
  \set stanza = #"2. " 
  Si -- ly li -- tle fu -- nny soun -- ding |
  Al -- pha -- bet song.
}

\score {
  <<
    \new Voice = "one" { \melody }
    \new Lyrics \lyricsto "one" \text
    \new Lyrics \lyricsto "shown" \wordsOne
    \new Lyrics \lyricsto "hidden" \wordsTwo
  >>

  \layout { }
  \midi { }
}
于 2014-12-11T07:07:20.563 回答