lilypond-user
[Top][All Lists]
Advanced

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

Re: Decrescendo on last note


From: Jay Anderson
Subject: Re: Decrescendo on last note
Date: Wed, 3 Oct 2012 07:37:13 -0700

On Wed, Oct 3, 2012 at 5:25 AM, Carlo Stemberger
<address@hidden> wrote:
> Il 03/10/2012 06:37, Keith OHara ha scritto:
>>
>> I guess there is good reason the manual shows the method with
>> simultaneous streams of music; it is more generally useful.
>>
>> \new Voice<<  b1 {s2.-\tweak #'minimum-length #5 \>   s4\pp}>>
>
>
> Yes, but this looks as a hack. I think we should have a very simple syntax
> for this kind of dynamics, because they are very frequent.

I don't consider this a hack. Using parallel spacer rests is a very
common construct. If it seems ugly then you can always move it to a
function to hide it away.


\version "2.16.0"

endHairpin =
#(define-music-function (parser location mus) (ly:music?)
  #{
    <<
      { $mus }
      {
        <>-\tweak #'minimum-length #5 \>
        #(skip-of-length #{\scaleDurations #'(9 . 10) $mus #})
        <>\pp
      }
    >>
  #})

\score
{
  \new Staff
  {
    c'1 \endHairpin c'1
  }
}


This function can be made more general (pass in dynamic, hairpin
length, etc.). However, it does show that you can simplify and hide
these constructs when desired. The syntax is very adequate for this.

-----Jay



reply via email to

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