lilypond-user
[Top][All Lists]
Advanced

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

Re: MIDI and template for dynamics


From: Kaj Persson
Subject: Re: MIDI and template for dynamics
Date: Tue, 31 May 2016 08:33:52 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.1.0

Hello Jan-Peter,

Sorry, I do not exactly understand the intention of your proposal. I am almost always using two \score sections, one for the midi and one for the layout (pdf). There are many reasons for that, among others "\unfoldRepeats" to take care of repeats. There are also other circumstances motivating this procedure. But there are nevertheless reasons to let them be as alike as possible, not least the amount of work to put into the project, by e.g. using a common dynamics template if the music allows this, which is often the case. To move the Dynamic_performer to the Staff context I do not think is a good idea, because the dynamics like the rest of the music belongs intimately to the voice, and small peculiarities must be taken care of there. Small and maybe rare differences can e.g. be adapted to the special note and voice where it belongs while the rest of the dynamics might be taken care of by the common template.

I might have misunderstood you, and do not see the innermost intention with your suggestion, so please come back and explain.

After all, your suggestion with including the dynamics template in the voice itself is the best for the moment, because it in fact does work. I have tested with the music I am working with for the moment. The result is what I want, and the midi, the strength of the notes is following the dynamics template.. However it is a pity that one has to define the template in every voice, instead of every staff or even group of staves. And still, I cannot understand why I have to do so, and what is happening when I put a name on one of the voices, as it works without this name.

/Kaj


Den 2016-05-30 15:37, skrev Jan-Peter Voigt:
Hi Kaj,

if you use separate templates for pdf and midi, of course you can adjust the template as needed per case. But it seems, you want to create both from one template. If you can use at least two score-statements, you can separate both cases and - for example - use tags to avoid double dynamics in PDF-output. Another approach would be to move the Dynamic_performer to the Staff-context:

\midi {
  \context {
    \Voice
    \remove "Dynamic_performer"
  }
  \context {
    \Staff
    \consists "Dynamic_performer"
  }
}

though, I haven't tested that!

HTH
Jan-Peter


Am 30.05.2016 um 11:34 schrieb Kaj Persson:
Hi Jan-Peter!

This, in fact, worked. Now I have to investigate the consequences for my real case, as this is of course a wee more complicated than the simple snippet. it deals with choir music with double voices (soprano and alto etc.) in each staff, and also other things.

The question remains however, if the first attempt with the dynamics as a separate voice is working for the printed score, why does not this information go into the MIDI file, when any of the voices is named.

/Kaj


Den 2016-05-30 10:34, skrev Jan-Peter Voigt:
Hi Kaj,

perhaps it doesn't matter that its named, but dynamics are in a separate voice context?

You might try instead:

\new Voice = "SA" << \Music \Dynamics >>

Just a thought ...

HTH
Jan-Peter


Am 30.05.2016 um 10:28 schrieb address@hidden:
Hi all,

Using a template for dynamics is a convenient way of writing, when
dealing with voices following the same dynamics pattern. Basically it
works very well for producing beautiful scores, and also controlling
MIDI. But now I have found something that might be a bug, even if I hope
it is just a mistake of mine. Here is a small example:

|\version "2.18.2"||
||||
||Music = {||
||  a'4 a' a' a'||
||  a'4 a' a' a'||
||}||
||||
||Dynamics = { ||
||  s4\ppp s s s||
||  s4\fff s s s||
||}||
||||
||\score {||
||   \new Staff <<||
||     \new Voice { \Music }||
||     \new Voice { \Dynamics }||
||   >>||
||||
||  \layout {}||
||  \midi {}||
||}|

It produces a nice score and also the MIDI reflects the dynamics. But,
if I name one of the Voices, which I need to for Lyrics, the score is
still fine, but in the MIDI file nothing of dynamics can be heard. Just
one level all the time.

|\version "2.18.2"||
||||
||Music = {||
||  a'4 a' a' a'||
||  a'4 a' a' a'||
||}||
||||
||Dynamics = { ||
||   s4\ppp s s s||
||   s4\fff s s s||
||}||
||||
||\score {||
||  \new Staff <<||
||    \new Voice = "SA" { \Music }||  % <-- named voice
||    \new Voice { \Dynamics }||
||  >>||
||||
||   \layout {}||
||   \midi {}||
||}||
|||

As you see the above examples are written for version 2.18.2, the latest stable, but I have tested also in version 2.19.42 without any difference.

/Kaj



_______________________________________________
lilypond-user mailing list
address@hidden
https://lists.gnu.org/mailman/listinfo/lilypond-user











reply via email to

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