1.6.3 パートを記述する

このセクションでは、テンポ指示と楽器名を楽譜に挿入する方法について説明します。他のボイスを引用する方法と、演奏指示音符を譜刻する方法についても記述します。


楽器名

Staff, PianoStaff, StaffGroup, GrandStaff それに ChoirStaff コンテキストの中にある譜の左側に、楽器名を譜刻することができます。instrumentName の値が最初の行の譜に対して使用され、shortInstrumentName の値がそれに続くすべての行の譜に対して使用されます。

\set Staff.instrumentName = #"Violin "
\set Staff.shortInstrumentName = #"Vln "
c4.. g'16 c4.. g'16
\break
c1

[image of music]

マークアップ モードを用いて、より複雑な楽器名を作成することができます:

\set Staff.instrumentName = \markup {
  \column { "Clarinetti"
            \line { "in B" \smaller \flat } } }
c4 c,16 d e f g2

[image of music]

2 つ以上の譜コンテキストが一緒になってグループ化されている場合、デフォルトでは楽器名と短縮楽器名は中央揃えされます。複数行にわたる楽器名を中央揃えするには、\center-column を用いる必要があります:

<<
  \new Staff {
    \set Staff.instrumentName = #"Flute"
    f2 g4 f
  }
  \new Staff {
    \set Staff.instrumentName = \markup \center-column {
      Clarinet
      \line { "in B" \smaller \flat }
    }
    c4 b c2
  }
>>

[image of music]

しかしながら、楽器名が長い場合、indent 設定と short-indent 設定の値を増やさない限り、譜グループの中にある楽器名は中央揃えされません。これらの設定についての詳細は \paper variables for shifts and indents を参照してください。

\layout {
  indent = 3.0\cm
  short-indent = 1.5\cm
}

\relative c'' <<
  \new Staff {
    \set Staff.instrumentName = #"Alto Flute in G"
    \set Staff.shortInstrumentName = #"Fl."
    f2 g4 f \break
    g4 f g2
  }
  \new Staff {
    \set Staff.instrumentName = #"Clarinet"
    \set Staff.shortInstrumentName = #"Clar."
    c,4 b c2 \break
    c2 b4 c
  }
>>

[image of music]

楽器名を他のコンテキスト (ChordNamesFiguredBass など) に付け加えるには、 そのコンテキストに Instrument_name_engraver を追加する必要があります。詳細は Modifying context plug-ins を参照してください。

楽曲の途中で楽器名を変更することもできます。しかしながら、instrumentName は最初の行の譜にしか表示されないため、楽曲の途中では表示されないことを思い出してください:

\set Staff.instrumentName = #"First"
\set Staff.shortInstrumentName = #"one"
c1 c c c \break
c1 c c c \break
\set Staff.instrumentName = #"Second"
\set Staff.shortInstrumentName = #"two"
c1 c c c \break
c1 c c c \break

[image of music]

楽器の 切り替え が必要な場合、切り替えのために必要とされる変更の詳細なリストを作成するために、\addInstrumentDefinition\instrumentSwitch と組み合わせて使用することがあります。\addInstrumentDefinition コマンドは 2 つの引数をとります: 識別文字列と、楽器で使用されるコンテキスト プロパティと値の連想リストです。このコマンドは最上位のスコープに配置する必要があります。\instrumentSwitch は音楽表記の中で使用され、楽器の切り替えを宣言します:

\addInstrumentDefinition #"contrabassoon"
  #`((instrumentTransposition . ,(ly:make-pitch -1 0 0))
     (shortInstrumentName . "Cbsn.")
     (clefGlyph . "clefs.F")
     (middleCPosition . 6)
     (clefPosition . 2)
     (instrumentCueName . ,(make-bold-markup "cbsn."))
     (midiInstrument . "bassoon"))

\new Staff \with {
  instrumentName = #"Bassoon"
}
\relative c' {
  \clef tenor
  \compressFullBarRests
  c2 g'
  R1*16
  \instrumentSwitch "contrabassoon"
  c,,2 g \break
  c,1 ~ | c1
}

[image of music]

参照

記譜法リファレンス: \paper variables for shifts and indents, Modifying context plug-ins

コード断片集: Staff notation

内部リファレンス: InstrumentName, PianoStaff, Staff


他のボイスを引用する

あるボイスが他のボイスの音楽の一部を兼ねることはごく一般的なことです。例えば、第 1 バイオリンと第2バイオリンは、音楽のあるパッセージの間、同じ音符を演奏することがあるかもしれません。LilyPond では、あるボイスに他のボイスを 引用 させることによって実現されます。再入力する必要はありません。

パートを引用するには、\addQuote コマンドを用いて引用する部分を初期化する必要があります。このコマンドは最上位のスコープで使用しなければなりません。1 番目の引数は識別文字列であり、2 番目の引数は音楽表記です:

flute = \relative c'' {
  a4 gis g gis
}
\addQuote "flute" { \flute }

