lilypond-user
[Top][All Lists]
Advanced

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

Re: music patterns and octave


From: David Wright
Subject: Re: music patterns and octave
Date: Wed, 9 Mar 2016 07:50:06 -0600
User-agent: Mutt/1.5.21 (2010-09-15)

On Wed 09 Mar 2016 at 01:07:47 (+0100), Gianmaria Lari wrote:
>    Ciao David,
>    let's put it in another way. Have a look to the attached image and please
>    suggest me how you would write the code to generate it.

That is attached. I adopted a subtractive approach, using your source
as a base.

>    Then please have a look to the code I *would* like to write to obtain it.
>    Do you know if does exist anything similar to "\setOctave"? Do you see any
>    logical mistake in trying to write it in this way? Sorry if the example is
>    not very simple, but I have not been able to make it better.

I find it difficult to know what you're trying achieve. It seems that
you're trying to fight LP's \relative { } construction rather than
just using it. We are left trying to guess your intent.

I see that one of the suggestions you've had is to use \resetRelativeOctave
but I can't quite see the necessity of using that in most static music.
OTOH it could be very useful if you were composing the middle section
of a work in LP and needed to prevent a later section from jumping up
and down an octave each time you changed anything.

>    \version "2.19.35"
>    \include "changePitch.ly"
>    rhythmPattern = {a16 \tuplet 3/2 {a8 a a} a16 a8 a4 a4} % a complex rhythm
>    scoreViolinI = \relative c'
>    {
>      \setOctave c' %this command is just an example and it does not exist!
>      \changePitch \rhythmPattern {c d d d c b d e}
>      f g a b
>      c d e f
>      \setOctave c'  
>      \changePitch \rhythmPattern {c d d d c b d e}
>    }
>    scoreViolinII = \relative c'
>    {
>      \setOctave c' 
>      \changePitch \rhythmPattern {a b b b a b a a}
>      f f a a  
>      c c f f
>      \setOctave c' 
>      \relative c' \changePitch \rhythmPattern {a b b b a b a a}
>    }
>    \score
>    {
>      <<
>        \new Staff \scoreViolinI
>        \new Staff \scoreViolinII
>      >>
>      \layout { }
>    }

Cheers,
David.

Attachment: cp.ly
Description: Text Data

Attachment: cp.pdf
Description: Adobe PDF document

Attachment: Capture.PNG
Description: PNG image


reply via email to

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