|
From: | Aaron Hill |
Subject: | Re: Espressivo type custom dynamics |
Date: | Wed, 23 Sep 2020 02:57:45 -0700 |
User-agent: | Roundcube Webmail/1.4.2 |
On 2020-09-23 2:06 am, Andrew Bernard wrote:
Harm's great code for making longer espressivo marks was posted on the list in 2013. It's excellent. But now say I want similar custom dynamics similar to an espressivo but with a dynamic inside, like <pp> where < and > are the arms of the espressivo. I'd like this because although the obvious answer is to use normal dynamics, I often don't have a note in the voice to set off, and I don't want to introduce separate voices just to handle this type of dynamic. For example: C1 <pp> <p> <f> Sorry, since I don't have code for this I can't provide an MWE. I hope the question is clear. I understand this is a lot complicated than just scaling the x-axis of the basic espressivo. As an aside, this style is _very_ common in Modernist music, and it would make a great addition to core lilypond at some time.
I took my code [1] I provided before and updated it to be a proper markup command:
[1]: https://lists.gnu.org/archive/html/lilypond-user/2019-01/msg00539.html
%%%% \version "2.20.0" #(define-markup-command (espressivo layout props arg) (markup?) #:properties ((thickness 0.12) (width 1.7) (height 0.9) (spacing 0.12)) (define (espressivo-side dir) (let ((outer (* dir width)) (middle (/ height 2))) (ly:stencil-add (make-line-stencil thickness 0 0 outer middle) (make-line-stencil thickness outer middle 0 height)))) (ly:stencil-combine-at-edge (espressivo-side LEFT) X RIGHT (ly:stencil-combine-at-edge (espressivo-side RIGHT) X LEFT (interpret-markup layout props arg) spacing) spacing)) { c'1 \espressivo c'1 \tweak parent-alignment-X #CENTER \tweak self-alignment-X #CENTER _\markup \espressivo \null c'1 \tweak parent-alignment-X #LEFT \tweak self-alignment-X #LEFT _\markup \override #'(spacing . 0.48) \fontsize #-2 { \override #'(thickness . 0.2) \espressivo \dynamic pp \override #'(width . 2.8) \espressivo \dynamic p \override #'(height . 1.5) \espressivo \dynamic f } } %%%% -- Aaron Hill
espressivo-markup.cropped.png
Description: PNG image
[Prev in Thread] | Current Thread | [Next in Thread] |