\quoteDuring コマンドを用いて、引用を開始する位置を示します。このコマンドは 2 つの引数をとります: \addQuote で定義した引用するボイスの名前と、引用部分の演奏時間を示す音楽表記 – 通常、これは空白休符か複数小節にわたる休符 – です。引用されるボイスの音楽から該当部分の音楽 (アーティキュレーション、強弱記号、マークアップ等を含みます) が音楽表記に挿入されます:

flute = \relative c'' {
  a4 gis g->\f gis^\markup{quoted}
}
\addQuote "flute" { \flute }

\relative c' {
  c4 cis \quoteDuring #"flute" { s2 }
}

[image of music]

\quoteDuring で使用される音楽表記に空白休符や複数小節休符以外のものが含まれている場合、多声部になります。これは望まない結果であることがしばしばあります:

flute = \relative c'' {
  a4 gis g->\f gis^\markup{quoted}
}
\addQuote "flute" { \flute }

\relative c' {
  c4 cis \quoteDuring #"flute" { s2 }
}

[image of music]

\transposition が使用される場合、引用機能はソースとターゲット両方の楽器の楽器移調設定を考慮します。\transposition についての詳細は 楽器の移調 を参照してください。

clarinet = \relative c'' {
  \transposition bes
  a4 gis g gis
}
\addQuote "clarinet" { \clarinet }

\relative c' {
  c4 cis \quoteDuring #"clarinet" { s2 }
}

[image of music]

引用部分に固有名のタグを付けて、引用部分をさまざまな形で処理することができます。この手法についての詳細は Using tags を参照してください。

quotedEventTypes プロパティを変更することで、オリジナル ボイスからどのオブジェクトを引用するか調節することもできます。デフォルトで、このプロパティの値は #'(StreamEvent) であり、すべてを引用します。例えば、この値を #'(note-event rest-event tie-event) に変更すると、LilyPond は音符、休符それにタイを引用し、アーティキュレーション、マーックアップあるいは強弱記号は引用しません。

clarinet = \relative c'' {
  a4 gis g->\f gis^\markup{quoted}
}
\addQuote "clarinet" { \clarinet }

\relative c' {
  \set Score.quotedEventTypes = #'(note-event rest-event tie-event)
  c4 cis \quoteDuring #"clarinet" { s2 }
}

[image of music]

Selected Snippets

Quoting another voice with transposition

Quotations take into account the transposition of both source and target. In this example, all instruments play sounding middle C; the target is an instrument in F. The target part may be transposed using \transpose. In this case, all the pitches (including the quoted ones) are transposed.

\addQuote clarinet {
  \transposition bes
  \repeat unfold 8 { d'16 d' d'8 }
}

\addQuote sax {
  \transposition es'
  \repeat unfold 16 { a8 }
}

quoteTest = {
  % french horn
  \transposition f
  g'4
  << \quoteDuring #"clarinet" { \skip 4 } s4^"clar." >>
  << \quoteDuring #"sax" { \skip 4 } s4^"sax." >>
  g'4
}

{
  \set Staff.instrumentName =
    \markup {
      \center-column { Horn \line { in F } }
    }
  \quoteTest
  \transpose c' d' << \quoteTest s4_"up a tone" >>
}

[image of music]

Quoting another voice

The quotedEventTypes property determines the music event types which should be quoted. The default value is (note-event rest-event tie-event beam-event tuplet-span-event), which means that only the notes, rests, ties, beams and tuplets of the quoted voice will appear in the \quoteDuring expression. In the following example, a 16th rest is not quoted since rest-event is not in quotedEventTypes.

For a list of event types, consult the “Music classes” section of the Internals Reference.

quoteMe = \relative c' {
  fis4 r16 a8.-> b4\ff c
}
\addQuote quoteMe \quoteMe

original = \relative c'' {
  c8 d s2
  \once \override NoteColumn #'ignore-collision = ##t
  es8 gis8
}

<<
  \new Staff {
    \set Staff.instrumentName = #"quoteMe"
    \quoteMe
  }
  \new Staff {
    \set Staff.instrumentName = #"orig"
    \original
  }
  \new Staff \relative c'' <<
    \set Staff.instrumentName = #"orig+quote"
    \set Staff.quotedEventTypes =
      #'(note-event articulation-event)
    \original
    \new Voice {
      s4
      \set fontSize = #-4
      \override Stem #'length-fraction = #(magstep -4)
      \quoteDuring #"quoteMe" { \skip 2. }
    }
  >>
>>

[image of music]

参照

記譜法リファレンス: 楽器の移調, Using tags

コード断片集: Staff notation

内部リファレンス: QuoteMusic, Voice

既知の問題と警告

\addQuote 中にある最初の Voice の内容だけが引用されます。そのため、music には他の Voice に切り替わる \new\context Voice を含めることはできません。

装飾小音符を引用しようとしてもうまくいかず、LilyPond がクラッシュする可能性さえあります。

ネストされた連符を引用しようとしてもうまくいきません。

以前のバージョンの LilyPond (2.11 よりも前) では、addQuote はすべて小文字 – addquote – で記述されていました。


合図音符をフォーマットする

前のセクションでは、引用を作成する方法について説明しました。\cueDuring コマンドは \quoteDuring コマンドのより特殊な形であり、あるパートに合図音符を挿入する場合に有用です。構文は以下の通りです:

