Hello,

it can be useful to create dynamics that can be heard only in the midi
output. Then I used the below procedure. However, if I try to make a
function with the same command, there's a syntax error. How can I fix it?
Thanks!


%%%%%%%%%%%%%%
midiDynamic = #(define-music-function (parser location dyn) (ly:music?)
#{ -\tag #'display \! -\tag #'midi $dyn #})

music = {

c'\pp

% WORKS
c'-\tag #'display \! -\tag #'midi \ff

% DOESN'T WORK, FIXME
% c'\midiDynamic \fff

}

\score {
  \keepWithTag #'layout
  \new Staff { \music }
  \layout {}
}

\score {
  \keepWithTag #'midi
  \new Staff { \music }
  \midi {}
}
%%%%%%%%%%%%%%

Reply via email to