Next: Transpose, Up: Changing multiple pitches
In relative mode, it is easy to forget an octave changing mark. Octave checks make such errors easier to find by displaying a warning and correcting the octave if a note is found in an unexpected octave.
To check the octave of a note, specify the absolute octave after
the =
symbol. This example will generate a warning
(and change the pitch) because the second note is the absolute
octave d''
instead of d'
as indicated by the octave
correction.
\relative c'' { c2 d='4 d e2 f }
The octave of notes may also be checked with the
\octaveCheck
controlpitch command.
controlpitch is specified in absolute mode. This checks
that the interval between the previous note and the
controlpitch is within a fourth (i.e., the normal
calculation of relative mode). If this check fails, a warning is
printed, but the previous note is not changed. Future notes are
relative to the controlpitch.
\relative c'' { c2 d \octaveCheck c' e2 f }
Compare the two bars below. The first and third \octaveCheck
checks fail, but the second one does not fail.
\relative c'' { c4 f g f c4 \octaveCheck c' f \octaveCheck c' g \octaveCheck c' f }
Snippets: Pitches.
Internals Reference: RelativeOctaveCheck.
This page is for LilyPond-2.11.58 (development-branch).
Report errors to http://post.gmane.org/post.php?group=gmane.comp.gnu.lilypond.bugs.
Your suggestions for the documentation are welcome.