\cueDuring #partname #voice music

このコマンドは partname の該当する小節から音符と休符だけを CueVoice にコピーします。CueVoice は暗黙的に作成されて music と同時進行し、結果として多声になります。引数 voice は合図音符を第 1 ボイスとして記譜すべきか、第 2 ボイスとして記譜すべきかを決定します。UP は第 1 ボイスに相当し、DOWN は第 2 ボイスに相当します。

oboe = \relative c'' {
  r2 r8 d16(\f f e g f a)
  g8 g16 g g2.
}
\addQuote "oboe" { \oboe }

\new Voice \relative c'' {
  \cueDuring #"oboe" #UP { R1 }
  g2 c,
}

[image of music]

上の例で、Voice コンテキストは明示的に宣言されている必要があります。さもなければ、音楽表記全体が CueVoice コンテキストに属してしまいます。

instrumentCueName プロパティを設定することによって、\cueDuring で音楽のどの側面を引用するか調節することができます。このプロパティのデフォルト値は #'(note-event rest-event tie-event beam-event tuplet-span-event) であり、音符、休符、タイ、連桁それに連符だけが引用され、アーティキュレーション、強弱記号、マークアップ等は引用されません。

oboe = \relative c'' {
  r2 r8 d16(\f f e g f a)
  g8 g16 g g2.
}
\addQuote "oboe" { \oboe }

\new Voice \relative c'' {
  \set Score.quotedCueEventTypes = #'(note-event rest-event tie-event
                                      beam-event tuplet-span-event
                                      dynamic-event slur-event)
  \cueDuring #"oboe" #UP { R1 }
  g2 c,
}

[image of music]

マークアップを使用して引用される楽器の名前を表示することができます。また、合図音符が音部変更を必要とする場合、合図音符の終わりで元の音部に戻す必要があります。

flute = \relative c'' {
  r2. c4 d8 c d e fis2 g2 d2
}
bassoon = \relative c {
  \clef bass
  R1
  \clef treble
  s1*0^\markup { \tiny "flute" }
  \cueDuring #"flute" #UP { R1 }
  \clef bass
  g4. b8 d2
}
\addQuote "flute" { \flute }
\new Staff {
  \bassoon
}

[image of music]

\killCues コマンドは音楽表記から合図音符を削除します。これにより、同じ音楽表記を使って合図を持つ楽器パートと総譜を作り出すことが可能です。\killCues コマンドは \cueDuring によって引用された音符とイベントだけを削除します。合図に関連する他のマークアップ – 音部変更と引用元の楽器を識別するラベルなど – にはタグを付けて総譜に含めるかどうかを選択することができます。Using tags を参照してください。

flute = \relative c'' {
  r2. c4 d8 c d e fis2 g2 d2
}
bassoon = \relative c {
  \clef bass
  R1
  \tag #'part {
    \clef treble
    s1*0^\markup { \tiny "flute" }
  }
  \cueDuring #"flute" #UP { R1 }
  \tag #'part \clef bass
  g4. b8 d2
}
\addQuote "flute" { \flute }

\new Staff {
  \bassoon
}
\new StaffGroup <<
  \new Staff {
    \flute
  }
  \new Staff {
    \removeWithTag #'part { \killCues { \bassoon } }
  }
>>

[image of music]

あるいはまた、音部変更や楽器ラベルを再利用するために、\addInstrumentDefinition を用いて楽器の定義に含めることができます。\addInstrumentDefinition についての説明は 楽器名 を参照してください。

\quoteDuring と同様に、\cueDuring は楽器の移調を考慮します。合図音符は、合図を受け取る楽器のピッチで作り出されます。

合図音符を移調させるには \transposedCueDuring を使用します。このコマンドはコンサート ミドル C の音を表すピッチを (絶対モードで) 指定する追加の引数を取ります。

piccolo = \relative c''' {
  \clef "treble^8"
  R1
  c8 c c e g2
  c4 g g2
}
bassClarinet = \relative c' {
  \key d \major
  \transposition bes,
  d4 r a r
  \transposedCueDuring #"piccolo" #UP d { R1 }
  d4 r a r
}

\addQuote "piccolo" { \piccolo }

<<
  \new Staff \piccolo
  \new Staff \bassClarinet
>>

[image of music]

小さなサイズの音符が必要な場合、CueVoice コンテキストを明示的に作成することがあります。例えば、本来の演奏とは異なる音符列をオリジナル ボイスの上または下にセットする場合に適しています。

\time 12/8
\key ees \major
g4 ees8 f4 g8
\stemDown
<<
  { d4. bes4 c8 }
  \new CueVoice
  { g'4. f4 ees8 }
>>
\stemUp
d2. d2.

[image of music]

参照

記譜法リファレンス: 楽器の移調, 楽器名, Musical cues, Using tags

コード断片集: Staff notation

内部リファレンス: CueVoice, Voice

既知の問題と警告

\cueDuring を使用した場合、Voice コンテキストと CueVoice コンテキストの間で休符の衝突が発生する可能性があります。


他の言語: English, deutsch, español, français

LilyPond — 記譜法リファレンス