lilypond-user
[Top][All Lists]
Advanced

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

Re: Expanding bowed arpeggios


From: shutterfreak
Subject: Re: Expanding bowed arpeggios
Date: Sat, 12 Jan 2013 12:33:34 -0800 (PST)

shutterfreak wrote
> On Sat, Nov 24, 2012 at 1:26 PM, Olivier Biot <

> olivier.biot@

> >wrote:
> 
> Dear all,
> 
> Following up on my own request, I stumbled upon an insightful article
> featuring Bach's prelude for piano (BWV 846):
> http://news.lilynet.net/?The-LilyPond-Report-23#feature_story_prelude_1_in_scheme
> 
> Based on this example I managed to create a first version, which however
> only works with *absolute* pitches (see measure 1).
> 
> How can I make it work with *relative* pitches (see measure 2)?
> 
> %%% BEGIN Snippet
> \version "2.16.1"
> 
> arpeggiate = #(define-music-function (parser location d p1 p2 p3 p4)
>                 (ly:duration? ly:pitch? ly:pitch? ly:pitch? ly:pitch?)
>                 "Arpeggiate each of the 4 notes note with a duration of
> d."
>                 #{
>                   $p1 $d ( $p2 $d $p3 $d $p4 $d )
>                   $p4 $d ( $p3 $d $p2 $d $p1 $d )
>                 #})
> 
> theMusic = {
>   \arpeggiate 8 g d' a' e''
>   \relative g {
>     \arpeggiate 8 g d' a' e'
>   }
> }
> 
> \score {
>   \new StaffGroup <<
>     \new Staff {
>       \relative g {
>         
> <g d' a' e'>
> 1 q
>       }
>     }
>     \new Staff {
>       \theMusic
>     }
>   >>
>   \layout { }
>   \midi { }
> }
> %%% END Snippet

Dear all,

So far I didn't find a way to make my arpeggio expansion work with notes in
*relative pitch*. My bet is that I need to do some magic on "ly:pitch?" to
get it to work, but I am clueless since I don't know what I should type as
search keywords to get that information. Is there for example a
relative-pitch-to-absolute-pitch checker routine that I could use?

Could somebody with better knowledge of LilyPond / Guile help me in making
it work or pointing me in the right direction?

Any help is greatly appreciated!

Olivier



--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/Expanding-bowed-arpeggios-tp136789p139404.html
Sent from the User mailing list archive at Nabble.com.



reply via email to

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