lilypond-devel
[Top][All Lists]
Advanced

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

piecewise Dynamics context


From: Werner LEMBERG
Subject: piecewise Dynamics context
Date: Tue, 30 Apr 2013 11:52:31 +0200 (CEST)

Folks,


currently, a `Dynamics' context consists of at least a straight
horizontal line with zero vertical extent by default.  For complex
piano music, this is far from ideal:


                                                     bottom skyline of
   -----------+    +--------+         +------------- right hand
              |    |        +---------+
              |    |
              +----+


   ------------ mf ------------ sfz ---------------- dynamics


   ------------------------------------------------- top skyline of
                                                     left hand


In the above sketch, the `sfz' should be positioned higher.

Making `Dynamics' a rubberband so that it gets always centered
vertically between the top and bottom skylines probably needs a lot of
thinking and coding to make this work.

It just occurred to me that an alternative solution might be easier to
implement (well, this is just a guess, of course): Instead of
considering a single Dynamics context spanning the whole line, what
about make it piecewise, together with a `horizontal-padding'
property, and vertically center this pieces individually?


                                                     bottom skyline of
   -----------+    +--------+         +------------- right hand
              |    |        +---------+
              |    |
              +----+

                            --- sfz ---
            --- mf ---


   ------------------------------------------------- top skyline of
                                                     left hand


In other words, within `Dynamics', the appearance of an element which
is not `s' triggers the creation of a small Dynamics subcontext (or
however you want to call it) which exists until the element disappears
in the flow of time, plus some horizontal padding around it.

Does this make sense?


    Werner



reply via email to

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