Comment #20 on issue 687 by adam.spiers: Enhancement: inequal MIDI
quantization of equal durations (swing, rubato)
http://code.google.com/p/lilypond/issues/detail?id=687
Great work! I will have to try this out soon.
You are right that more parametrization is required: currently the fact
that your "swing-unit" is twice the duration of your "swing-division"
corresponds to a repeat count of 2 as defined in comment 6. But with other
styles of music the repeat count can be 3 (Viennese waltz), 4 (samba), or
possibly other funky styles I've never heard of - I'm willing to bet that
there are some Eastern European styles which swing in 5 for instance :)
Likewise, your swing-division corresponds to my denominator also defined in
comment 6, and the decision of whether a note gets lengthened or shortened
corresponds to whether its start and/or end fall on a displaced numerator.
In jazz swing, only the second (i.e. last) numerator of every 2-note repeat
group gets displaced to make it later. This second numerator corresponds
to the end of the first note in the repeat group and the beginning of the
second note in the repeat group. This results in a lengthening of the
first note and a shortening of the second note.
In the lilt of Viennese waltzes, only the second (i.e. middle) numerator of
every 3-note repeat group gets displaced, this time to make it earlier.
This results in a shortening of the first note in each group, a lengthening
of the second note, and the third note's length remaining unchanged.
Therefore as explained in comment 6, I think we need 4 integer parameters
per displacement. (Note that in order to accomodate "swing within swing",
even the denominator and repeat count are not necessarily shared across all
displacements in the swing style, since you could have multiple repeat
groups with independent displacements. Although this opens a question over
how to resolve conflicts between multiple repeat groups requesting
different displacements of the same note boundary - I would suggest that
that should generate an error.)
I think this waltz example would be a great acid test - if the code can
handle that, then we know we must be very close to a completely general
solution :)
_______________________________________________
bug-lilypond mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-lilypond