lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: constructing a jazz piece


From: Shamus
Subject: Re: constructing a jazz piece
Date: Wed, 09 Apr 2008 12:23:55 -0500
User-agent: Thunderbird 2.0.0.9 (X11/20080224)

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Stan Mulder wrote:
| In constructing a small combo piece, I'm not sure how to modularize
individual
| parts.
|
| For example, notes are specific to a certain instrument whereas a segno
| or coda is common to all parts.

I've been wondering this myself after having typeset around 50 or so
lead sheets with melody, chords and rhythm parts. I've looked at the
documentation, but there doesn't seem to be any easy way to separate the
structure of the music (i.e., voltas, codas, special barlines, etc) from
the music itself (i.e., notes, fingerings, etc.). I vaguely remember
that there was some discussion about doing it in a new version of
lilypond on the list, but I can't remember if it was going to happen in
the current development branch (2.11.x) or not.

Is something like this already in the works? Or is there a good way to
do it now that I've overlooked? :-) As it is now, I have to specify the
structure in all parts (except chords) if I want to be able to print out
separate parts. Needless to say (but here I am saying it anyway :-P) it
makes part entry more cumbersome and error prone when you have to do it
this way.

- -- Shamus

Attached is an example of how I do my lead sheets currently--maybe it'll
spark some ideas for you Stan.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.7 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFH/PurmE5b/O3JjkYRAhQzAJ9V/K2pZU3hTRZAiJSG5N21LJFEDACgpohH
g4mEPT+ZrzVtpKBSOBDq3FE=
=tvj1
-----END PGP SIGNATURE-----
\version "2.10.29"
\include "pop-chords.ly"
\include "english.ly"

% Good sizes are 16, 18, & 20
staffSize = #20
#(set-default-paper-size "letter")
#(set-global-staff-size staffSize)
#(ly:set-option (quote no-point-and-click))

%{ Some useful characters: ‘ ’ “ ” – — † ‡ • … %}

\header
{
%Let's bump up the title size and switch to the chord font. :-)

        title    = \markup { \override #'(font-family . sans) \fontsize #3.5 
"As The Deer" }
%       composer = \markup { \override #'(font-family . sans) \fontsize #1.3 "" 
}
        arranger = \markup { \override #'(font-family . sans) \fontsize #1.3 
"arr. Ed Smart" }
        tagline  = #(ly:export (string-append "Engraved by JLH and Lilypond " 
(lilypond-version)))
}


