[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Beginner's questions about long repeats & MIDI files
From: |
Mojca Miklavec |
Subject: |
Re: Beginner's questions about long repeats & MIDI files |
Date: |
Sat, 15 Oct 2016 07:36:41 +0200 |
Hi,
Thank you very much for some very useful suggestion. I'll reply to the
rest later, but I have one "objection" (I could probably have
mentioned that in my first post):
On 15 October 2016 at 01:22, Flaming Hakama by Elaine wrote:
>
>> Is there a way to make this both appear correctly and play correctly
>> in a midi file?
>
> Similar to an earlier question, no, MIDI doesn't honor or respect repeats.
This is not entirely true. I happily use a super easy way to make this work:
melody = {...}
\unfoldRepeats { \melody }
to generate the MIDI file and for simple repeats like
\repeat volta 2 {...} \alternative {{...}{...}})
that simply works perfect.
Below is the general structure I use.
melody = {...}
basses = {...}
\score {
\new PianoStaff <<
...
>>
\layout {}
}
\score {
\unfoldRepeats {
\new PianoStaff <<
\new Voice = "melody" {
\set Staff.midiInstrument = "accordion"
\melody
}
\new Voice = "basses" {
\set Staff.midiInstrument = "accordion"
\basses
}
>>
}
\midi {
\tempo 4 = 160
}
}
I'm just saying that it would be awesome if I could convince
\unfoldRepeats to be able to obey some more complex scenarios. (But I
believe that tagging will do the trick.)
Mojca