@c -*- coding: utf-8; mode: texinfo; documentlanguage: ja -*-
@ignore
- Translation of GIT committish: d5647c5fd1c38d4124d2374725b923f4901f3661
+ Translation of GIT committish: 9bb7fa99aa8bc7c14a45a42224545c726bb6c592
When revising a translation, copy the HEAD committish of the
version that you are working on. For details, see the Contributors'
Guide, node Updating translation committishes..
@end ignore
-@c \version "2.16.0"
+@c \version "2.19.22"
-@c Translators: Yoshiki Sawada
+@c Translators: Tomohiro Tatejima, Yoshiki Sawada
@c Translation status: post-GDP
@node 基礎となるコンセプト
\header @{ @}
\score @{
- @var{...複合音楽表記...} % すべての音楽がここに入ります!
+ @var{ @dots{} 複合音楽表記 @dots{} } % すべての音楽がここに入ります!
\layout @{ @}
\midi @{ @}
@}
しかしながら、この例はスタート地点として役に立ちます。
@funindex \book
-@funindex book
@funindex \score
-@funindex score
@cindex book
@cindex score
LilyPond は以下のような入力:
@example
-\relative c'' @{
- c4 a d c
+\relative @{
+ c''4 a d c
@}
@end example
\score @{
\new Staff @{
\new Voice @{
- \relative c'' @{
- c4 a b c
+ \relative @{
+ c''4 a b c
@}
@}
@}
@code{\score} ブロックは常にただ 1 つの音楽表記を@c
保持していなければなりません。@c
-そして、その音楽表記は @code{\score} コマンドのすぐ後に@c
-置かれなければなりません。@c
音楽表記は単一の音符である場合もありますし、以下のような@c
巨大な複合表記である場合もあるということを覚えておいてください:
@example
@{
\new StaffGroup <<
- @var{...ワーグナーのオペラの楽譜全体がここに入ります...}
+ @var{ @dots{} ワーグナーのオペラの楽譜全体がここに入ります @dots{} }
>>
@}
@end example
@noindent
-すべては @code{@{ ... @}} の内部にあるため、@c
+すべては @code{@{ @dots{} @}} の内部にあるため、@c
それは 1 つの音楽表記であるとカウントされます。
以前見てきたように、@code{\score} ブロックは他のものを含む可能性もあります。@c
@end example
@funindex \header
-@funindex header
@funindex \layout
-@funindex layout
@funindex \midi
-@funindex midi
@cindex header (ヘッダ)
@cindex layout (レイアウト)
@cindex midi
それらが上記のように記述された場合、LilyPond はそれぞれ譜刻された楽譜と
MIDI 出力を作り出します。@c
それらは記譜法リファレンスの @ruser{Score layout} と
-@ruser{Creating MIDI files} で完全に記述されています。
+@ruser{Creating MIDI output} で完全に記述されています。
@cindex scores, multiple (複数の Score)
@cindex book block, implicit (暗黙の book ブロック)
@cindex implicit book block (暗黙の book ブロック)
@funindex \book
-@funindex book
あなたは複数の @code{\score} ブロックを記述するかもしれません。@c
それらはそれぞれ別々の楽譜として扱われますが、それらは結合されて@c
すべてのテンプレートがこれを使っています:
@example
-melody = \relative c' @{
- c4 a b c
+melody = \relative @{
+ c'4 a b c
@}
\score @{
@translationof Score is a (single) compound musical expression
@funindex \score
-@funindex score
@cindex score
@cindex contents of a score block (score ブロックの内容)
@cindex score block, contents of (score ブロックの内容)
以下の行がこの謎についてすべてを説明しています:
@quotation
-@emph{@code{\score} ブロックは 1 つの複合音楽表記で始まらなくてはなりません。}
+@emph{@code{\score} ブロックはただ 1 つの音楽表記のみを含まなくてはなりません。}
@end quotation
@noindent
-é\9f³æ¥½è¡¨è¨\98ã\81¨è¤\87å\90\88é\9f³æ¥½è¡¨è¨\98ã\81\8cæ\84\8få\91³ã\81\97ã\81¦ã\81\84ã\82\8bã\82\82ã\81®ã\82\92ç\90\86解ã\81\99ã\82\8bã\81«ã\81¯ã\80\81ã\83\81ã\83¥ã\83¼ã\83\88ã\83ªã\82¢ã\83«ã\81®
+音楽表記が意味しているものを理解するには、チュートリアルの
@ref{音楽表記についての説明} を読み返すと役に立つかもしれません。@c
そこでは、小さな音楽表記 -- 音符から始めて、それから和音など -- から@c
大きな音楽表記を構築する方法を説明しています。@c
@end example
@end ignore
-歌手とピアノが同時進行であることを示すために @code{@{ ... @}} の代わりに
-@code{<< ... >>} を使用するということを思い出してください。@c
+歌手とピアノが同時進行であることを示すために @code{@{ @dots{} @}} の代わりに
+@code{<< @dots{} >>} を使用するということを思い出してください。@c
こうすることで、ボーカル パートはピアノ パートの上に表示されます。@c
上の例で歌手の譜が一続きの音楽表記を保持するだけであるのなら
-@code{<< ... >>} を使う必要はありませんが、@c
+@code{<< @dots{} >>} を使う必要はありませんが、@c
譜が同時進行する複数の音楽表記
-- 例えば、同時進行する 2 つの声部や、声部と歌詞です
-- を保持するのであれば必須となります。@c
@code{\new Voice = "vocal"} の後の波括弧の中に、以下を書き加えることができます:
@example
-\relative c'' @{
- r4 d8\noBeam g, c4 r
+\relative @{
+ r4 d''8\noBeam g, c4 r
@}
@end example
これで、実際の楽譜の一部ができます:
@lilypond[verbatim,quote,ragged-right]
-melody = \relative c'' { r4 d8\noBeam g, c4 r }
+melody = \relative { r4 d''8\noBeam g, c4 r }
text = \lyricmode { And God said, }
-upper = \relative c'' { <g d g,>2~ <g d g,> }
-lower = \relative c { b2 e }
+upper = \relative { <g' d g,>2~ <g d g,> }
+lower = \relative { b,2 e }
\score {
<<
@lilypond[verbatim,quote,ragged-right]
\new Staff {
- \relative g' {
- r4 g8 g c4 c8 d |
+ \relative {
+ r4 g'8 g c4 c8 d |
e4 r8
<<
{ f8 c c }
@lilypond[verbatim,quote,ragged-right]
\new Staff = "main" {
- \relative g' {
- r4 g8 g c4 c8 d |
+ \relative {
+ r4 g'8 g c4 c8 d |
e4 r8
<<
{ f8 c c }
@multitable @columnfractions .3 .7
@headitem 括弧のタイプ
@tab 機能
-@item @code{@{ .. @}}
+@item @code{@{ @dots{} @}}
@tab 一続きの音楽を囲みます
-@item @code{< .. >}
+@item @code{< @dots{} >}
@tab 和音となる音符を囲みます
-@item @code{<< .. >>}
+@item @code{<< @dots{} >>}
@tab 同時進行する音楽表記を囲みます
-@item @code{( .. )}
+@item @code{( @dots{} )}
@tab スラーの開始点と終了点を意味します
-@item @code{\( .. \)}
+@item @code{\( @dots{} \)}
@tab フレージング スラーの開始点と終了点を意味します
-@item @code{[ .. ]}
+@item @code{[ @dots{} ]}
@tab 手動連桁の開始点と終了点を意味します
@end multitable
こららに対して、音符の間や音符をまたがって線を生成する他の構文を@c
付け加えるべきです: タイ (チルド @code{~} によって記述されます)、@c
-連符 (@code{\times x/y @{..@}} として記述されます)、@c
-グレイス ノート (@code{\grace@{..@}} として記述されます) です。
+連符 (@code{\tuplet x/y @{ @dots{} @}} として記述されます)、@c
+グレイス ノート (@code{\grace @{ @dots{} @}} として記述されます) です。
LilyPond 以外では、種類の異なる括弧が適切にネストされること
--- @code{[ @{ ( .. ) @} ]} のように --
+-- @code{[ @{ ( @dots{} ) @} ]} のように --
が一般的な使い方であり、@c
括弧の終わりの順序は正確に括弧の始まりの順序と逆になります。@c
このことは上記の表で @q{囲みます} という言葉で記述されている
その手動連桁の前に終わる可能性もあります -- たぶん音楽的では@c
ないかもしれませんが、可能性はあります:
-@lilypond[quote,verbatim,fragment,ragged-right,relative=2]
- { g8\( a b[ c b\) a] }
+@lilypond[quote,verbatim,ragged-right]
+\relative { g'8\( a b[ c b\) a] g4 }
@end lilypond
一般に、種類の異なる括弧、括弧のような構成物、@c
タイが 2 つの連符にまたがっていて、@c
さらにフレージング スラーが連符の外にまで伸びています (行 3 と 4)。
-@lilypond[quote,verbatim,ragged-right,relative=1]
-r16[ g \times 2/3 { r16 e'8] }
-g,16( a \times 2/3 { b16 d) e }
-g,8[( a \times 2/3 { b8 d) e~] } |
-\times 4/5 { e32\( a, b d e } a4.\)
+@lilypond[quote,verbatim,ragged-right]
+\relative {
+ r16[ g' \tuplet 3/2 { r16 e'8] }
+ g,16( a \tuplet 3/2 { b16 d) e }
+ g,8[( a \tuplet 3/2 { b8 d) e~] } |
+ \tuplet 5/4 { e32\( a, b d e } a4.\)
+}
@end lilypond
それでは、複数のボイスが実際に必要とされるのはどんな場合なのでしょうか?@c
まずは、4 つの和音を持つ以下の例を見てください:
-@lilypond[quote,verbatim,fragment,ragged-right,relative=1]
-\key g \major
-<d g>4 <d fis> <d a'> <d g>
+@lilypond[quote,verbatim,ragged-right]
+\relative {
+ \key g \major
+ <d' g>4 <d fis> <d a'> <d g>
+}
@end lilypond
-この例は単一の山括弧からなる和音記号 @code{< ... >} を使って@c
+この例は単一の山括弧からなる和音記号 @code{< @dots{} >} を使って@c
表記することができ、必要とされるボイスは 1 つだけです。@c
しかしながら、F シャープが A に移行する際に、F シャープは実際には
8 分音符であり、そのあとに 8 分音符の G が続くとしたらどうでしょうか?@c
1 つの譜に複数のボイスがある楽譜を入力する最も簡単な方法は、@c
各ボイスをシーケンスに (続けて) 入力し
-(各ボイスを @code{@{...@}} の中に入れます)、@c
-それらのボイスを @code{<<...>>} を使って同時進行するよう組み合わせます。@c
+(各ボイスを @code{@{ @dots{} @}} の中に入れます)、@c
+それらのボイスを @code{<< @dots{} >>} を使って同時進行するよう組み合わせます。@c
さらに、各断片は、それぞれが別の断片であることを示すために、@c
ダブル バックスラッシュ @code{\\} で区切られなければなりません。@c
ダブル バックスラッシュが無ければ、すべての音符は単一のボイスの中に挿入され、@c
以下では、上記の例の和音を 2 つのボイスに分け、経過音とスラーを付け加えています:
-@lilypond[quote,verbatim,ragged-right,relative=2]
-\key g \major
-% Voice "1" Voice "2"
-<< { g4 fis8( g) a4 g } \\ { d4 d d d } >>
+@lilypond[quote,verbatim,ragged-right]
+\relative {
+ \key g \major
+ % Voice = "1" Voice = "2"
+ << { g'4 fis8( g) a4 g } \\ { d4 d d d } >>
+}
@end lilypond
この例では 2 番目のボイスの符幹が下向きになっていることに気付いてください。
今度はもう 1 つ簡単な例を挙げてみます:
-@lilypond[quote,verbatim,fragment,ragged-right,relative=2]
-\key d \minor
-% Voice "1" Voice "2"
-<< { r4 g g4. a8 } \\ { d,2 d4 g } >> |
-<< { bes4 bes c bes } \\ { g4 g g8( a) g4 } >> |
-<< { a2. r4 } \\ { fis2. s4 } >> |
+@lilypond[quote,verbatim,ragged-right]
+\relative {
+ \key d \minor
+ % Voice = "1" Voice = "2"
+ << { r4 g' g4. a8 } \\ { d,2 d4 g } >> |
+ << { bes4 bes c bes } \\ { g4 g g8( a) g4 } >> |
+ << { a2. r4 } \\ { fis2. s4 } >> |
+}
@end lilypond
各小節で別々に @code{<< \\ >>} 構造を使用する必要はありません。@c
しかしながら、各小節に多くの音符がある場合、@c
以下のようにボイス毎に分離した方が良いかもしれません:
-@lilypond[quote,verbatim,ragged-right,relative=2]
-\key d \minor
-<< {
- % Voice "1"
- r4 g g4. a8 |
- bes4 bes c bes |
- a2. r4 |
-} \\ {
- % Voice "2"
- d,2 d4 g |
- g4 g g8( a) g4 |
- fis2. s4 |
-} >>
+@lilypond[quote,verbatim,ragged-right]
+<<
+ \key d \minor
+ \relative { % Voice = "1"
+ r4 g' g4. a8 |
+ bes4 bes c bes |
+ a2. r4 |
+ } \\
+ \relative { % Voice = "2"
+ d'2 d4 g |
+ g4 g g8( a) g4 |
+ fis2. s4 |
+ }
+>>
@end lilypond
これらの各コンテキストでは、スラー、符幹、タイ、強弱記号などの垂直方向の@c
向きは適切にセットされます。
-@lilypond[quote,verbatim,fragment]
-\new Staff \relative c' {
+@lilypond[quote,verbatim]
+\new Staff \relative {
+ % Main voice
+ c'16 d e f
+ % Voice = "1" Voice = "2" Voice = "3"
+ << { g4 f e } \\ { r8 e4 d c8~ } >> |
+ << { d2 e } \\ { c8 b16 a b8 g~ 2 } \\ { s4 b c2 } >> |
+}
+@end lilypond
+
+@funindex \voices
+もし別の順番で -- 例えば上から下の順番に -- ボイスを入力したい場合、
+@code{<< @dots{} >>} 構造の前に @code{\voices} を用いることで、@c
+各ボイスの番号を指定することができます。以下は例です。
+
+@lilypond[quote,verbatim]
+\new Staff \relative {
% Main voice
- c16 d e f
- % Voice "1" Voice "2" Voice "3"
- << { g4 f e } \\ { r8 e4 d c8 ~ } >> |
- << { d2 e2 } \\ { c8 b16 a b8 g ~ g2 } \\ { s4 b4 c2 } >> |
+ c'16 d e f
+ % Voice = "1" Voice = "2"
+ << { g4 f e } \\ { r8 e4 d c8~ } >> |
+ \voices 1,3,2
+ % Voice = "1" Voice = "3" Voice = "2"
+ << { d2 e } \\ { s4 b c2 } \\ { c8 b16 a b8 g~ 2 } >> |
}
@end lilypond
これらのボイスはすべてメインのボイスからは分かれています。@c
-メインのボイスの音符は@code{<< .. >>} 構造の外にあるからです。@c
-この @code{<< .. >>} 構造を @emph{同時進行構造} と呼ぶことにしましょう。@c
+メインのボイスの音符は@code{<< @dots{} >>} 構造の外にあるからです。@c
+この @code{<< @dots{} >>} 構造を @emph{同時進行構造} と呼ぶことにしましょう。@c
スラーとタイは同じボイス内にある音符だけをつなぎます。@c
そのため、スラーとタイは同時進行構造を出たり入ったりすることはありません。@c
反対に、同じ譜上にある個々の同時進行構造で、@c
またがって分かれるかもしれないということに注意してください。
@lilypond[quote,verbatim]
-\new Staff \relative c' {
+\new Staff \relative {
% Main voice
- c16 d e f
+ c'16 d e f
<< % Bar 1
{
\voiceOneStyle
{ d2 e }
\\
% Voice 2 continues
- { c8 b16 a b8 g~ g2 }
+ { c8 b16 a b8 g~ 2 }
\\
{
\voiceThreeStyle
@code{\voiceNeutralStyle} (これもここでは使用されていません) は@c
符頭のスタイルをデフォルトに戻します。@c
後ほど、ユーザがこのようなコマンドを作成するための方法を見ていきます。@c
-@ref{オブジェクトの可視性と色} と @ref{調整のために変数を使用する}
+@ref{オブジェクトの可視性と色} と @ref{レイアウトの調整のために変数を使用する}
を参照してください。
@cindex polyphony and relative note entry (多声と相対音符入力)
そのため、以下の例では
@example
-\relative c' @{ noteA << < noteB noteC > \\ noteD >> noteE @}
+\relative @{ noteA << < noteB noteC > \\ noteD >> noteE @}
@end example
@noindent
各ボイスの始めに @code{\relative} コマンドを置くと明瞭になるかもしれません:
@example
-\relative c' @{ noteA ... @}
+\relative @{ noteA @dots{} @}
<<
- \relative c'' @{ < noteB noteC > ... @}
-@bs{}@bs{}
- \relative g' @{ noteD ... @}
+ \relative @{ < noteB noteC > @dots{} @}
+\\
+ \relative @{ noteD @dots{} @}
>>
-\relative c' @{ noteE ... @}
+\relative @{ noteE @dots{} @}
@end example
最後に、もっと複雑な楽曲の中にあるボイスを分析してみましょう。@c
音楽とボイスだけに注目してください -- 込み入った内容は後ほど説明します。
@c The following should appear as music without code
+@c KEEP LY
@lilypond[quote,ragged-right]
-\new Staff \relative c'' {
+\new Staff \relative {
\key aes \major
+ \voices 1,2,4 % ボイス 3 はありません
<< % Voice one
- { c2 aes4. bes8 }
+ { c''2 aes4. bes8 }
\\ % Voice two
{
- % Ignore these for now - they are explained in Ch 4
- \once \override NoteColumn #'ignore-collision = ##t
+ % ここは今は無視してください - 4 章で説明します
+ \once \override NoteColumn.force-hshift = #0
<ees, c>2
- \once \override NoteColumn #'force-hshift = #0.5
+ \once \override NoteColumn.force-hshift = #0.5
des2
}
- \\ % No voice three
\\ % Voice four
{
- \override NoteColumn #'force-hshift = #0
+ \override NoteColumn.force-hshift = #0
aes'2 f4 fes
}
>> |
@c The following should appear as music without code
@c The three voice styles should be defined in -init
+@c KEEP LY
@lilypond[quote,ragged-right]
-\new Staff \relative c'' {
+\new Staff \relative {
\key aes \major
+ \voices 1,2,4 % ボイス 3 はありません (符幹を下向きにしたいため)
<<
- { % Voice one
+ { % Voice one
\voiceOneStyle
- c2 aes4. bes8
+ c''2 aes4. bes8
}
\\ % Voice two
{ \voiceTwoStyle
- % Ignore these for now - they are explained in Ch 4
- \once \override NoteColumn #'ignore-collision = ##t
+ % ここは今は無視してください - 4 章で説明します
+ \once \override NoteColumn.force-hshift = #0
<ees, c>2
- \once \override NoteColumn #'force-hshift = #0.5
+ \once \override NoteColumn.force-hshift = #0.5
des2
}
- \\ % No Voice three (we want stems down)
\\ % Voice four
{ \voiceThreeStyle
- \override NoteColumn #'force-hshift = #0
+ \override NoteColumn.force-hshift = #0
aes'2 f4 fes
}
>> |
@c ignore
@lilypond[quote,verbatim,fragment,ragged-right]
-\new Staff \relative c'' {
+\new Staff \relative {
\key aes \major
<<
- { c2 aes4. bes8 } \\ { <ees, c>2 des } \\ { aes'2 f4 fes }
+ { c''2 aes4. bes8 } \\ { <ees, c>2 des } \\ { aes'2 f4 fes }
>>
<c ees aes c>1
}
ボイス 3 を省略するには、@code{\\} を 2 つ記述します:
@lilypond[quote,verbatim,fragment,ragged-right]
-\new Staff \relative c'' {
+\new Staff \relative {
\key aes \major
<< % Voice one
- { c2 aes4. bes8 }
+ { c''2 aes4. bes8 }
\\ % Voice two
{ <ees, c>2 des }
\\ % Omit Voice three
@translationof Explicitly instantiating voices
@funindex \voiceOne
-@funindex voiceOne
@funindex \voiceTwo
-@funindex voiceTwo
@funindex \voiceThree
-@funindex voiceThree
@funindex \voiceFour
-@funindex voiceFour
@funindex \oneVoice
-@funindex oneVoice
@funindex \new Voice
@cindex voice contexts, creating (ボイス コンテキストを作成する)
@example
\new Staff @{
- \relative c' @{
- << @{ e4 f g a @} \\ @{ c,4 d e f @} >>
+ \relative @{
+ << @{ e'4 f g a @} \\ @{ c,4 d e f @} >>
@}
@}
@end example
@example
\new Staff <<
- \new Voice = "1" @{ \voiceOne \relative c' @{ e4 f g a @} @}
- \new Voice = "2" @{ \voiceTwo \relative c' @{ c4 d e f @} @}
+ \new Voice = "1" @{ \voiceOne \relative @{ e'4 f g a @} @}
+ \new Voice = "2" @{ \voiceTwo \relative @{ c'4 d e f @} @}
>>
@end example
@c The following example should not display the code
@lilypond[ragged-right,quote]
\new Staff <<
- \new Voice = "1" { \voiceOne \relative c' { e4 f g a } }
- \new Voice = "2" { \voiceTwo \relative c' { c4 d e f } }
+ \new Voice = "1" { \voiceOne \relative { e'4 f g a } }
+ \new Voice = "2" { \voiceTwo \relative { c'4 d e f } }
>>
@end lilypond
マークアップ、タイ、スラー、強弱記号に与える影響を見ていきましょう:
@lilypond[quote,ragged-right,verbatim]
-\relative c' {
+\relative {
% Default behavior or behavior after \oneVoice
- c4 d8~ d e4( f | g4 a) b-> c |
+ c'4 d8~ 8 e4( f | g4 a) b-> c |
}
@end lilypond
@lilypond[quote,ragged-right,verbatim]
-\relative c' {
+\relative {
\voiceOne
- c4 d8~ d e4( f | g4 a) b-> c |
+ c'4 d8~ 8 e4( f | g4 a) b-> c |
\oneVoice
- c,4 d8~ d e4( f | g4 a) b-> c |
+ c,4 d8~ 8 e4( f | g4 a) b-> c |
}
@end lilypond
@lilypond[quote,ragged-right,verbatim]
-\relative c' {
+\relative {
\voiceTwo
- c4 d8~ d e4( f | g4 a) b-> c |
+ c'4 d8~ 8 e4( f | g4 a) b-> c |
\oneVoice
- c,4 d8~ d e4( f | g4 a) b-> c |
+ c,4 d8~ 8 e4( f | g4 a) b-> c |
}
@end lilypond
今度は、前のセクションの例を使って同じ多声部音楽のパッセージを
-3 つの異なる方法で表記する例を見ていきます。@c
+4 つの異なる方法で表記する例を見ていきます。@c
それぞれ異なる状況で利点があります。
1 つはメイン ボイスに属する @code{<< >>} の内部に直接表記を記述する方法です
示しています。
@lilypond[quote,ragged-right,verbatim]
-\new Staff \relative c' {
+\new Staff \relative {
\voiceOneStyle
% This section is homophonic
- c16^( d e f
+ c'16^( d e f
% Start simultaneous section of three voices
<<
% Continue the main voice in parallel
\new Voice {
% Set stems, etc., down
\voiceTwo
- r8 e4 d c8~ | c8 b16 a b8 g~ g2 |
+ r8 e4 d c8~ | 8 b16 a b8 g~ 2 |
}
% Initiate third voice
\new Voice {
}
@end lilypond
+@cindex voices, continued (続くボイス)
+@funindex \voices
+
+@code{\voices} コマンドはメインのボイスを同時進行表記へと@c
+続けるためにも使えます。
+
+@c KEEP LY
+@lilypond[quote,ragged-right,verbatim]
+\new Staff \relative {
+ \new Voice = "main" {
+ \voiceOneStyle
+ % ここは単声です
+ c'16^( d e f
+ % 3 ボイスの同時進行表記を開始
+ \voices "main",2,3
+ <<
+ % メインのボイスの続き
+ { g4 f e | d2 e) | }
+ \\
+ % ボイス 2 の開始
+ % 符幹などの向きが下になります
+ { r8 e4 d c8~ | 8 b16 a b8 g~ 2 | }
+ \\
+ % ボイス 3 の開始
+ % 符幹などの向きが上になります
+ { s2. | s4 b c2 | }
+ >>
+ }
+}
+@end lilypond
+
@cindex nesting music expressions (音楽表記をネストさせる)
@cindex nesting simultaneous constructs (同時進行構造をネストさせる)
@cindex nesting voices (ボイスをネストさせる)
@cindex voices, nesting (ボイスをネストさせる)
@lilypond[quote,ragged-right,verbatim]
-\new Staff \relative c' {
- c16^( d e f
+\new Staff \relative {
+ c'16^( d e f
<<
{ g4 f e | d2 e) | }
\new Voice {
\voiceTwo
r8 e4 d c8~ |
<<
- { c8 b16 a b8 g~ g2 | }
+ { c8 b16 a b8 g~ 2 | }
\new Voice {
\voiceThree
s4 b c2 |
ボイスが無音の場所を飛ばすには以下のように空白音符を使用します:
@lilypond[quote,ragged-right,verbatim]
-\new Staff \relative c' <<
+\new Staff \relative <<
% Initiate first voice
\new Voice {
\voiceOne
- c16^( d e f g4 f e | d2 e) |
+ c'16^( d e f g4 f e | d2 e) |
}
% Initiate second voice
\new Voice {
% Set stems, etc, down
\voiceTwo
- s4 r8 e4 d c8~ | c8 b16 a b8 g~ g2 |
+ s4 r8 e4 d c8~ | 8 b16 a b8 g~ 2 |
}
% Initiate third voice
\new Voice {
@cindex collisions, notes (音符の衝突)
@cindex shift commands (シフト コマンド)
@funindex \shiftOff
-@funindex shiftOff
@funindex \shiftOn
-@funindex shiftOn
@funindex \shiftOnn
-@funindex shiftOnn
@funindex \shiftOnnn
-@funindex shiftOnnn
和音の中で小さな間隔で置かれる音符、@c
あるいは異なるボイスで同時に発生する音符は、@c
保持することができます。@c
同じ向きの符幹を持つ 2 つのボイスからの音符が同じ位置に置かれ、両方のボイスに@c
シフトが指定されていない、あるいは同じシフトが指定されている場合、@c
-エラー メッセージ @qq{Too many clashing note columns} (音符が多すぎて音符列で@c
-衝突が起こっています) が生成されます。
+エラー メッセージ
+@qq{This voice needs a @code{@bs{}voiceXx} or @code{@bs{}shiftXx} setting}
+(このボイスは @code{@bs{}voiceXx} か @code{@bs{}shiftXx} の設定が必要です)
+が生成されます。
@seealso
+学習マニュアル:
+@ruser{Moving objects}
+
記譜法リファレンス:
@ruser{複数のボイス}
@funindex \new Lyrics
@funindex \lyricsto
-@funindex lyricsto
@funindex Lyrics
@cindex Lyrics context, creating (歌詞コンテキストを作成する)
@cindex lyrics, linking to voice (歌詞をボイスにリンクさせる)
@lilypond[quote,verbatim]
<<
\new Voice = "one" {
- \relative c'' {
+ \relative {
\autoBeamOff
\time 2/4
- c4 b8. a16 | g4. f8 | e4 d | c2 |
+ c''4 b8. a16 | g4. f8 | e4 d | c2 |
}
}
\new Lyrics \lyricsto "one" {
@cindex lyrics and beaming (歌詞と連桁)
@cindex beaming and lyrics (連桁と歌詞)
@funindex \autoBeamOff
-@funindex autoBeamOff
LilyPond がデフォルトで使用する自動連桁は楽器だけの音楽では@c
うまく機能しますが、歌詞を持つ音楽ではそれほどうまく機能しません。@c
@funindex \new ChoirStaff
@funindex ChoirStaff
@funindex \lyricmode
-@funindex lyricmode
@cindex vocal score structure (ボーカル譜構造)
@cindex choir staff
@lilypond[quote,verbatim]
global = { \key f \major \time 6/8 \partial 8 }
-SopOneMusic = \relative c'' {
- c8 | c8([ bes)] a a([ g)] f | f'4. b, | c4.~ c4
+SopOneMusic = \relative {
+ c''8 | c8([ bes)] a a([ g)] f | f'4. b, | c4.~ 4
}
SopOneLyrics = \lyricmode {
Let | flee -- cy flocks the | hills a -- dorn, __
}
-SopTwoMusic = \relative c' {
- r8 | r4. r4 c8 | a'8([ g)] f f([ e)] d | e8([ d)] c bes'
+SopTwoMusic = \relative {
+ r8 | r4. r4 c'8 | a'8([ g)] f f([ e)] d | e8([ d)] c bes'
}
SopTwoLyrics = \lyricmode {
Let | flee -- cy flocks the | hills a -- dorn,
@lilypond[quote,verbatim]
keyTime = { \key c \major \time 4/4 \partial 4 }
-SopMusic = \relative c' { c4 | e4. e8 g4 g | a4 a g }
-AltoMusic = \relative c' { c4 | c4. c8 e4 e | f4 f e }
-TenorMusic = \relative c { e4 | g4. g8 c4. b8 | a8 b c d e4 }
-BassMusic = \relative c { c4 | c4. c8 c4 c | f8 g a b c4 }
+SopMusic = \relative { c'4 | e4. e8 g4 g | a4 a g }
+AltoMusic = \relative { c'4 | c4. c8 e4 e | f4 f e }
+TenorMusic = \relative { e4 | g4. g8 c4. b8 | a8 b c d e4 }
+BassMusic = \relative { c4 | c4. c8 c4 c | f8 g a b c4 }
VerseOne =
\lyricmode { E -- | ter -- nal fa -- ther, | strong to save, }
記譜要素を出力に追加しなければなりません。@c
例えば、以下の例で入力と出力を比較してください:
-@lilypond[quote,verbatim,relative=2]
-cis4 cis2. | a4 a2. |
+@lilypond[quote,verbatim]
+\relative { cis''4 cis2. | a4 a2. | }
@end lilypond
この入力は内容がやや乏しいですが、出力では小節線、臨時記号、音部記号、@c
@translationof Creating contexts
@funindex \new
-@funindex new
@cindex new contexts (新しいコンテキスト)
@cindex creating contexts (コンテキストを作成する)
@cindex contexts, creating (コンテキストを作成する)
-入力ファイルの中で、@code{\score} コマンドによって導入される
-score ã\83\96ã\83ã\83\83ã\82¯ã\81¯å\8d\98ä¸\80ã\81®é\9f³æ¥½è¡¨è¨\98ã\81¨それに関連する出力定義
-(@code{\layout} ã\83\96ã\83ã\83\83ã\82¯ã\81\82ã\82\8bã\81\84ã\81¯ @code{\midi} ã\83\96ã\83ã\83\83ã\82¯)
-ã\82\92ä¿\9dæ\8c\81ã\81\97ます。@c
+入力ファイルの中で、(@code{\score} コマンドによって導入される)
+score ã\83\96ã\83ã\83\83ã\82¯ã\81¯å\8d\98ä¸\80ã\81®é\9f³æ¥½è¡¨è¨\98ã\82\92ä¿\9dæ\8c\81ã\81\97ã\81¾ã\81\99ã\81\8cã\80\81それに関連する出力定義
+(@code{\layout} ã\83\96ã\83ã\83\83ã\82¯ã\81¨ @code{\midi} ã\83\96ã\83ã\83\83ã\82¯ã\81®ã\81\84ã\81\9aã\82\8cã\81\8bã\81\82ã\82\8bã\81\84ã\81¯ä¸¡æ\96¹)
+ã\82\82ä¿\9dæ\8c\81ã\81\99ã\82\8bã\81\93ã\81¨ã\81\8cã\81§ã\81\8dます。@c
通常、@code{Score} コンテキストは省略され、@c
音楽表記の解釈が始まった時点で自動的に作成されます。
\clef "treble"
\key g \minor
\new Voice { % 右手の音符用のボイスを作成します
- \relative c'' { % 右手の音符の開始点
- d4 ees16 c8. |
+ \relative { % 右手の音符の開始点
+ d''4 ees16 c8. |
d4 ees16 c8. |
} % 右手の音符の終了点
} % 右手のボイスの終了点
\key g \minor
\new Voice { % 左手のボイス 1 を作成します
\voiceOne
- \relative g { % 左手のボイス 1 の音符の開始点
+ \relative { % 左手のボイス 1 の音符の開始点
g8 <bes d> ees, <g c> |
g8 <bes d> ees, <g c> |
} % 左手のボイス 1 の音符の終了点
} % 左手のボイス 1 の終了点
\new Voice { % 左手のボイス 2 を作成します
\voiceTwo
- \relative g { % 左手のボイス 2 の音符の開始点
+ \relative { % 左手のボイス 2 の音符の開始点
g4 ees |
g4 ees |
} % 左手のボイス 2 の音符の終了点
@seealso
-記譜法リファレンス: @ruser{Creating contexts}
+記譜法リファレンス: @ruser{Creating and referencing contexts}
@node エングラーバの説明
@tab 音部記号を譜刻します。
@item Completion_heads_engraver
@tab 小節線をまたがる音符を分割します。
-@c The old Dynamic_engraver is deprecated. -jm
-@item New_dynamic_engraver
+@item Dynamic_engraver
@tab 強弱記号 (クレッシェンド、デクレッシェンド) と強弱テキスト (p や f など)
を作成します。
@item Forbid_line_break_engraver
@cindex context properties, modifying (コンテキスト プロパティを変更する)
@cindex modifying context properties (コンテキスト プロパティを変更する)
@funindex \set
-@funindex set
@funindex \unset
-@funindex unset
コンテキストにはいくつかのコンテキスト プロパティを保持する責任があります。@c
それらプロパティの多くは変更可能であり、変更することで入力の構文解釈に影響を@c
これは明らかな場合もありますが、ややこしい場合もあります。@c
間違ったコンテキストが指定された場合、エラー メッセージは表示されませんが、@c
予期したアクションが起こりません。@c
-例えば、@code{instrumentName} は間違いなく @code{Staff} コンテキストの中に@c
+例えば、@code{clefGlyph} は間違いなく @code{Staff} コンテキストの中に@c
きます。@c
-なぜなら、このプロパティが名前を付けるのは譜表だからです。@c
-以ä¸\8bã\81®ä¾\8bã\81§ã\81¯ã\80\81æ\9c\80å\88\9dã\81®è\9c表ã\81«ã\81¯å\90\8då\89\8dã\81\8cä»\98ã\81\91ã\82\89ã\82\8cã\81¦ã\81\84ã\81¾ã\81\99ã\81\8cã\80\812 ç\95ªç\9b®ã\81®è\9c表ã\81«は@c
-付けられていません。@c
-なぜなら、コンテキスト名を省略しているからです。
+なぜなら、変更されるものは譜表に属する音部記号だからです。@c
+以ä¸\8bã\81®ä¾\8bã\81§ã\81¯ã\80\81æ\9c\80å\88\9dã\81®è\9c表ã\81®é\9f³é\83¨è¨\98å\8f·ã\81¯æ£ã\81\97ã\81\8f表示ã\81\95ã\82\8cã\81¦ã\81\84ã\81¾ã\81\99ã\81\8cã\80\812 ç\95ªç\9b®ã\81®è\9c表は@c
+正しくありません -- ヘ音記号を指定したはずですが、デフォルトであるト音記号が@c
+表示されています -- なぜなら、コンテキスト名を省略しているからです。
@lilypond[quote,verbatim,ragged-right]
<<
- \new Staff \relative c'' {
- \set Staff.instrumentName = #"Soprano"
- c2 c
+ \new Staff \relative {
+ \set Staff.clefGlyph = "clefs.C"
+ c''2 c
}
- \new Staff \relative c' {
- \set instrumentName = #"Alto" % Wrong!
- d2 d
+ \new Staff \relative {
+ \set clefGlyph = "clefs.F" % Wrong!
+ d'2 d
}
>>
@end lilypond
デフォルトのコンテキスト名は @code{Voice} であることを思い出してください。@c
このため、2 番目の @code{@bs{}set} コマンドは @code{Voice} コンテキストの@c
-プロパティ @code{instrumentName} を @qq{Alto} にセットしています。@c
+プロパティ @code{clefGlyph} を @qq{clefs.F} にセットしています。@c
しかしながら、LilyPond は @code{Voice} コンテキストでそのようなプロパティを@c
見つけ出さないため、何のアクションも起こしません。@c
これはエラーではなく、ログ ファイルにエラー メッセージは残りません。
@rinternals{Tunable context properties} や @rinternals{Contexts}
を参照してください。
-@code{instrumentName} プロパティは @code{Staff} コンテキストの中に@c
+@code{clefGlyph} プロパティは @code{Staff} コンテキストの中に@c
セットされた場合にのみ効果を持ちますが、いくつかのプロパティは複数の@c
コンテキストの中にセットすることができます。@c
例えば、プロパティ @code{extraNatural} はすべての譜に対してデフォルトで
@lilypond[quote,verbatim,ragged-right]
<<
- \new Staff \relative c'' {
- aeses2 aes
+ \new Staff \relative {
+ aeses'2 aes
}
- \new Staff \relative c'' {
+ \new Staff \relative {
\set Staff.extraNatural = ##f
- aeses2 aes
+ aeses'2 aes
}
>>
@end lilypond
@lilypond[quote,verbatim,ragged-right]
<<
- \new Staff \relative c'' {
- aeses2 aes
+ \new Staff \relative {
+ aeses'2 aes
}
- \new Staff \relative c'' {
+ \new Staff \relative {
\set Score.extraNatural = ##f
- aeses2 aes
+ aeses'2 aes
}
>>
@end lilypond
-他の例としては、@code{clefOctavation} が @code{Score} コンテキストに@c
-セットされた場合、直ちにすべての譜でのオクターブの値を変更し、すべての譜に@c
+他の例としては、@code{clefTransposition} が @code{Score} コンテキストに@c
+セットされた場合、直ちにすべての譜でのオクターブ表示を変更し、すべての譜に@c
適用される新しいデフォルト値をセットします。
逆のことを行うコマンド @code{\unset} はコンテキストからプロパティを@c
変更は直前にセットされた値から行われるのではなく、デフォルト値から行われます。
@c KEEP LY
-@lilypond[quote,verbatim,ragged-right,relative=1]
-c4 d
-% 符頭を小さくします
-\set fontSize = #-4
-e4 f |
-% 符頭を大きくします
-\set fontSize = #2.5
-g4 a
-% デフォルトのサイズに戻します
-\unset fontSize
-b4 c |
+@lilypond[quote,verbatim,ragged-right]
+\relative {
+ c'4 d
+ % 符頭を小さくします
+ \set fontSize = #-4
+ e4 f |
+ % 符頭を大きくします
+ \set fontSize = #2.5
+ g4 a
+ % デフォルトのサイズに戻します
+ \unset fontSize
+ b4 c |
+}
@end lilypond
これまでにいくつかのタイプのプロパティ値をセットする方法を見てきました。@c
@c Setting context properties with @code{\with}
@funindex \with
-@funindex with
@cindex context properties, setting with \with (\with でコンテキスト プロパティを設定する)
コンテキスト プロパティはコンテキストが作成されるときに@c
@lilypond[quote,verbatim,ragged-right]
<<
\new Staff {
- \relative c'' {
- gisis4 gis aeses aes
+ \relative {
+ gisis'4 gis aeses aes
}
}
\new Staff \with { extraNatural = ##f } {
- \relative c'' {
- gisis4 gis aeses aes
+ \relative {
+ gisis'4 gis aeses aes
}
}
>>
@cindex context properties, setting with \context (\context でコンテキスト プロパティを設定する)
@funindex \context
-@funindex context
コンテキスト プロパティの値は単一のコマンドによってある特定のタイプの@c
コンテキスト@emph{すべて} -- すべての @code{Staff} コンテキストなどのように
@lilypond[verbatim,quote]
\score {
\new Staff {
- \relative c'' {
- cisis4 e d cis
+ \relative {
+ cisis''4 e d cis
}
}
\layout {
\score {
<<
\new Staff {
- \relative c'' {
- gisis4 gis aeses aes
+ \relative {
+ gisis'4 gis aeses aes
}
}
\new Staff {
- \relative c'' {
- gisis4 gis aeses aes
+ \relative {
+ gisis'4 gis aeses aes
}
}
>>
@cindex removing engravers (エングラーバを削除する)
@funindex \consists
-@funindex consists
@funindex \remove
-@funindex remove
これまでに、コンテキストはそれぞれにいくつかのエングラーバを保持し、@c
それぞれのエングラーバは出力のある特定部分
\new Staff \with {
\remove "Staff_symbol_engraver"
}
-\relative c' {
- c4 d
+\relative {
+ c'4 d
\set fontSize = #-4 % 符頭を小さくします
e4 f |
\set fontSize = #2.5 % 符頭を大きくします
\new Voice \with {
\consists "Ambitus_engraver"
} {
- \relative c'' {
+ \relative {
\voiceOne
- c4 a b g
+ c''4 a b g
}
}
\new Voice {
- \relative c' {
+ \relative {
\voiceTwo
- c4 e d f
+ c'4 e d f
}
}
>>
}
<<
\new Voice {
- \relative c'' {
+ \relative {
\voiceOne
- c4 a b g
+ c''4 a b g
}
}
\new Voice {
- \relative c' {
+ \relative {
\voiceTwo
- c4 e d f
+ c'4 e d f
}
}
>>
@c Changing all contexts of the same type
@funindex \layout
-@funindex layout
上の例では、個々のコンテキストにエングラーバを追加あるいは削除する方法を@c
示しました。@c
\score {
<<
\new Staff {
- \relative c'' {
- c4 a b g
+ \relative {
+ c''4 a b g
}
}
\new Staff {
- \relative c' {
- c4 a b g
+ \relative {
+ c'4 a b g
}
}
\new Staff {
\clef "G_8"
- \relative c' {
- c4 a b g
+ \relative {
+ c'4 a b g
}
}
\new Staff {
\clef "bass"
- \relative c {
+ \relative {
c4 a b g
}
}
@example
\version @w{"@version{}"}
-melody = \relative c' @{
+melody = \relative @{
\clef "treble"
\key c \major
\time 4/4
@example
\version @w{"@version{}"}
-melody = \relative c' @{
+melody = \relative @{
\clef "treble"
\key c \major
\time 4/4
チェロ用のセクションを @code{celloMusic} と呼ぶことにします。@c
リネームするときに、@code{text} を @code{sopranoLyrics} とりネームしましょう。@c
これらのインスタンスをリネームすることも忘れないでください
-−- 初期定義 (@code{melody = \relative c' @{ } 部分) とその名前が@c
+−- 初期定義 (@code{melody = \relative @{ } 部分) とその名前が@c
使われているところ (@code{\score セクションの中}) の両方です。
リネームする際に、チェロ パートの譜も変更しましょう
@example
\version @w{"@version{}"}
-sopranoMusic = \relative c' @{
+sopranoMusic = \relative @{
\clef "treble"
\key c \major
\time 4/4
Aaa Bee Cee Dee
@}
-celloMusic = \relative c @{
+celloMusic = \relative @{
\clef "bass"
\key c \major
\time 4/4
ここで、完成したソプラノとチェロ用のテンプレートを挙げます。
@lilypond[quote,verbatim,ragged-right,addversion]
-sopranoMusic = \relative c' {
+sopranoMusic = \relative {
\clef "treble"
\key c \major
\time 4/4
Aaa Bee Cee Dee
}
-celloMusic = \relative c {
+celloMusic = \relative {
\clef "bass"
\key c \major
\time 4/4
@seealso
開始点となるテンプレートは付録 @q{テンプレート} で見つけることができます。@c
-@ref{単一の譜表} を参照してください。
+@ref{Single staff templates} を参照してください。
@node 4 パート SATB ボーカル譜
@lilypond[quote,ragged-right]
global = { \key d \major \time 4/4 }
-sopranoMusic = \relative c'' {
+sopranoMusic = \relative {
\clef "treble"
- r4 d2 a4 | d4. d8 a2 | cis4 d cis2 |
+ r4 d''2 a4 | d4. d8 a2 | cis4 d cis2 |
}
sopranoWords = \lyricmode {
Wor -- thy | is the lamb | that was slain |
}
-altoMusic = \relative a' {
+altoMusic = \relative {
\clef "treble"
- r4 a2 a4 | fis4. fis8 a2 | g4 fis e2 |
+ r4 a'2 a4 | fis4. fis8 a2 | g4 fis e2 |
}
altoWords = \sopranoWords
-tenorMusic = \relative c' {
+tenorMusic = \relative {
\clef "G_8"
- r4 fis2 e4 | d4. d8 d2 | e4 a, cis2 |
+ r4 fis'2 e4 | d4. d8 d2 | e4 a, cis2 |
}
tenorWords = \sopranoWords
-bassMusic = \relative c' {
+bassMusic = \relative {
\clef "bass"
- r4 d2 cis4 | b4. b8 fis2 | e4 d a'2 |
+ r4 d'2 cis4 | b4. b8 fis2 | e4 d a'2 |
}
bassWords = \sopranoWords
-upper = \relative a' {
+upper = \relative {
\clef "treble"
\global
- r4 <a d fis>2 <a e' a>4 |
+ r4 <a' d fis>2 <a e' a>4 |
<d fis d'>4. <d fis d'>8 <a d a'>2 |
<g cis g'>4 <a d fis> <a cis e>2 |
}
-lower = \relative c, {
+lower = \relative {
\clef "bass"
\global
- <d d'>4 <d d'>2 <cis cis'>4 |
+ <d, d'>4 <d d'>2 <cis cis'>4 |
<b b'>4. <b' b'>8 <fis fis'>2 |
<e e'>4 <d d'> <a' a'>2 |
}
\score {
<< % combine ChoirStaff and PianoStaff in parallel
\new ChoirStaff <<
- \new Staff = "sopranos" <<
- \set Staff.instrumentName = #"Soprano"
+ \new Staff = "sopranos"
+ \with { instrumentName = #"Soprano" }
+ <<
\new Voice = "sopranos" {
\global
\sopranoMusic
\new Lyrics \lyricsto "sopranos" {
\sopranoWords
}
- \new Staff = "altos" <<
- \set Staff.instrumentName = #"Alto"
+ \new Staff = "altos"
+ \with { instrumentName = #"Alto" }
+ <<
\new Voice = "altos" {
\global
\altoMusic
}
>>
- \new Lyrics \lyricsto "altos" { \altoWords }
- \new Staff = "tenors" <<
- \set Staff.instrumentName = #"Tenor"
+ \new Lyrics \lyricsto "altos" {
+ \altoWords
+ }
+ \new Staff = "tenors"
+ \with { instrumentName = #"Tenor" }
+ <<
\new Voice = "tenors" {
\global
\tenorMusic
}
>>
- \new Lyrics \lyricsto "tenors" { \tenorWords }
- \new Staff = "basses" <<
- \set Staff.instrumentName = #"Bass"
+ \new Lyrics \lyricsto "tenors" {
+ \tenorWords
+ }
+ \new Staff = "basses"
+ \with { instrumentName = #"Bass" }
+ <<
\new Voice = "basses" {
\global
\bassMusic
\bassWords
}
>> % end ChoirStaff
- \new PianoStaff <<
- \set PianoStaff.instrumentName = #"Piano"
+ \new PianoStaff \with { instrumentName = #"Piano" }
+ <<
\new Staff = "upper" \upper
\new Staff = "lower" \lower
>>
}
@end lilypond
-このレイアウトをそのまま提供するテンプレートはありません。@c
-最も近いのは @q{SATB ボーカル譜と自動ピアノ伴奏譜} -- @ref{合唱} を@c
-参照してください -- ですが、レイアウトを変更して、ボーカル パートから@c
-自動的に生成されたものではないピアノ伴奏譜を付け加える必要があります。@c
+@warning{このレイアウトは LilyPond に組み込まれているテンプレートを@c
+用いることで簡単に実現できます: @code{satb.ly} 。@c
+@ref{Built-in templates} を参照してください。@c
+簡単に利用できるという利点はありますが、@c
+このテンプレートを用いるということは、必要なコンテキスト構造を@c
+自動で提供する代わりに、それを隠してしまうということです。@c
+ですから学習のために、これを一から作る方法を見てみましょう。@c
+組み込みのテンプレートが完全には望みどおりでない場合、@c
+この手順を行う必要があるかもしれません。}
+
+コピーして編集できるテンプレートの中で、最も近いものは
+@ref{SATB vocal score and automatic piano reduction}
+ですが、レイアウトを変更して、ボーカル パートから自動的に生成されたものでは@c
+ないピアノ伴奏譜を付け加える必要があります。@c
ボーカル パートのための音楽と歌詞を保持している変数はそのまま使えますが、@c
ピアノ伴奏譜のための変数を付け加える必要があります。
@example
\new ChoirStaff <<
- \new Staff = "sopranos" <<
- \set Staff.instrumentName = #"Soprano"
+ \new Staff = "sopranos"
+ \with @{ instrumentName = #"Soprano" @}
+ <<
\new Voice = "sopranos" @{
\global
\sopranoMusic
\new Lyrics \lyricsto "sopranos" @{
\sopranoWords
@}
- \new Staff = "altos" <<
- \set Staff.instrumentName = #"Alto"
+ \new Staff = "altos"
+ \with @{ instrumentName = #"Alto" @}
+ <<
\new Voice = "altos" @{
\global
\altoMusic
\new Lyrics \lyricsto "altos" @{
\altoWords
@}
- \new Staff = "tenors" <<
- \set Staff.instrumentName = #"Tenor"
+ \new Staff = "tenors"
+ \with @{ instrumentName = #"Tenor" @}
+ <<
\new Voice = "tenors" @{
\global
\tenorMusic
\new Lyrics \lyricsto "tenors" @{
\tenorWords
@}
- \new Staff = "basses" <<
- \set Staff.instrumentName = #"Bass"
+ \new Staff = "basses"
+ \with @{ instrumentName = #"Bass" @}
+ <<
\new Voice = "basses" @{
\global
\bassMusic
引き抜いてくるだけです:
@example
-\new PianoStaff <<
- \set PianoStaff.instrumentName = #"Piano "
+\new PianoStaff \with @{ instrumentName = #"Piano " @}
+<<
\new Staff = "upper" \upper
\new Staff = "lower" \lower
>>
@}
>> % end ChoirStaff
- \new PianoStaff <<
- \set PianoStaff.instrumentName = #"Piano"
+ \new PianoStaff \with @{ instrumentName = #"Piano " @}
+ <<
\new Staff = "upper" \upper
\new Staff = "lower" \lower
>>
@c KEEP LY
@lilypond[quote,verbatim,ragged-right,addversion]
global = { \key d \major \time 4/4 }
-sopranoMusic = \relative c'' {
+sopranoMusic = \relative {
\clef "treble"
- r4 d2 a4 | d4. d8 a2 | cis4 d cis2 |
+ r4 d''2 a4 | d4. d8 a2 | cis4 d cis2 |
}
sopranoWords = \lyricmode {
Wor -- thy | is the lamb | that was slain |
}
-altoMusic = \relative a' {
+altoMusic = \relative {
\clef "treble"
- r4 a2 a4 | fis4. fis8 a2 | g4 fis fis2 |
+ r4 a'2 a4 | fis4. fis8 a2 | g4 fis fis2 |
}
altoWords = \sopranoWords
-tenorMusic = \relative c' {
+tenorMusic = \relative {
\clef "G_8"
- r4 fis2 e4 | d4. d8 d2 | e4 a, cis2 |
+ r4 fis'2 e4 | d4. d8 d2 | e4 a, cis2 |
}
tenorWords = \sopranoWords
-bassMusic = \relative c' {
+bassMusic = \relative {
\clef "bass"
- r4 d2 cis4 | b4. b8 fis2 | e4 d a'2 |
+ r4 d'2 cis4 | b4. b8 fis2 | e4 d a'2 |
}
bassWords = \sopranoWords
-upper = \relative a' {
+upper = \relative {
\clef "treble"
\global
- r4 <a d fis>2 <a e' a>4 |
+ r4 <a' d fis>2 <a e' a>4 |
<d fis d'>4. <d fis d'>8 <a d a'>2 |
<g cis g'>4 <a d fis> <a cis e>2 |
}
-lower = \relative c, {
+lower = \relative {
\clef "bass"
\global
- <d d'>4 <d d'>2 <cis cis'>4 |
+ <d, d'>4 <d d'>2 <cis cis'>4 |
<b b'>4. <b' b'>8 <fis fis'>2 |
<e e'>4 <d d'> <a' a'>2 |
}
\score {
<< % ChoirStaff と PianoStaff を並行に組み合わせます
\new ChoirStaff <<
- \new Staff = "sopranos" <<
- \set Staff.instrumentName = #"Soprano"
+ \new Staff = "sopranos"
+ \with { instrumentName = #"Soprano" }
+ <<
\new Voice = "sopranos" {
\global
\sopranoMusic
\new Lyrics \lyricsto "sopranos" {
\sopranoWords
}
- \new Staff = "altos" <<
- \set Staff.instrumentName = #"Alto"
+ \new Staff = "altos"
+ \with { instrumentName = #"Alto" }
+ <<
\new Voice = "altos" {
\global
\altoMusic
\new Lyrics \lyricsto "altos" {
\altoWords
}
- \new Staff = "tenors" <<
- \set Staff.instrumentName = #"Tenor"
+ \new Staff = "tenors"
+ \with { instrumentName = #"Tenor" }
+ <<
\new Voice = "tenors" {
\global
\tenorMusic
\new Lyrics \lyricsto "tenors" {
\tenorWords
}
- \new Staff = "basses" <<
- \set Staff.instrumentName = #"Bass"
+ \new Staff = "basses"
+ \with { instrumentName = #"Bass" }
+ <<
\new Voice = "basses" {
\global
\bassMusic
}
>> % ChoirStaff の終了
- \new PianoStaff <<
- \set PianoStaff.instrumentName = #"Piano "
+ \new PianoStaff
+ \with { instrumentName = #"Piano " }
+ <<
\new Staff = "upper" \upper
\new Staff = "lower" \lower
>>
@end example
2 番目の鍵盤パートとペダル オルガンの譜表は 1 つだけしか音楽表記を@c
-保持しないため、それらに対して同時進行構造 @code{<< .. >>} を使う必要は@c
+保持しないため、それらに対して同時進行構造 @code{<< @dots{} >>} を使う必要は@c
必ずしもありません。@c
しかしながら、そうしても害はありませんし、@code{\new Staff} の後に常に@c
山括弧を置くというのは複数のボイスがある場合では推奨される良い習慣です。@c
Voice はこれとは対照的に、あなたの音楽を連続して演奏すべきいくつかの変数に@c
-分けてコード化する場合に Voice の後に波括弧 @code{@{ .. @}} を常に置くべきです。
+分けてコード化する場合に Voice の後に波括弧 @code{@{ @dots{} @}} を常に置くべきです。
この構造をスコア ブロックに付け加えて、インデントを調整しましょう。@c
さらに、適切な音部記号を付け加え、@code{\voiceOne} と @code{\voiceTwo} を@c
@}
>> % ManualOne Staff コンテキストの終了
\new Staff = "ManualTwo" \with @{
- \override VerticalAxisGroup
- #'staff-staff-spacing #'stretchability = 5
+ \override VerticalAxisGroup.staff-staff-spacing.stretchability = 5
@} <<
\keyTime
\clef "bass"
composer = "J S Bach"
}
keyTime = { \key c \minor \time 4/4 }
-ManualOneVoiceOneMusic = \relative g' {
- g4 g f ees |
+ManualOneVoiceOneMusic = \relative {
+ g'4 g f ees |
d2 c |
}
-ManualOneVoiceTwoMusic = \relative c' {
- ees16 d ees8~ ees16 f ees d c8 d~ d c~ |
- c8 c4 b8 c8. g16 c b c d |
+ManualOneVoiceTwoMusic = \relative {
+ ees'16 d ees8~ 16 f ees d c8 d~ d c~ |
+ 8 c4 b8 c8. g16 c b c d |
}
-ManualTwoMusic = \relative c' {
- c16 b c8~ c16 b c g a8 g~ g16 g aes ees |
- f16 ees f d g aes g f ees d e8~ ees16 f ees d |
+ManualTwoMusic = \relative {
+ c'16 b c8~ 16 b c g a8 g~ 16 g aes ees |
+ f16 ees f d g aes g f ees d ees8~ 16 f ees d |
}
-PedalOrganMusic = \relative c {
- r8 c16 d ees d ees8~ ees16 a, b g c b c8 |
+PedalOrganMusic = \relative {
+ r8 c16 d ees d ees8~ 16 a, b g c b c8 |
r16 g ees f g f g8 c,2 |
}
}
>> % ManualOne Staff コンテキストの終了
\new Staff = "ManualTwo" \with {
- \override VerticalAxisGroup
- #'staff-staff-spacing #'stretchability = 5
+ \override VerticalAxisGroup.staff-staff-spacing.stretchability = 5
} <<
\keyTime
\clef "bass"
これまでに、以下のような記述を見てきました:
@lilypond[quote,verbatim,ragged-right]
-hornNotes = \relative c'' { c4 b dis c }
+hornNotes = \relative { c''4 b dis c }
\score {
{
気付くかもしれません:
@lilypond[quote,verbatim,ragged-right]
-fragmentA = \relative c'' { a4 a8. b16 }
-fragmentB = \relative c'' { a8. gis16 ees4 }
+fragmentA = \relative { a'4 a8. b16 }
+fragmentB = \relative { a'8. gis16 ees4 }
violin = \new Staff {
\fragmentA \fragmentA |
さらに、これらの変数 (変数、マクロ、(ユーザ定義) コマンドなどと呼ばれます)
を調整のために使うこともできます:
-@c TODO Avoid padtext - not needed with skylining
@lilypond[quote,verbatim,ragged-right]
dolce = \markup { \italic \bold dolce }
-padText = { \once \override TextScript #'padding = #5.0 }
+centreText = { \once \override TextScript.self-alignment-X = #CENTER }
+
fthenp =_\markup {
\dynamic f \italic \small { 2nd } \hspace #0.1 \dynamic p
}
-violin = \relative c'' {
+violin = \relative {
\repeat volta 2 {
- c4._\dolce b8 a8 g a b |
- \padText
- c4.^"hi there!" d8 e' f g d |
- c,4.\fthenp b8 c4 c-. |
+ c''4._\dolce b8 a8 g a b |
+ \centreText
+ c4.^"hi there!" d8 e f g d |
+ c4.\fthenp b8 c4 c-. |
}
}
{
\violin
}
- \layout { ragged-right = ##t }
}
@end lilypond
とても読み難く、特に最後の行が読み難いです。
@example
-violin = \relative c'' @{
+violin = \relative @{
\repeat volta 2 @{
- c4._\markup @{ \italic \bold dolce @} b8 a8 g a b |
- \once \override TextScript #'padding = #5.0
- c4.^"hi there!" d8 e' f g d |
- c,4.\markup @{
+ c''4._\markup @{ \italic \bold dolce @} b8 a8 g a b |
+ \once \override TextScript.self-alignment-X = #CENTER
+ c4.^"hi there!" d8 e f g d |
+ c4._\markup @{
\dynamic f \italic \small @{ 2nd @} \hspace #0.1 \dynamic p
@}
b8 c4 c-. |
@}
@end example
-@c TODO Replace the following with a better example -td
-@c Skylining handles this correctly without padText
-
これまでに見てきたのは静的な置き換えです
--- LilyPond は @code{\padText} を見つけると、それを定義した内容
-(つまり、@code{padText=} の右側にあるもの) に置き換えます。
+-- LilyPond は @code{\centreText} を見つけると、それを定義した内容
+(つまり、@code{centreText=} の右側にあるもの) に置き換えます。
LilyPond は非静的な置き換えも処理できます (それらを関数と見なすことができます)。
@lilypond[quote,verbatim,ragged-right]
padText =
#(define-music-function
- (parser location padding)
+ (padding)
(number?)
#{
- \once \override TextScript #'padding = #padding
+ \once \override TextScript.padding = #padding
#})
-\relative c''' {
- c4^"piu mosso" b a b |
+\relative {
+ c''4^"piu mosso" b a b
\padText #1.8
- c4^"piu mosso" d e f |
+ c4^"piu mosso" b a b
\padText #2.6
- c4^"piu mosso" fis a g |
+ c4^"piu mosso" b a b
}
@end lilypond
以下のホルン/@/バスーン デュオのパートを保持しているとします:
@example
-hornNotes = \relative c @{
+hornNotes = \relative @{
\time 2/4
r4 f8 a | cis4 f | e4 d |
@}
この移調により出力は以下のようになります:
@lilypond[quote,ragged-right]
-\transpose f c' \relative c {
+\transpose f c' \relative {
\time 2/4
r4 f8 a | cis4 f | e4 d |
}
@end example
この部分を譜刻するとき、複小節休符を圧縮する必要があります。@c
-ã\81\93ã\82\8cã\81¯ä»¥ä¸\8bã\81®ã\83©ã\83³-ã\82¿ã\82¤ã\83 å¤\89æ\95°ã\82\92è¨å®\9aã\81\99ã\82\8bã\81\93ã\81¨ã\81«ã\82\88ã\81£ã\81¦è¡\8cã\81\84ã\81¾ã\81\99:
+ã\81\93ã\82\8cã\82\92è¡\8cã\81\86é\9f³æ¥½é\96¢æ\95°ã\81\8cå\98å\9c¨ã\81\97ã\81¾ã\81\99ã\80\82
@example
-\set Score.skipBars = ##t
+\compressMMRests @{ ... @}
@end example
-@noindent
-このコマンドは @code{Score} コンテキストの中にある@c
-プロパティ @code{skipBars} を真 (@code{##t}) にセットします。@c
-この休符とオプションを上記の音楽の先頭に追加することによって、@c
-以下のような結果になります:
+これを @code{hornNotes} に適用すると、以下のような結果になります:
@lilypond[quote,ragged-right]
-\transpose f c' \relative c {
+\compressMMRests \transpose f c' \relative {
\time 2/4
- \set Score.skipBars = ##t
R2*3 |
r4 f8 a | cis4 f | e4 d |
}
そして、以下のような楽譜になります:
@lilypond[quote,ragged-right]
-\relative c <<
+\relative <<
\new Staff {
\clef "treble"
\time 2/4
>>
@end lilypond
+@seealso
+学習マニュアル:
+@ref{Organizing pieces with variables}.
+
+記譜法リファレンス:
+@ruser{Transpose},
+@ruser{Writing parts},
+@ruser{Full measure rests},
+@ruser{Including LilyPond files}.