%{
tweak = #(define-music-function (parser location sym val arg)
           (symbol? scheme? ly:music?)

           "Add @code{sym . val} to the @code{tweaks} property of @var{arg}."

           (set!
            (ly:music-property arg 'tweaks)
            (acons sym val
                   (ly:music-property arg 'tweaks)))
           arg)
%}

% Useful tweak abbreviations (hn = harmony note)

hn = #(define-music-function (parser location arg) (ly:music?)
;; Harmony Note: Set the tweaks property of the passed in note to use a smaller 
font

  (set! (ly:music-property arg 'tweaks)
    (acons 'font-size -3.5 (ly:music-property arg 'tweaks))) arg)


%
% Lead vocal
%

LeadVox = \relative c'
{
        \set Voice.autoBeaming = ##f
%       \set Staff.instrument = #"Lead vox"
        \clef G
        \key c \major
        \override Staff.TimeSignature #'style = #'()
        \time 4/4
\override Score.SpacingSpanner #'average-spacing-wishes = ##f

        \set Score.markFormatter = #format-mark-box-letters

        % Intro

        \once \override TextScript #'padding = #2.0
        s1*0^\markup { \large { Moderate ballad } }
%\small
\tiny
        e4 g g e8 [ d ] |   % 1
        c4. d8 f [ e d c ] |   % 2
        c4. e8 d4. c8 |   % 3
        c1 |   % 4
\normalsize

        \repeat volta 2
        {
                % A section

\mark \markup { \override #'(font-family . sans) { \box { A } } }

                e4 g g e8 [ d ] |   % 5
                c4. d8 f [ e d c ] |   % 6
                a'4 a8 [ a ] g4. f8 |   % 7
                g1 |   % 8
                e4 g g e8 [ d ] |   % 9
                c4. d8 f ( [ e ) d c ] |   % 10
                c4. e8 d4. c8 |   % 11
                c2 ~ c4 r \bar "||"   % 12

                % B section

\mark \markup { \override #'(font-family . sans) { \box { B } } }

                <c' \hn a \hn e>4 <c \hn a \hn e> <c \hn g \hn e> <c \hn g \hn 
e>8 [ <b \hn g \hn e> ] |   % 13
%               <c' \hn a \hn e>4 <c \hn a \hn e> <c \hn g \hn e> <c \hn g \hn 
e>8 [ <b \hn g \hn e> ] |   % 13
                <a \hn f \hn c>4 <a \hn d, \hn b> <g \hn e \hn c>4. <\hn e c>8 
|   % 14
                <a \hn f \hn d>4 <a \hn f \hn d> <a \hn f \hn c> <a \hn f \hn 
c>8 [ <g \hn e \hn c> ] |   % 15
                <f \hn d \hn a>4 <f \hn d \hn a>
                << { \voiceOne <e \hn b>2 } \new Voice = "v" { \voiceTwo 
\override NoteHead #'font-size = #-2.0 a,4 gs \override NoteHead #'font-size = 
#1.0 } >> \oneVoice |   % 16
                e'4 g g e8 [ d ] |   % 17
                c4. d8 f ( [ e ) d c ] |   % 18
                c4. e8 d4. c8 |   % 19
        }
        \alternative
        {
                {
                        c2 r |   % 20
                }
                {
                        c2 r \bar "||"   % 21
                }
        }

        % A section (modulation)

        \key d \major
\once \override Score.RehearsalMark #'padding = #2.0
\mark \markup { \override #'(font-family . sans) { \box { C } } }

        fs4 a a fs8 [ e ] |   % 22
        d4. e8 g [ fs e d ] |   % 23
        b'4. b8 a4. g8 |   % 24
        a1 |   % 25
        fs4 a a fs8 [ e ] |   % 26
        d4. e8 g [ fs e d ] |   % 27
        d4. fs8 e4. d8 |   % 28
        d2 ~ d4 r |   % 29

        % B section

        \repeat volta 2
        {
\mark \markup { \override #'(font-family . sans) { \box { D } } }

                <d' \hn b \hn fs>4 <d \hn b \hn fs> <d \hn a \hn fs> <d \hn a 
\hn fs>8 [ <cs \hn a \hn fs> ] |   % 30
                <b \hn g \hn d>4 <b \hn e, \hn cs> <a \hn fs \hn d>4. <\hn fs 
d>8 |   % 31
                <b \hn g \hn e>4 <b \hn g \hn e> <b \hn g \hn d> <b \hn g \hn 
d>8 [ <a \hn fs \hn d> ] |   % 32
                <g \hn e \hn b>4 <g \hn e \hn b>
                << { \voiceOne <fs \hn cs>2 } \new Voice = "v" { \voiceTwo 
\override NoteHead #'font-size = #-2.0 b,4 as \override NoteHead #'font-size = 
#1.0 } >> \oneVoice |   % 33
                fs'4 a a fs8 [ e ] |   % 34
                d4. e8 g [ fs e d ] |   % 35
                d4. fs8 e4. d8 |   % 36
        }
        \alternative
        {
                {
                        d1 |   % 37
                }
                {
                        d2 ~ d4 fs8 [ e ] |   % 38
                }
        }

        % Outro

        d4. fs8 e4. d8 |   % 39
        d2 ~ d4 fs8 [ e ] |   % 40
        d4. fs8 e4. d8 |   % 41
%       d1 |   % 42
        << { \voiceOne d1 } \context Voice = v { \voiceThree \tiny fs4 a a fs8 
[ e ] \normalsize } >> \oneVoice |   % 42

%\small
\tiny
        d4. e8 g [ fs e d ] |   % 43
        d1^\fermata \bar "|."   % 44
\normalsize
}

LeadVoxText = \lyricmode
{
        _ _ _ _ _ _ _ _ _ _ _
        _ _ _ _ _

        As the deer pant -- eth for the wa -- ter
        So my soul long -- eth a -- fter thee

        You a -- lone are my heart’s de -- sire _
        And I long to wor -- ship thee. _

        You a -- lone are my strength my shield
        To you a -- lone may my spi -- rit yield

        You a -- lone are my heart’s de -- sire _
        And I long to wor -- ship thee.

        thee.

        I want you more than gold or sil -- ver
        On -- ly you can sa -- tis -- fy

        You a -- lone are the real joy gi -- ver
        And the ap -- ple of my eye. _


        You a -- lone are my strength my shield
        To you a -- lone may my spi -- rit yield

        You a -- lone are my heart’s de -- sire _
        And I long to wor -- ship thee.

        thee _

        and I long to wor -- ship thee _
        and I long to wor -- ship thee
}

LeadVoxTextB = \lyricmode
{
        _ _ _ _ _ _ _ _ _ _ _
        _ _ _ _ _

        You’re my friend and you are my bro -- ther
        E -- ven though you _ are a king

        I love you more than a -- ny o -- ther
        So much more than a -- ny -- thing.
}


%
% Chord names
%

Chords = \chordmode
{
        \override SeparatingGroupSpanner #'padding = #'2.0

%Bah, can't we set this globally?
        \popChords

        % Intro

        c2 e:m/b |   % 1
        a2:m c/g |   % 2
        d2:m g4:sus4 g |   % 3
        c2 g4/c f/c |   % 4

        \repeat volta 2
        {
                % A section

                c2 e:m/b |   % 5
                a2:m c/g |   % 6
                f2 g:sus2/f |   % 7
                c2 g4/c f/c |   % 8
                c2 e:m/b |   % 9
                a2:m c/g |   % 10
                d2:m7 g4:sus4 g |   % 11
                c2. g4/b \bar "||"   % 12

                % B section

                a2:m a:m7/g |   % 13
                f4 g:sus2/f c2/e |   % 14
                d2:m d:m/c |   % 15
                d2:m/b e4:sus4 e |   % 16
                c2 e:m/b |   % 17
                a2:m c/g |   % 18
                d2:m g4:sus4 g |   % 19
        }
        \alternative
        {
                {
                        c2 g4/c f/c |   % 20
                }
                {
                        c2 g/a \bar "||"   % 21
                }
        }

        % A section (modulation)

        d2 fs:m/cs |   % 22
        b2:m d/a |   % 23
        g2 a:sus2/g |   % 24
        d2 a4/d g/d |   % 25
        d2 fs:m/cs |   % 26
        b2:m d/a |   % 27
        e2:m a4:sus4 a |   % 28
        d2. a4/cs |   % 29

        % B section

        \repeat volta 2
        {
                b2:m b:m/a |   % 30
                g4 a:sus2/g d2/fs |   % 31
                e2:m e:m/d |   % 32
                e2:m/cs fs4:sus4 fs |   % 33
                d2 fs:m/cs |   % 34
                b2:m d/a |   % 35
                e2:m7 a4:sus4 a |   % 36
        }
        \alternative
        {
                {
                        d2. a4/cs |   % 37
                }
                {
                        b2:m b:m/a |   % 38
                }
        }

        % Outro

        e2:m7 a4:sus4 a |   % 39
        b2.:m b4:m/a |   % 40
        e2:m7 a4:sus4 a |   % 41
        d2 fs:m/cs |   % 42
        b2:m g:sus2 |   % 43
        d1 \bar "|."   % 44
}


%
% Chord rhythms
%

% Use a RhythmicStaff on the chords instead of this?
% It almost works, but not quite. Doesn't collapse chords above to single 
notes...

StaffC = \relative c
{
        \set Voice.autoBeaming = ##f
%       \set Staff.instrument = #"Rhythm"
        \override Staff.TimeSignature #'style = #'()
        \time 4/4 
        \override NoteHead #'style = #'slash

        % Intro

        c4 c c c |   % 1
        c4 c c c |   % 2
        c4 c c c |   % 3
        c4 c c c |   % 4

        \repeat volta 2
        {
                % A section

                c4 c c c |   % 5
                c4 c c c |   % 6
                c4 c c c |   % 7
                c4 c c c |   % 8
                c4 c c c |   % 9
                c4 c c c |   % 10
                c4 c c c |   % 11
                c4 c c c \bar "||"   % 12

                % B section

                c4 c c c |   % 13
                c4 c c c |   % 14
                c4 c c c |   % 15
                c4 c c c |   % 16
                c4 c c c |   % 17
                c4 c c_\markup { \italic { rit. } } c |   % 18
                c4_\markup { \italic { A tempo } } c c c |   % 19
        }
        \alternative
        {
                {
                        c4 c c c |   % 20
                }
                {
                        c4 c c c \bar "||"   % 21
                }
        }

        % A section (modulation)

        c4 c c c |   % 22
        c4 c c c |   % 23
        c4 c c c |   % 24
        c4 c c c |   % 25
        c4 c c c |   % 26
        c4 c c c |   % 27
        c4 c c c |   % 28
        c4 c c c |   % 29

        % B section

        \repeat volta 2
        {
                c4 c c c |   % 30
                c4 c c c |   % 31
                c4 c c c |   % 32
                c4 c c_\markup { \italic { rit. } } c |   % 33
                c4_\markup { \italic { A tempo } } c c c |   % 34
                c4 c c c |   % 35
                c4 c c c |   % 36
        }
        \alternative
        {
                {
                        c4 c c c |   % 37
                }
                {
                        c4 c c c |   % 38
                }
        }

        % Outro

        c4 c c c |   % 39
        c4 c c c |   % 40
        c4 c c_\markup { \italic { rit. } } c |   % 41
        c4 c c c |   % 42
        c4 c c c |   % 43
        c1-\fermata \bar "|."   % 44
}


\score
{
        <<
%               \new ChoirStaff = "Vox"
                <<
                        \new Staff = leadStaff { \new Voice = "lead" \LeadVox }
                        \new Lyrics \lyricsto "lead" \LeadVoxText
                        \new Lyrics \lyricsto "lead" \LeadVoxTextB
                >>

                \new ChoirStaff = "Rhythm"
                <<
                        \new ChordNames = "chords" \Chords
                        \new RhythmicStaff = "chordRhythm" \StaffC
                >>

                \set Score.skipBars = ##t
                \set Score.melismaBusyProperties = #'()
        >>
        \layout
        {
%               ragged-last-bottom = ##t
                ragged-last = ##t
        }
}


\paper
{
  #(define fonts (make-pango-font-tree
    "Times New Roman"
    "DomCasual BT"
    "Luxi Mono"
    (/ staffSize 20)))
}
% Pop chords as used in English/American popular music
% by James L. Hammons

% Written against \version "2.8.2"

chordFlat = \markup { \hspace #0.2 \tiny \raise #1.0 \flat }
chordSharp = \markup { \hspace #0.1 \teeny \raise #1.0 \sharp }

popChordsMusic =
{
        % Triads

        <c g>-\markup { "5" }
        <c d g>-\markup { "2" }
%       <c d g>-\markup { "sus2" }
        <c f g>-\markup { "sus" }
%       <c f g>-\markup { "sus4" }
%       <c ees ges>-\markup { \small \raise #1.0 "o" }
        <c ees ges>-\markup { \raise #0.8 "o" }
%       <c ees ges>-\markup { "dim" }
%       <c e gis>-\markup { "aug" }                                             
                        % or +

        % Sixths

        <c e g a>-\markup { "6" }
        <c ees g a>-\markup { "m6" }

        % Sevenths (including altered)

        <c e g bes>-\markup { "7" }
        <c ees g bes>-\markup { "m7" }
        <c e g b>-\markup { "maj7" }
        <c f g bes>-\markup { "7sus4" }
        <c d g bes>-\markup { "7sus2" }
        <c e ges bes>-\markup { "7" \chordFlat "5" }
        <c e gis bes>-\markup { "7" \chordSharp "5" }
%       <c e gis bes>-\markup { "aug7" }                                        
                % or +7
        <c ees g b>-\markup { "m(maj7)" }
%       <c ees ges beses>-\markup { \small \raise #1.0 { "o" } "7" }
        <c ees ges beses>-\markup { \raise #0.8 { "o" } "7" }
%       <c ees ges beses>-\markup { "dim7" }
%       <c ees ges bes>-\markup { \small \raise #1.0 { #(ly:export 
(ly:wide-char->utf-8 #x00f8)) } "7" }
%       <c ees ges bes>-\markup { \raise #0.8 { #(ly:export 
(ly:wide-char->utf-8 #x00f8)) } "7" }
        <c ees ges bes>-\markup { "m7" \chordFlat "5" }
        <c e ges b>-\markup { "maj7" \chordFlat "5" }
        <c e gis b>-\markup { "maj7" \chordSharp "5" }

        % Ninths (including altered--incomplete)

        <c e g bes d'>-\markup { "9" }
        <c ees g bes d'>-\markup { "m9" }
        <c e g b d'>-\markup { "maj9" }
        <c e g d'>-\markup { "add9" }
        <c e g a d'>-\markup { "6/9" }
        <c ees g a d'>-\markup { "m6/9" }
        <c ees g b d'>-\markup { "m(maj9)" }
        <c e g bes des'>-\markup { "7" \chordFlat "9" }
        <c e g bes dis'>-\markup { "7" \chordSharp "9" }
%dim7add9, dim7b9, dim7#9, 9#5, 9b5, maj9#5, maj9b5, 9sus4, 9sus2

        % Elevenths (incomplete)

        <c e g bes d' f'>-\markup { "11" }
        <c ees g bes d' f'>-\markup { "m11" }
        <c e g b d' f'>-\markup { "maj11" }
        <c e g f'>-\markup { "add11" }
        <c ees g bes f'>-\markup { "m7add11" }

        % Thirteenths (incomplete)

        <c e g bes d' a'>-\markup { "13" }
        <c ees g bes d' a'>-\markup { "m13" }
        <c e g b d' a'>-\markup { "maj13" }
        <c e g a'>-\markup { "add13" }

        % Misc add chords

        <c e g bes des' aes'>-\markup { "7" \chordFlat "9" \chordFlat "13" }
        <c e gis bes des'>-\markup { "7" \chordSharp "5" \chordFlat "9" }
        <c e g b d' fis'>-\markup { "maj9" \chordSharp "11" }
        <c e g bes d' fis'>-\markup { "9" \chordSharp "11" }
}

% Add to existing exceptions
popChordsAdd = #(append
         (sequential-music-to-chord-exceptions popChordsMusic #t)
         ignatzekExceptions)

% Bah, can't we set this globally?
% \set chordNameExceptions = #popChords

% Bah, this doesn't work either...
% #(set chordNameExceptions popChords)


% Let's try fixing the accidentals with some Scheme...

#(define (chord-name->pop-markup pitch)

  (let* ((alt (ly:pitch-alteration pitch)))

  (make-line-markup
    (list
      (make-simple-markup (vector-ref #("C" "D" "E" "F" "G" "A" "B") 
(ly:pitch-notename pitch)))

      ;; If it's natural, do nothing

      (if (= alt 0)

        (make-line-markup (list empty-markup))

        (if (= alt FLAT)

          ;; Otherwise, handle adding the flat symbol

          (make-line-markup
            (list
              (make-hspace-markup 0.3) ;; WAS: 0.4
              (make-tiny-markup (make-raise-markup 1.0
                (make-musicglyph-markup (string-append "accidentals." 
(number->string alt)))))
            )
          )

          ;; or handle adding the sharp symbol

          (make-line-markup
            (list
              (make-hspace-markup 0.1) ;; WAS: 0.2
              (make-teeny-markup (make-raise-markup 1.0
                (make-musicglyph-markup (string-append "accidentals." 
(number->string alt)))))
            )
          )

        )

      )

    )
  )

  )
)


popChords =
{
  \set chordNameExceptions = #popChordsAdd
  \set chordRootNamer = #chord-name->pop-markup
}

reply via email to

[Prev in Thread] Current Thread [Next in Thread]