]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/user/percussion.itely
Update from Stefan.
[lilypond.git] / Documentation / user / percussion.itely
1 @c -*- coding: utf-8; mode: texinfo; -*-
2 @ignore
3     Translation of GIT committish: FILL-IN-HEAD-COMMITTISH
4
5     When revising a translation, copy the HEAD committish of the
6     version that you are working on.  See TRANSLATION for details.
7 @end ignore
8
9 @c \version "2.11.51"
10
11 @node Percussion
12 @section Percussion
13
14 @menu
15 * Common notation for percussion::
16 @end menu
17
18 @node Common notation for percussion
19 @subsection Common notation for percussion
20
21 Rhythmic music is primarily used for percussion and drum notation, but it can
22 also be used to show the rhythms of melodies.
23
24 @menu
25 * References for percussion::
26 * Basic percussion notation::
27 * Percussion staves::
28 * Ghost notes::
29 @end menu
30
31 @node References for percussion
32 @subsubsection References for percussion
33
34 @c TODO Add refs
35 TBC
36
37
38 @seealso
39
40 Internals Reference: @rinternals{RhythmicStaff}.
41
42
43 @node Basic percussion notation
44 @subsubsection Basic percussion notation
45
46 @cindex percussion
47 @cindex drums
48
49
50 Percussion notes may be entered in @code{\drummode} mode, which is
51 similar to the standard mode for entering notes.  Each piece of
52 percussion has a full name and an abbreviated name, and both can
53 be used in input files.  The simplest way to enter percussion notes
54 is to use the @code{\drums} command, which creates the correct
55 context and entry mode for percussion:
56
57 @lilypond[quote,ragged-right,verbatim]
58 \drums {
59   hihat hh bassdrum bd
60 }
61 @end lilypond
62
63 This is shorthand for:
64
65 @lilypond[quote,ragged-right,verbatim]
66 \new DrumStaff {
67   \drummode {
68     hihat hh bassdrum bd
69   }
70 }
71 @end lilypond
72
73 Note, that percussion clefs are added automatically in a
74 @code{DrumStaff} context.  But it is possible to use other clefs
75 if you want.
76
77
78 The complete list of drum names is in the init file
79 @file{ly/@/drumpitch@/-init@/.ly}.
80
81 Here is the list of abbreviations You can use in a drum Staff:
82
83 @example
84    bda  acousticbassdrum
85    bd  bassdrum
86    ssh  hisidestick
87    ss  sidestick
88    ssl  losidestick
89    sna  acousticsnare
90    sn  snare
91    hc  handclap
92    sne  electricsnare
93    tomfl  lowfloortom
94    hhc  closedhihat
95    hh  hihat
96    tomfh  highfloortom
97    hhp  pedalhihat
98    toml  lowtom
99    hho  openhihat
100    hhho  halfopenhihat
101    tomml  lowmidtom
102    tommh  himidtom
103    cymca  crashcymbala
104    cymc  crashcymbal
105    tomh  hightom
106    cymra  ridecymbala
107    cymr  ridecymbal
108    cymch  chinesecymbal
109    rb  ridebell
110    tamb  tambourine
111    cyms  splashcymbal
112    cb  cowbell
113    cymcb  crashcymbalb
114    vibs  vibraslap
115    cymrb  ridecymbalb
116    bohm  mutehibongo
117    boh  hibongo
118    boho  openhibongo
119    bolm  mutelobongo
120    bol  lobongo
121    bolo  openlobongo
122    cghm  mutehiconga
123    cglm  muteloconga
124    cgho  openhiconga
125    cgh  hiconga
126    cglo  openloconga
127    cgl  loconga
128    timh  hitimbale
129    timl  lotimbale
130    agh  hiagogo
131    agl  loagogo
132    cab  cabasa
133    mar  maracas
134    whs  shortwhistle
135    whl  longwhistle
136    guis  shortguiro
137    guil  longguiro
138    gui  guiro
139    cl  claves
140    wbh  hiwoodblock
141    wbl  lowoodblock
142    cuim  mutecuica
143    cuio  opencuica
144    trim  mutetriangle
145    tri  triangle
146    trio  opentriangle
147    tt  tamtam
148    ua  oneup
149    ub  twoup
150    uc  threeup
151    ud  fourup
152    ue  fiveup
153    da  onedown
154    db  twodown
155    dc  threedown
156    dd  fourdown
157    de  fivedown
158 @end example
159
160 Note that the normal notation of pitches in a @code{DrumStaff}
161 will cause an error message.
162
163
164
165 Drum rolls are indicated with three slashes across the stem.
166 For quarter notes or longer the three slashes are shown explicitly,
167 eighth notes are shown with two slashes (the beam being the third),
168 and drum rolls shorter than eighths have one stem slash to
169 supplement the beams.  This is achieved with the tremolo notation,
170 @code{:32}, see @ref{Tremolo repeats}.  Here's an example of
171 some snare rolls:
172
173 @lilypond[quote,ragged-right,verbatim]
174 \new DrumStaff
175 \drummode {
176   \time 2/4
177   sn16 sn8 sn16 sn8 sn8:32~ |
178   sn8 sn8 sn4:32~ |
179   sn4 sn8 sn16 sn16 |
180   sn4 r4 |
181 }
182 @end lilypond
183
184 Sticking can be indicated by placing @code{^"R"} or @code{^"L"}
185 after the note.  The @code{staff-padding} property may be
186 overridden to achieve a pleasing baseline.
187
188 @lilypond[quote,ragged-right,verbatim]
189 \drums {
190         \repeat "unfold" 2 { sn16 ^"L" sn^"R" sn^"L" sn^"L" sn^"R" sn^"L"  sn^"R" sn^"R" }
191                                 
192 }
193 @end lilypond
194
195
196 @seealso
197
198 Internals Reference: @rinternals{note-event}.
199
200 @node Percussion staves
201 @subsubsection Percussion staves
202 @cindex percussion
203 @cindex drums
204
205 A percussion part for more than one instrument typically uses a
206 multiline staff where each position in the staff refers to one piece
207 of percussion.
208
209
210 To typeset the music, the notes must be interpreted in a
211 @rinternals{DrumStaff} and @rinternals{DrumVoice} contexts
212
213 @lilypond[quote,ragged-right,verbatim]
214 up = \drummode { crashcymbal4 hihat8 halfopenhihat hh hh hh openhihat }
215 down = \drummode { bassdrum4 snare8 bd r bd sn4 }
216   \new DrumStaff <<
217     \new DrumVoice { \voiceOne \up }
218     \new DrumVoice { \voiceTwo \down }
219   >>
220 @end lilypond
221
222 The above example shows verbose polyphonic notation.  The short
223 polyphonic notation, described in @rlearning{I'm hearing Voices},
224 can also be used if the @rinternals{DrumVoice}s are instantiated
225 by hand first.  For example,
226
227 @lilypond[quote,ragged-right,fragment,verbatim]
228 \new DrumStaff <<
229   \new DrumVoice = "1" { s1 *2 }
230   \new DrumVoice = "2" { s1 *2 }
231   \drummode {
232     bd4 sn4 bd4 sn4
233     <<
234       { \repeat unfold 16 hh16 }
235       \\
236       { bd4 sn4 bd4 sn4 }
237     >>
238   }
239 >>
240 @end lilypond
241
242
243 There are also other layout possibilities.  To use these, set the
244 property @code{drumStyleTable} in context @rinternals{DrumVoice}.
245 The following variables have been predefined
246
247 @table @code
248 @item drums-style
249 This is the default.  It typesets a typical drum kit on a five-line staff
250
251 @lilypond[quote,line-width=10.0\cm]
252 nam = \lyricmode {
253   cymc cyms cymr hh hhc hho hhho hhp
254   cb hc bd sn ss tomh tommh tomml toml tomfh tomfl }
255 mus = \drummode {
256   cymc cyms cymr hh hhc hho hhho hhp \break
257   cb hc bd sn ss tomh tommh tomml toml tomfh tomfl s16 }
258 \score {
259   << \new DrumStaff \with {
260        \remove Bar_engraver
261        \remove Time_signature_engraver
262        \override Stem #'transparent = ##t
263        \override Stem #'Y-extent-callback = ##f
264        \override VerticalAxisGroup #'minimum-Y-extent = #'(-4.0 . 5.0)
265      } \mus
266      \new Lyrics \nam
267   >>
268   \layout {
269     \context {
270       \Score
271       \override LyricText #'font-family = #'typewriter
272       \override BarNumber #'transparent =##T
273     }
274   }
275 }
276 @end lilypond
277
278 The drum scheme supports six different toms.  When there are fewer toms,
279 simply select the toms that produce the desired result, i.e., to get toms
280 on the three middle lines you use @code{tommh}, @code{tomml}, and
281 @code{tomfh}.
282
283 @item timbales-style
284 This typesets timbales on a two line staff
285
286 @lilypond[quote,ragged-right]
287 nam = \lyricmode { timh ssh timl ssl cb }
288 mus = \drummode { timh ssh timl ssl cb s16 }
289
290 <<
291   \new DrumStaff \with {
292     \remove Bar_engraver
293     \remove Time_signature_engraver
294     \override Stem #'transparent = ##t
295     \override Stem #'Y-extent-callback = ##f
296     \override StaffSymbol #'line-count = #2
297     \override StaffSymbol #'staff-space = #2
298     \override VerticalAxisGroup #'minimum-Y-extent = #'(-3.0 . 4.0)
299     drumStyleTable = #timbales-style
300   } \mus
301   \new Lyrics {
302     \override LyricText #'font-family = #'typewriter
303     \nam
304   }
305 >>
306 @end lilypond
307
308 @item congas-style
309 This typesets congas on a two line staff
310
311 @lilypond[quote,ragged-right]
312 nam = \lyricmode { cgh cgho cghm ssh cgl cglo cglm ssl }
313 mus = \drummode { cgh cgho cghm ssh cgl cglo cglm ssl s16 }
314
315 <<
316   \new DrumStaff \with {
317     \remove Bar_engraver
318     \remove Time_signature_engraver
319     drumStyleTable = #congas-style
320     \override StaffSymbol #'line-count = #2
321
322     %% this sucks; it will lengthen stems.
323     \override StaffSymbol #'staff-space = #2
324     \override Stem #'transparent = ##t
325     \override Stem #'Y-extent-callback = ##f
326   } \mus
327   \new Lyrics {
328     \override LyricText #'font-family = #'typewriter
329     \nam
330   }
331 >>
332 @end lilypond
333
334 @item bongos-style
335 This typesets bongos on a two line staff
336
337 @lilypond[quote,ragged-right]
338 nam = \lyricmode { boh boho bohm ssh bol bolo bolm ssl }
339 mus = \drummode { boh boho bohm ssh bol bolo bolm ssl s16 }
340
341 <<
342   \new DrumStaff \with {
343     \remove Bar_engraver
344     \remove Time_signature_engraver
345     \override StaffSymbol #'line-count = #2
346     drumStyleTable = #bongos-style
347
348     %% this sucks; it will lengthen stems.
349     \override StaffSymbol #'staff-space = #2
350     \override Stem #'transparent = ##t
351     \override Stem #'Y-extent-callback = ##f
352   } \mus
353   \new Lyrics {
354     \override LyricText #'font-family = #'typewriter
355     \nam
356   }
357 >>
358 @end lilypond
359
360 @item percussion-style
361 To typeset all kinds of simple percussion on one line staves.
362
363 @lilypond[quote,ragged-right]
364 nam = \lyricmode { tri trio trim gui guis guil cb cl tamb cab mar hc }
365 mus = \drummode { tri trio trim gui guis guil cb cl tamb cab mar hc s16 }
366
367 <<
368   \new DrumStaff \with{
369     \remove Bar_engraver
370     drumStyleTable = #percussion-style
371     \override StaffSymbol #'line-count = #1
372     \remove Time_signature_engraver
373     \override Stem #'transparent = ##t
374     \override Stem #'Y-extent-callback = ##f
375   } \mus
376   \new Lyrics {
377     \override LyricText #'font-family = #'typewriter
378     \nam
379   }
380 >>
381 @end lilypond
382 @end table
383
384 If you do not like any of the predefined lists you can define your own
385 list at the top of your file
386
387 @lilypond[quote,ragged-right,verbatim]
388 #(define mydrums '(
389          (bassdrum     default   #f         -1)
390          (snare        default   #f         0)
391          (hihat        cross     #f         1)
392          (pedalhihat   xcircle   "stopped"  2)
393          (lowtom       diamond   #f         3)))
394 up = \drummode { hh8 hh hh hh hhp4 hhp }
395 down = \drummode { bd4 sn bd toml8 toml }
396
397 \new DrumStaff <<
398   \set DrumStaff.drumStyleTable = #(alist->hash-table mydrums)
399   \new DrumVoice { \voiceOne \up }
400   \new DrumVoice { \voiceTwo \down }
401 >>
402 @end lilypond
403
404
405 @seealso
406
407 Init files: @file{ly/@/drumpitch@/-init@/.ly}.
408
409 Internals Reference: @rinternals{DrumStaff}, @rinternals{DrumVoice}.
410
411 @knownissues
412
413 Because general MIDI does not contain rim shots, the sidestick is used
414 for this purpose instead.
415
416
417 @c TODO: check name -gp
418 @node Ghost notes
419 @subsubsection Ghost notes
420
421 Ghost notes for drums and percussion may be created using the
422 @code{\parenthesize} command detailed in @ref{Parentheses}.  However,
423 the default @code{\drummode} does
424 not include the @code{Parenthesis_engraver} plugin which allows
425 this.
426
427 @lilypond[quote,ragged-right,verbatim,fragment]
428 \new DrumStaff \with {
429   \consists "Parenthesis_engraver"
430 } <<
431   \context DrumVoice  = "1"  { s1 *2 }
432   \context DrumVoice  = "2" { s1 *2 }
433   \drummode {
434     <<
435       {
436         hh8[ hh] <hh sn> hh16
437         < \parenthesize sn > hh < \parenthesize
438         sn > hh8 <hh sn> hh
439       } \\ {
440         bd4 r4 bd8 bd r8 bd
441       }
442     >>
443   }
444 >>
445 @end lilypond
446
447 @noindent
448 Also note that you must add chords (@code{< >} brackets)
449 around each @code{\parenthesize} statement.
450
451
452