lilypond-user
[Top][All Lists]
Advanced

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

Printing transposed versions


From: Peter Dixon
Subject: Printing transposed versions
Date: Sat, 7 Dec 2002 21:39:25 -0000

On 06 Dec 2002 at 20:28, Simon Bailey wrote:
<snip>
> i recently typeset a march for our concert band. we have instruments in
> F, E-flat, B-flat, C and one crazy guy who plays a D trumpet, but cannot
> transpose. using lilypond, i could write all parts of the march for c
> instruments and just transpose the parts to the correct keys for the
> relative instruments. including a part for the d-trumpet which was a
> matter of changing one line of code...
<snip>

I have been doing a similar exercise.  After having done 8 songs, changing
two lines (transpose line and a subtitle to say which instrument) and
recompiling for each instrument, I got fed up and decided to try automating
it.  I wrote an \include .ly file (see below) which is included in each
song.  The main script produces a score with harmony and guitar chords for
keyboard, etc, and the \include script produces scores on separate pages for
all the instruments, properly headed and transposed.

Hope it helps

Peter Dixon

----------------------------------------------------------------
% songinstruments.ly
% common code to set a song for flute, clarinet and sax
% calling script must define voicea and lyrica
% use 'piece' for title so that it appears on every page
% use pagenumber = "no" to kill numbering

%Peter Dixon 20021104

\score {
\addlyrics \context Staff = flute {
\property Staff.automaticMelismata = ##t
\notes \transpose c'' \voicea
}
\context Lyrics = flyric \lyrica
\header {
opus = "\\newpage Flute"
}
\paper {indent = 0.0}
}

\score {
\addlyrics \context Staff = clar {
\property Staff.automaticMelismata = ##t
\notes \transpose d' \voicea
}
\context Lyrics = clyric \lyrica
\header {
opus = "\\newpage Clarinet (b-flat)"
}
\paper {indent = 0.0}
}

\score {
\addlyrics \context Staff = sax {
\property Staff.automaticMelismata = ##t
\notes \transpose a' \voicea
}
\context Lyrics = slyric \lyrica
\header {
opus = "\\newpage Saxaphone (e-flat)"
}
\paper {indent = 0.0}
}






reply via email to

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