lilypond-user
[Top][All Lists]
Advanced

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

Re: rearrange music flow


From: Carl D. Sorensen
Subject: Re: rearrange music flow
Date: Sat, 27 Dec 2008 10:35:20 -0700



On 12/27/08 9:25 AM, "Antanas Budri?nas" <address@hidden> wrote:

> Hello,
> 
> 2008/12/27 Francisco Vila <address@hidden>:
>> 2008/12/27 Antanas Budri?nas <address@hidden>:
>>> Thanks Arjan, thanks Francisco for replies.
>>> Perhaps due my poor English you both misunderstood me.
>>> There is a simplified example:
>> 
>>> { \xi \xii \xi \xiii }
>>> %%%%%%%%%%%%%%%%%
>>> 
>>> Would be nice that all this code results the same score as from
>>> %%%%%%%%%%%%%%%%%%
>>>  \relative c' { << {e f g f e f e d} {c d e d c d c b}>> }
>> 
>> You get something close by means of
>> { \new Voice \xi \xii \xi \xiii  }
> 
> Only *close* :) As well as with \new Staff I get all notes on one
> staff instead of voices on separate staves. Imagine an orchestral
> score :)


Aha!  I got it!   The secret was to explicitly name the Staff and Voice
contexts, and use \context instead of \new.

\version "12.0.0"
intro = <<
  \context Staff = "StaffOne" {
    \context Voice = "VoiceOne" {
      c''4 c''
    }
  }
  \context Staff = "StaffTwo" {
    \context Voice = "VoiceTwo" {
      c'4 c'
    }
  }
>>

verseOne = <<
  \context Staff = "StaffOne" {
    \context Voice = "VoiceOne" {
      d''4 d'
    }
  }
  \context Staff = "StaffTwo" {
    \context Voice = "VoiceTwo" {
      d'4 d'
    }
  }
>>

chorus = <<
  \context Staff = "StaffOne" {
    \context Voice = "VoiceOne" {
      e''4 e''
    }
  }
  \context Staff = "StaffTwo" {
    \context Voice = "VoiceTwo" {
      e'4 e'
    }
  }
>>

verseTwo = <<
  \context Staff = "StaffOne" {
    \context Voice = "VoiceOne" {
      f''4 f''
    }
  }
  \context Staff = "StaffTwo" {
    \context Voice = "VoiceTwo" {
      f'4 f'
    }
  }
>>

\score {
  {
    \intro
    \verseOne
    \chorus
    \verseTwo
  }
}


HTH,

Carl





reply via email to

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