lilypond-user-fr
[Top][All Lists]
Advanced

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

Re: Liaison sur 2 portées, commenç ant et terminant sur la même portée


From: AiYori
Subject: Re: Liaison sur 2 portées, commenç ant et terminant sur la même portée
Date: Sun, 10 Mar 2013 10:02:35 -0700 (PDT)

Bonjour,


Merci pour ta réponse.

J'ai défini les macros suivantes.



% <<<
  Down = \change Staff = "down"
  Up = \change Staff = "up"
% >>>



Voici le code complet.



% <<<

  \version "2.14.2"

  RythmePrimo = \markup { \bold "Dashing and bright" }

  Down = \change Staff = "down"
  Up = \change Staff = "up"

  % =-o-=
  offsetPositions =
  #(define-music-function (parser location offsets) (pair?)
    #{
       \once \override Slur #'positions = #(lambda (grob) 
         `(,(+ (car $offsets) (cdar (ly:slur::calc-control-points grob))) . 
           ,(+ (cdr $offsets) (cdr (cadddr (ly:slur::calc-control-points 
grob))))))
    #})
  
  %* Liaisons personnalisées. *
  LPA = \once \override Slur #'control-points = #'((0 . 3) (8 . 5) (16 . 3)
(26 . -5)) 
  LPB = \once \override Slur #'control-points = #'((0 . 3) (8 . 5) (16 . 3)
(24 . -5)) 
  LPC = \once \override Slur #'control-points = #'((0 . 5) (3 . 9) (5 . 7)
(7 . -5)) 
  LPD = \once \override Slur #'control-points = #'((0 . 3) (3 . 19) (5 . 17)
(7 . 15)) 

  VoixHautPrimo = \relative c'' {
    \override Score.BarNumber #'break-visibility = #'#(#f #t #t)
    \override Lyrics.LyricSpace #'minimum-distance = #3.0
    \numericTimeSignature \time 4/4
    \key c \major
    \clef treble

    r1        | % 01
    r1        | % 02
    r4\mf s2. | % 03
    r1        | % 04

    \break

    r4 s2. | % 05
    r1     | % 06
    r4 s2. | % 07
    r1     | % 08

    \break

    g4^5( g f d                      | % 09
    < c^1 e^3 >1)                    | % 10
    r4\mp \LPA e4( d c               | % 11
    \Down < e, g >2.) < e g >4-. \Up | % 12

    \break

    r4\mp \LPB e'4( d c                  | % 13
    \Down < f,_3 a_1 >2.) < f a >4-. \Up | % 14
    r4\< f'( e d                         | % 15
    g4-.) r g4-.^4 r\!                   | % 16

    \break

    a4\f^5( g f d^2       | % 17
    c4-.) r r2            | % 18
    r2 r4 < c e g >4-.\mp | % 19
    r2 r4 < e g b >4-.    | % 20

    \break

    r1                                   | % 21
    r4 < c e g >\< < d f a > < e g b >\! | % 22
    < f a c >4-.\mf r < f a c >-. r      | % 23
    < g c >-. r < g c >-. r              | % 24

    \break

    \LPC < fis c' >4( \Down < fis, c' >-.) \LPD < fis c' >( \Up < fis' c'
>-.) | % 25
    < g^2 b^4 >4\< < f!^2 a^4 > < e g > < d f >\!                             
| % 26
    < c^2 e^4 >4\f < c e > < c e >2                                           
| % 27
    < c e >4 < c e > < c e >2                                                 
| % 28

    \break

    < c^2 d^3 >4 < c d > < c d >2      | % 29
    < c d >4 < c d > < b d >2          | % 30
    r2 < a c e >4-.->\ff < a c e >-.-> | % 31
    r2 < b e >4-.-> < b e >-.->        | % 32

  }
  
  VoixBasPrimo = \relative c' {
    \numericTimeSignature
    \key c \major
    \clef treble

    r1                                    | % 01
    r1                                    | % 02

    %=-o-= 
    \offsetPositions #'(0 . 1)

    < e_3 g_1 >1*1/4( \Up e'4^3 d c \Down | % 03
    < e, g >2.) < e g >4-.                | % 04

    \break

    < e g >1*1/4( \Up e'4 d c \Down   | % 05
    < f,_3 a_1 >1)                    | % 06
    < f a >1*1/4( \Up f'4^4 e d \Down | % 07
    < g,_3 b_1 >1)                    | % 08

    \break

    r1                  | % 09
    g1_3                | % 10
    < e_3 g_1 >4-. r r2 | % 11
    \Up r1 \Down        | % 12

    \break

    < e g >4-. r r2 | % 13
    \Up r1 \Down    | % 14
    < f a >4-. r r2 | % 15
    r4 g-._2 r g-.  | % 16

    \break

    a4_1( g f d_4      | % 17
    c4-.) r r2         | % 18
    r2 r4 < c e g >4-. | % 19
    r2 r4 < e g b >4-. | % 20

    \break

    r1                                | % 21
    r4 < c e g >4 < d f a > < e g b > | % 22
    r4 < f a c >-. r < f a c >-.      | % 23
    r4 < g_4 c_1 >-. r < g c >-.      | % 24

    \break

    r4 \Up r r \Down r                        | % 25
    < g_4 b_2 >4 < f!_4 a_2 > < e g > < d f > | % 26
    < c_4 e_2 >4 < c e > < c e >2             | % 27
    < c e >4 < c e > < c e >2                 | % 28

    \break

    < c_4 d_3 >4 < c d > < c d >2   | % 29
    < c d >4 < c d > < b d >2       | % 30
    r2 < a c e >4-.-> < a c e >-.-> | % 31
    r2 < g b d >4-.-> < g b d >-.-> | % 32

  }

  \book {
 
    \header {
      title = "Jingle Bells"
      composer = \markup { \column {
        "James Pierpont"
        "Arrangement : Robert D. Vandall"
      } }
    }

    \score {
      \new PianoStaff <<
        \set PianoStaff.instrumentName = \markup { Primo }
        \new Staff = "up" \VoixHautPrimo
        \new Staff = "down" \VoixBasPrimo
      >>

      \layout {
        indent = 2\cm
        \context {
          \Staff
        }
        \context {
          \Score
        }
      }
      
      \midi {
        \context {
          \Score
          tempoWholesPerMinute = #(ly:make-moment 75 4)
        }
      }

    }

  }

%>>>



La version de Lilyond utilisée est la 2.14.2.


En revanche, j'ai un problème lorsque je compile ce code. Ce problème
survient depuis que j'ai inséré et utilisé la fonction 'offsetPositions'.
Voici la sortie que j'obtiens.



# <<<
00094.ly:111:20: erreur de programmation : dépendance circulaire :
calculation-in-progress rencontrée pour #'positions (Slur)
    < e_3 g_1 >1*1/4
                    ( \Up e'4^3 d c \Down | % 03
# >>>


J'avoue que je ne suis pas capable de résoudre ce problème.



--
View this message in context: 
http://lilypond-french-users.1298960.n2.nabble.com/Liaison-sur-2-portees-commencant-et-terminant-sur-la-meme-portee-tp7579071p7579132.html
Sent from the LilyPond French Users mailing list archive at Nabble.com.



reply via email to

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