From 49d14358c33b7d0ba7e7c381f91943617c7723ea Mon Sep 17 00:00:00 2001 From: Erich Eckner Date: Wed, 10 Sep 2014 17:47:07 +0200 Subject: Hauke eingefügt MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hr/michi/whitacre/rose/midi.lua | 53 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) create mode 100644 hr/michi/whitacre/rose/midi.lua (limited to 'hr/michi/whitacre/rose/midi.lua') diff --git a/hr/michi/whitacre/rose/midi.lua b/hr/michi/whitacre/rose/midi.lua new file mode 100644 index 0000000..8aef7d6 --- /dev/null +++ b/hr/michi/whitacre/rose/midi.lua @@ -0,0 +1,53 @@ + -- some settings -- vim: ai sw=2 lbr nu et + +pre=[[ +%some settings% vim: ai sw=2 lbr nu et + +\version "2.12" +\include "stimmen.ly" + + \score { + << + \unfoldRepeats +]] + +post=[[ + >> + \midi { + \context{ + %\Score + %tempoWholesPerMinute = #(ly:make-moment 100 4) + } + } + } +]] + +voices={ "s", "a", "t", "b" } +expand = { s="sopran", a="alt", t="tenor", b="bass" } +map = { sopran="soprane", alt="alti", tenor="tenoere", bass="baesse" } + +function text(stimme) + return +[[ + \new Staff = ]]..stimme..[[ << + %\new Voice = "meta" { s1*<+Anzahl der Takte+> \bar "|." } + \new Voice = "]]..map[stimme]..[[" { \global \]]..stimme..[[Melodie } + >> +]] +end + +function err() print("oops") os.exit() end + +which=which or "satb" +if type(which)~="string" then err() end + +for _,v in pairs(voices) do + if string.find(which, v) then pre=pre..text(expand[v]) end +end + +input=pre..post + +--os.execute(lilypond -...) +io.stdout:write(input) +os.exit() + -- cgit v1.2.3-70-g09d2