Menu

#4048 Is Dynamic_performer’s understanding of (de)crescendo too limited?

Verified
Dan Eble
Enhancement
2016-08-02
2014-08-02
Anonymous
No

Originally created by: *anonymous

Originally created by: pkx1...@gmail.com

On 02/08/14 18:36, Knute Snortum wrote:> Something that is seen a lot in 19th and 20th century music is a crescendo
> or decrescendo without going to a specific dynamic.  The performer is given
> the freedom to decide how much to change the dynamics.  This causes an
> error message: "programming error: Impossible or ambiguous (de)crescendo in
> MIDI."
>
> %%% BEGIN
> \version "2.19.10"
>
> \score {
>   \relative c' {
>     c1 \p | c4 \< d e f | g \> f e d | c1 \p
>   }
>   \layout {}
>   \midi {}
> }
> %%% END
>
> This error message should be a warning and give some line number to the
> offending code.

On 02/08/14 15:28, David Kastrup wrote:> Knute Snortum <ksnortum@gmail.com> writes:

...

>
> That's not an actual programming error in pretty much all cases but
> rather an input problem probably deserving a warning.  That alone should
> warrant fixing.
>

Discussion

1 2 > >> (Page 1 of 2)
  • Google Importer

    Google Importer - 2014-10-04

    Originally posted by: nine.fie...@gmail.com

    Should this issue be merged with issue 3945?

     

    Related

    Issues: #3945

  • Google Importer

    Google Importer - 2015-05-02

    Originally posted by: simon.al...@mail.de

    Well, it’s very similar. This one has a stress on what the output message says. But the ‘design’ question is common to all three issues (including issue 4104, which really is a duplicate).

     

    Related

    Issues: #4104

  • Google Importer

    Google Importer - 2015-05-02

    Originally posted by: simon.al...@mail.de

    And by ‘design’ question I mean: Do we want Lily to complain at all? As Knute rightly pointed out, this reflects a specific way to use hairpins, which is definitely ‘correct’ within that style.
    So I’d suggest to make it configurable at the very least (say through
    \set HairpinStrictLoudness = ##t or
    \override Hairpin.strictLoudness = ##t or
    \override Hairpin.midiLoudnessBehaviour = #'seamless-edges vs. #'independent-edges
    \override Hairpin.midiEdges = #'bound vs. #'free)
    The last one seems most descriptive and concise to me.
    Behaviour sketch:
    If #'free (or strictLoudness = ##f or #'independent-edges) assign to the Hairpin’s closed end a midi volume as in effect previously, and adjust the (de-)crescendo accordingly. Continue playing with the volume from before the hairpin.
    If #'bound (or strictLoundess = ##t or #'seamless-edges) start with the midi volume currently in effect, make (de-)crescendo and arrive at a new level. If there are inconsistencies, complain (as it is now), but not with a programming error, but with a warning (perhaps "Can’t make sense of hairpin in MIDI"), pointing to the input location and appearing only if MIDI output is generated (i.e. given by Dynamic_performer IIUC).

     
  • Google Importer

    Google Importer - 2015-07-20

    Originally posted by: simon.al...@mail.de

    (No comment was entered for this change.)

    Summary: Is Dynamic_performer’s understanding of (de)crescendo too limited?
    Labels: Needs-design

     
  • Dan Eble

    Dan Eble - 2016-06-04
    • Description has changed:

    Diff:

    
    
    • assigned_to: Dan Eble
    • Patch: -->
     
  • Dan Eble

    Dan Eble - 2016-06-04

    I ran across some code that inspired head-scratching, and I believe it is directly related to this issue. I can probably fix it. Here are my thoughts for your review. Basically, in most cases, I don't think there is sufficient reason to issue warnings.

    crescendo with explicit dynamics (mf < f)

    • at endpoints, use the specified dynamics
    • between endpoints, interpolate

    unspecified starting dynamic (... < f)

    • use the most recent dynamic as the starting point
    • at the start of the piece, use the default dynamic (issue 3945)
    • between endpoints, interpolate

    unspecified ending dynamic (mf < ...)

    • at the ending point, use a volume that is a reasonable amount louder than the starting volume (there appears to be code to do this already)
    • between endpoints, interpolate

    “impossible” crescendo (mf < p)

    • perform as a crescendo with unspecified ending dynamic followed by an instant change to the specified ending dynamic

    mid-crescendo dynamics

    • e.g. << { c'1\< c' c'\! } { s1 s\p s } >>
    • interpolate each interval separately as in cases above
    • it might make sense to some people to warn about unexpected dynamics like p in the middle of a crescendo from mf to f, but the engraver lays it out as requested without complaining, so why not have a go at performing it too?
     

    Last edit: Dan Eble 2016-06-04
    • Dan Eble

      Dan Eble - 2016-06-05

      mid-crescendo dynamics
      e.g. << { c'1\< c' c'\! } { s1 s\p s } >>

      On second thought, this is not a case that needs to be handled. In my test file, I didn't force the simultaneous music into the same voice, so what looked like mid-crescendo dynamics to me was just parallel voices. An absolute dynamic ends a crescendo or decrescendo in a voice, so only the cases with dynamics at the start and end need to be handled.

       
  • Simon Albrecht

    Simon Albrecht - 2016-06-05

    LGTM.

     
  • Dan Eble

    Dan Eble - 2016-06-25

    I've gone a bit further and handled sequences of (de)crescendi, to an extent. I plan to test my work before posting a review, but here is the algorithm in case anyone would like to raise objections in the meantime.

    The performer works on passages containing of the longest string of consecutive crescendi followed by consecutive decrescendi (or vice versa) which are not interrupted by an absolute dynamic. For example, this passage has two crescendi and a decrescendo, as well as some spans of unchanging volume.

    c\< c\! c c c\< c\! c c c\> c c c c c c c\! ...
    

    The performer works it out so that at the end of the decrescendo, the volume has returned to the original volume before the first crescendo in the passage began. The maximum (or minimum) volume is chosen as it was before. The change in volume of a particular (de)crescendo is proportional to its duration.

    When an absolute dynamic appears, the performer terminates the group and uses the specified dynamic instead of the starting dynamic.

     

    Last edit: Dan Eble 2016-07-04
  • Dan Eble

    Dan Eble - 2016-07-04

    Issue 4048: Improve crescendo performance with unspecified dynamics

    http://codereview.appspot.com/302910043

     
  • Dan Eble

    Dan Eble - 2016-07-04

    Represent dynamics as a piecewise linear function

    http://codereview.appspot.com/302910043

     
  • Dan Eble

    Dan Eble - 2016-07-04

    Handle multiple (de)crescendi in depart-return groups

    http://codereview.appspot.com/302910043

     
  • Anonymous

    Anonymous - 2016-07-05
    • Needs: -->
    • Patch: new --> waiting
    • Type: --> Enhancement
     
  • Anonymous

    Anonymous - 2016-07-05

    Passes make, make check and a full make doc.

     
  • Dan Eble

    Dan Eble - 2016-07-07
    • Patch: waiting --> review
     
  • Anonymous

    Anonymous - 2016-07-11
    • Patch: review --> needs_work
     
  • Anonymous

    Anonymous - 2016-07-11

    Looks like this patch needs some more work (based on comments on Rietveld).

     
  • Dan Eble

    Dan Eble - 2016-07-12
     
  • Anonymous

    Anonymous - 2016-07-12
    • Needs: -->
    • Patch: new --> review
    • Type: --> Enhancement
     
  • Anonymous

    Anonymous - 2016-07-12

    passes make, make check and a full make doc.

     
  • Anonymous

    Anonymous - 2016-07-14
    • Patch: review --> countdown
     
  • Anonymous

    Anonymous - 2016-07-14

    Patch on countdown for July 17th - although there is a long thread in Rietveld that seems to just be a general discussion about a previous reply, but can you just check in case there i something that still needs to be done?

     
  • Anonymous

    Anonymous - 2016-07-17
    • Patch: countdown --> push
     
  • Anonymous

    Anonymous - 2016-07-17

    Patch counted down - please push

     
    • Anonymous

      Anonymous - 2016-07-19

      This is unlikely to happen this week for a few reasons beyond my control.
      Sorry to anyone who is inconvenienced.
      --
      Dan

       
1 2 > >> (Page 1 of 2)
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.