lilypond-user
[Top][All Lists]
Advanced

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

Re: alternatives at beginning or middle


From: Joel C. Salomon
Subject: Re: alternatives at beginning or middle
Date: Sun, 10 Nov 2013 18:56:24 -0500
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.1.0

Almost eight years ago, on 11/30/2005, Mats Bengtsson wrote:
> Quoting Stuart Lowe <address@hidden>:
>> Lilypond seems to handle alternative endings on repeated parts very
>> well.  What about alternative beginnings, or even an
>> alternative somewhere in the middle?
>>
>> Can someone tell me how I would do this?
>
> I don't know if there is any standardized notation for such things.
> However, if you want to have the brackets and labels, take a look
> at the section on "Manual Repeat Commands" in the manual.

Is this still the only option?

I'm trying to typeset something like the score shown in
<http://youtu.be/xucuWOMmPio>.  Below is a cut-down version of a source
file that seems to accomplish this result.  To my (beginner's) eye, this
looks kind of messy.  But is there a better way?

--Joel Salomon

\version "2.16.2"
\score {
  <<
    \relative c'' {
      % This line is only played the first time
      \set Score.repeatCommands = #'((volta "1."))
      \partial 4 a4 | c c c c |

      \set Score.repeatCommands = #'((volta #f) (volta "2.--3."))
      \bar "|:"
      \set Timing.measureLength = #(ly:make-moment 1 4)
      b4 |
      \set Timing.measureLength = #(ly:make-moment 4 4)
      g4 g g g |

      \set Score.repeatCommands = #'((volta #f) (volta "1.--3."))
      b4 c d e | f e d c |

      \set Score.repeatCommands = #'((volta #f) (volta "1.--2"))
      \set Timing.measureLength = #(ly:make-moment 3 4)
      a4 a a |

      \set Score.repeatCommands = #'((volta #f) end-repeat (volta "3."))
      \set Timing.measureLength = #(ly:make-moment 4 4)
      c4 c c c |

      \set Score.repeatCommands = #'((volta #f))
      \bar "|."
    }
  >>
}



reply via email to

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