lilypond-user
[Top][All Lists]
Advanced

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

Re: Repeats in \parallelMusic


From: Jacques Menu
Subject: Re: Repeats in \parallelMusic
Date: Wed, 26 Aug 2015 17:17:07 +0200

For example, 2.19.25, given :

fagottThemaAndanteConVariazioni = \relative f {
  \clef "bass"
  \key g \major
  \time 2/4

  \tempo "Thema andante con variazioni"

  \set Score.skipBars = ##t

  % page 43

  \repeat volta 2 {
    \partial 8*1
    d8\p |
    \barNumberCheck #1

    g4 a |
    b4 c |
    d4 c8 cis |
    d4. r8 |
    \myBreak\myDisplayBarNum\barNumberCheck #5

    r8 g,8\f a4 |
    r8 b8 c4 |
    d4 c4 |
    c4( b8)
  }

  \repeat volta 2 {
    r8 |
    r8 gis8\p( a b) |
    c8\f-.  d( e) r8 |
    \myBreak\myDisplayBarNum\barNumberCheck #11

    fis,8\p( g a fis) |
    b8 c( d) r8 |
    b4\f d |
    g4 e |
    r8 d8 c4 |
    c4( b8)
  }
  \break

  % page 44


produces:

JM

Le 26 août 2015 à 17:12, Jacques Menu <address@hidden> a écrit :

Hello David,

Wouldn’t all that be much simpler without \parallelMusic, with just one variable per staff contents?

JM


Le 26 août 2015 à 16:02, David Sumbler <address@hidden> a écrit :

On Wed, 2015-08-26 at 14:10 +0200, David Kastrup wrote:
David Sumbler <address@hidden> writes:

is it
possible to have repeats starting and ending within a bar when using
\parallelMusic?

\version "2.18.0"

\parallelMusic #'(Vone Vtwo) {
%bar 1
  \repeat volta 2 {
d''2 d'' |
f'2 f' |
%bar 2    
c''2 c'' |
e'2 e' |
  }
%bar 3
  g''1 |
  c''1 |
}

\score { <<
  \new Staff { \Vone }
  \new Staff { \Vtwo }
}

That, of course, works fine.

But suppose that the repeat should start in the middle of bar 1 and end
in the middle of bar 2.  This is easily done when setting the parts
separately; but can it be done within a \parallelMusic structure?  On
the face of it, the answer would seem to be "no".

Or is it?

Any reason you neither try it out nor add any template to demonstrate
on?  A user list is primarily a knowledge resource: making use of the
different knowledge and skill levels of the participants for overcoming
hurdles, not for running the whole track.

It should be easy enough for yourself to modify the example such that
the repeats are on partial measure positions.

With respect, I could see no obvious way in which it could be done,
which is why I asked.  I suppose it was the proverbial "stupid
question".

Anyway, after trying several more (im)possibilities, I found a method
that worked but produced error messages.  Then I remembered Stephen
MacNeil's helpful suggestion a few months ago regarding incomplete final
bars.  An example is:

\version "2.18.0"

\parallelMusic #'(Vone Vtwo) {
%bar 1
  \set Score.measureLength = #(ly:make-moment 3/4) c''2. |
  \set Score.measureLength = #(ly:make-moment 3/4) e'2. |
  \repeat volta 2 {
\set Score.measureLength = #(ly:make-moment 1/4) d''4 |
\set Score.measureLength = #(ly:make-moment 1/4) f'4 |
%bar 2
\set Score.measureLength = #(ly:make-moment 4/4) e''1 |
\set Score.measureLength = #(ly:make-moment 4/4) g'1 |
%bar 3
d''1 |
f'1 |
%bar 4    
\set Score.measureLength = #(ly:make-moment 3/4) c''2. |
\set Score.measureLength = #(ly:make-moment 3/4) e'2. |
  }
  \set Score.measureLength = #(ly:make-moment 1/4) b'4 |
  \set Score.measureLength = #(ly:make-moment 1/4) d'4 |
%bar 5
  \set Score.measureLength = #(ly:make-moment 4/4) c''1 |
  \set Score.measureLength = #(ly:make-moment 4/4) e'1 |
}

\score {
  <<
\new Staff { \Vone }
\new Staff { \Vtwo }

}

Not exactly succinct, but it works.  I am sending this to the list (a)
so that I can find it again when I actually need it (b) in case somebody
knows a neater solution to the problem.

David


_______________________________________________
lilypond-user mailing list
address@hidden
https://lists.gnu.org/mailman/listinfo/lilypond-user



reply via email to

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