summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2017-02-23 11:59:26 +0100
committerRicardo Wurmus <rekado@elephly.net>2017-02-23 11:59:26 +0100
commit15e26d5cf1cc3ffc0b28db94744bfc33b4932409 (patch)
tree1a3e4e62f664c744d392bac5e676dc5d92dd096f
parent42da410946a5f6338922e07ba85001fa51660d56 (diff)
Make all songs share the same score layouts.
-rw-r--r--01-song1/01-song1.ly33
-rw-r--r--02-song2/02-song2.ly31
-rw-r--r--02-song2/music/click.ly1
-rw-r--r--03-circus/03-circus.ly32
-rw-r--r--03-circus/music/click.ly1
-rw-r--r--04-white-noise/04-white-noise.ly30
-rw-r--r--04-white-noise/music/click.ly1
-rw-r--r--layouts.ly32
8 files changed, 39 insertions, 122 deletions
diff --git a/01-song1/01-song1.ly b/01-song1/01-song1.ly
index 7f85e93..d66b0da 100644
--- a/01-song1/01-song1.ly
+++ b/01-song1/01-song1.ly
@@ -48,35 +48,4 @@ AllMusic = <<
} { \stick }
>>
-%% Two scores are needed: one with drums for MIDI and the other for
-%% notation.
-\score {
- \unfoldRepeats {
- <<
- \AllMusic
- \new DrumStaff { \click }
- >>
- }
- \midi { \tempo 4 = 180 }
-}
-
-\score {
- %% Always unfold repeats in the big score. The individual parts can
- %% have repeats as they wish.
- \unfoldRepeats { \AllMusic }
- \layout {
- \tempo 4 = 180
- \context {
- %% add the RemoveEmptyStaffContext that erases rest-only staves
- \Staff \RemoveEmptyStaves
- }
- \context {
- \Score
- \numericTimeSignature
- %% Remove all-rest staves also in the first system
- \override VerticalAxisGroup.remove-first = ##t
- %% If only one non-empty staff in a system exists, still print the starting bar
- \override SystemStartBar.collapse-height = #1
- }
- }
-}
+\include "../layouts.ly"
diff --git a/02-song2/02-song2.ly b/02-song2/02-song2.ly
index e8c2327..b563088 100644
--- a/02-song2/02-song2.ly
+++ b/02-song2/02-song2.ly
@@ -55,33 +55,4 @@ AllMusic = <<
} { \tabChordRepeats \guitar }
>>
-%% Two scores are needed: one with unfolded repeats for MIDI and the
-%% other with regular repeats for notation.
-\score {
- \unfoldRepeats {
- <<
- \AllMusic
- \new DrumStaff { \click }
- >>
- }
- \midi { \tempo 4 = 90 }
-}
-
-\score {
- \AllMusic
- \layout {
- \tempo 4 = 90
- \context {
- %% add the RemoveEmptyStaffContext that erases rest-only staves
- \Staff \RemoveEmptyStaves
- }
- \context {
- \Score
- \numericTimeSignature
- %% Remove all-rest staves also in the first system
- \override VerticalAxisGroup.remove-first = ##t
- %% If only one non-empty staff in a system exists, still print the starting bar
- \override SystemStartBar.collapse-height = #1
- }
- }
-}
+\include "../layouts.ly"
diff --git a/02-song2/music/click.ly b/02-song2/music/click.ly
index eaccc18..ee30e48 100644
--- a/02-song2/music/click.ly
+++ b/02-song2/music/click.ly
@@ -1,5 +1,6 @@
click = \drummode {
\time 4/4
+ \tempo 4 = 90
%% intro
\repeat unfold 8 { hh4 hh hh hh |}
diff --git a/03-circus/03-circus.ly b/03-circus/03-circus.ly
index 18132ce..c28f1b4 100644
--- a/03-circus/03-circus.ly
+++ b/03-circus/03-circus.ly
@@ -50,34 +50,4 @@ AllMusic = <<
} { \stick }
>>
-%% Two scores are needed: one with unfolded repeats for MIDI and the
-%% other with regular repeats for notation.
-\score {
- \unfoldRepeats {
- <<
- \AllMusic
- \new DrumStaff { \click }
- >>
- }
- \midi { \tempo 4 = 120 }
-}
-
-\score {
- \AllMusic
- \layout {
- \tempo 4 = 120
- \context {
- %% add the RemoveEmptyStaffContext that erases rest-only staves
- \Staff \RemoveEmptyStaves
- }
- \context {
- \Score
- \numericTimeSignature
- markFormatter = #format-mark-box-alphabet
- %% Remove all-rest staves also in the first system
- \override VerticalAxisGroup.remove-first = ##t
- %% If only one non-empty staff in a system exists, still print the starting bar
- \override SystemStartBar.collapse-height = #1
- }
- }
-}
+\include "../layouts.ly"
diff --git a/03-circus/music/click.ly b/03-circus/music/click.ly
index df88100..6e7c3d8 100644
--- a/03-circus/music/click.ly
+++ b/03-circus/music/click.ly
@@ -1,6 +1,7 @@
click = \drummode {
%% intro
\time 2/4
+ \tempo 4 = 120
hh4 hh | hh hh |
\repeat volta 2 {
hh4 hh | hh hh |
diff --git a/04-white-noise/04-white-noise.ly b/04-white-noise/04-white-noise.ly
index 3ec5c3a..8073a56 100644
--- a/04-white-noise/04-white-noise.ly
+++ b/04-white-noise/04-white-noise.ly
@@ -48,32 +48,4 @@ AllMusic = <<
} { \stick }
>>
-%% Two scores are needed: one with unfolded repeats for MIDI and the
-%% other with regular repeats for notation.
-\score {
- \unfoldRepeats {
- <<
- \AllMusic
- \new DrumStaff { \click }
- >>
- }
- \midi { \tempo 4 = 120 }
-}
-
-\score {
- \AllMusic
- \layout {
- \tempo 4 = 120
- \context {
- %% add the RemoveEmptyStaffContext that erases rest-only staves
- \Staff \RemoveEmptyStaves
- }
- \context {
- \Score
- %% Remove all-rest staves also in the first system
- \override VerticalAxisGroup.remove-first = ##t
- %% If only one non-empty staff in a system exists, still print the starting bar
- \override SystemStartBar.collapse-height = #1
- }
- }
-}
+\include "../layouts.ly"
diff --git a/04-white-noise/music/click.ly b/04-white-noise/music/click.ly
index c95d3d8..c66feb2 100644
--- a/04-white-noise/music/click.ly
+++ b/04-white-noise/music/click.ly
@@ -1,6 +1,7 @@
click = \drummode {
%% intro
\time 4/4
+ \tempo 4 = 120
\repeat unfold 2 {
hh4 hh hh hh | hh hh hh hh |
hh hh hh hh | hh hh hh hh |
diff --git a/layouts.ly b/layouts.ly
new file mode 100644
index 0000000..b382da2
--- /dev/null
+++ b/layouts.ly
@@ -0,0 +1,32 @@
+%% Two scores are needed to separately control MIDI and notation
+%% output.
+\score {
+ \unfoldRepeats {
+ <<
+ \AllMusic
+ \new DrumStaff { \click }
+ >>
+ }
+ \midi {}
+}
+
+\score {
+ %% Always unfold repeats in the big score. The individual parts can
+ %% have repeats as they wish.
+ \unfoldRepeats { \AllMusic }
+ \layout {
+ \context {
+ %% add the RemoveEmptyStaffContext that erases rest-only staves
+ \Staff \RemoveEmptyStaves
+ }
+ \context {
+ \Score
+ \numericTimeSignature
+ markFormatter = #format-mark-box-alphabet
+ %% Remove all-rest staves also in the first system
+ \override VerticalAxisGroup.remove-first = ##t
+ %% If only one non-empty staff in a system exists, still print the starting bar
+ \override SystemStartBar.collapse-height = #1
+ }
+ }
+}