lilypond-user
[Top][All Lists]
Advanced

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

Re: Scheme function help - modifying note durations


From: David Kastrup
Subject: Re: Scheme function help - modifying note durations
Date: Sat, 06 Oct 2012 16:37:22 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.50 (gnu/linux)

Shashank Raja <address@hidden> writes:

> I want to write a scheme function that doubles a note such that the
> pitch (let's call it 'x') is retained, but the respective durations
> are such that {x8.. x32} is displayed. 
> Since \displayMusic{ c'8.. c'32 } outputs this:
> https://raw.github.com/gist/3843324/f77790c4917337539936584ae65bb886f804edec/gistfile1.
> ly
>
> My attempt based wholly on the Lilypond Scheme docs is as follows:
> https://raw.github.com/gist/3843324/15d0b07d567370f69631f68194e71bc5a62c6610/minimal.
> ly
>
> However, I get this error upon compiling:
> https://raw.github.com/gist/3843324/0e5c741648ec02eddf2e561aa3d69f0b114acde9/error%20output
>
> Also, in the part of the error which says 
>
>  (#<Duration 32 > . #<Duration 4 >)
>
> the 4 changes based on the argument to the \myfunc function; i.e.
> \myfunc c128 would result in (with snipping, of course):
>  (#<Duration 32 > . #<Duration 128 >)
>
> What am I doing wrong?

You are replacing a duration here with a pair of durations.  A pair of
durations is not the same as a duration.

I think that the snippets in the documentation contain useful examples,
likely under the topic of "rhythm", how to repeat some pitch or chord
with a particular rhythm or phrase.

-- 
David Kastrup




reply via email to

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