lilypond-user
[Top][All Lists]
Advanced

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

Re: F7 chord appearing as E#7 when I transpose


From: Mats Bengtsson
Subject: Re: F7 chord appearing as E#7 when I transpose
Date: Fri, 13 Jun 2008 14:47:15 +0200
User-agent: Thunderbird 2.0.0.5 (X11/20070716)

Since the same request has appeared for ordinary notes, some clever Scheme hackers have made a function that automatically gets rid of the extra accidentals by enharmonically rewriting the music. Fortunately, it turns out that the same functions works also for chords. So, go to LSR http://lsr.dsi.unimi.it/, search for transpose, click on the typeset music for the "Smart transpose" snippet to see the corresponding LilyPond code, copy the lines defining the functions naturalise-pitch, naturalise and naturalizeMusic (i.e. all the lines up to " (naturalise m))", except for the line "music = ...") and paste them at the top of your own file. Then, in your code replace
transposeHarmonies = \transpose c b \harmonies
by
transposeHarmonies = \naturaliseMusic \transpose c b \harmonies
and hopefully your teacher will be more satisfied.

   /Mats


Robert Glover wrote:
I am created a lead sheet consisting of words, chords, and melody in the key of C. The bridge has these chords:
   fis2:m7     b2:7     |       e2:maj7     cis2:m7  |

   In the key of C they appear okay in the pdf as:  F#m7   B7   Etriangle  C#7

  but when I transpose it from C to B those chords appear as:  E#m7  A#7  
D#7triangle  B#m7.

  When I transpose the same key of C lead sheet to a flat key, for example E 
flat, it appears okay in the pdf.
For example in key of E flat:   Am7  D7  Gtriangle  Em7

   My jazz piano teacher tells me that in a jazz lead sheet it is mandatory that  an "F" chord be notated as 
an "F" chord no matter what the key is.  Specifically, my jazz piano teacher tells me that notating an 
"F" chord as "E#" is absolutely not allowed in a jazz lead sheet.

What I am trying to do is have one version of the complete song in the key of "C" and then print out 12 lead sheets, one in each key. Below shows the program I use for the key of B. After that I show the program I use for the key of E flat. After that, I show the contents of file "actual_song_for_include.ly" which I include in all 12 of my transposition file. My jazz piano teacher tells me that what I need is a way to force Lilypond to in all circumstances to never ever print a chord as a B# chord, to always automatically change it to a C chord. Similarly, an E# chord should always be automatically changed to an "F" chord. Same for an Fb chord, which LilyPond should always notate as an "E" chord. Finally, a Cb chord should be notated as a B chord.

 Help with this very  much appreciated.  Thank you in advance.


..(below is contents of file transpose_song_into_KEY_B.ly )...
=====================
\include "..\actual_song_for_include.ly" transposeHarmonies = \transpose c b \harmonies transposeMelody = \transpose c b \melody \include "template_boilerplate_AFTER.ly" =======================


..(below is contents of file transpose_song_into_KEY_E_FLAT.ly )...
======================
\include "..\actual_song_for_include.ly" transposeHarmonies = \transpose c ees \harmonies transposeMelody = \transpose c ees \melody \include "template_boilerplate_AFTER.ly" ======================


..(below is contents of file actual_song_for_include.ly )...
=============================
\version "2.10.33"

#(set-default-paper-size "letter")
\paper {
   head-separation = 2\mm
   page-top-space = 3\mm
   before-title-space = 3\mm
   after-title-space = 3\mm
   top-margin = 2\mm
   bottom-margin = 2\mm
   between-system-space =  10\mm
   between-system-padding = 2\mm
   foot-separation = 2\mm
}
\header
   {
      title = "Moonlight In Vermont"
      composer = "Music by Karl Suessdorf"
      poet = "Lyric by John Blackburn"
      copyright = "copyright 1945, 1945, renewed 1972"
      enteredby = "address@hidden"
   }
\layout
   {
     indent = 0.0\cm
   }

theLyricsOne = \lyricmode {
  Pen -- nies in a               | stream,                |  Fall -- ing 
leaves, a    | sy -- ca -- more,  |
  Moon -- light in Ver --        | mont.                  |  I -- cy fin -- ger 
      | waves,             |
  Ski trails on a                | moun -- tain -- side,  |  Snow -- light in 
Ver --  | mont        |
Tel -- e -- graph ca -- bles, they | sing down the high -- way and | trav -- el each bend __ in the | road. | Peo -- ple who meet __ in this | ro -- man -- tic set -- ting are | so hyp -- no -- tized by the | love -- ly | Eve -- ning sum -- mer | breeze, | Warb -- ling of a | mead -- ow -- lark, | Moon -- light in Ver -- | mont. You and I and moon -- light in Ver -- | mont. }





melody = \relative c'
{
  \time 4/4
  \clef treble
  \key c \major
% ****************************************************************
% First "A" Section  (melody)
% ****************************************************************

\repeat volta 2 {

a'4    g     e     d      |
e1                        |
a4    g     e4.     c8    |
d8 e8 aes,2. | e'4 d c a |
c1                        |
\break
a'4    g     e     d      |
e1                        |
a4    g     e4.     c8    |
d8 e8  aes,2.             |
e'4    d     c     a      |
c1                        |
\break

% ****************************************************************
% First "B" Section  (melody)
% ****************************************************************



b8 [b b b] ~ b b4 b8     |
b8 b4 b8 b8 b4 b8        |
\break
b8 [b8 b8] b'8 ~ b4 a8 b8  |
gis1  |


c,8 [c8 c8 c8] ~ c8 c4 c8   |
\break

c8 c4 c8 c8 c4 c8         |
c8 [c8 c8] c'8 ~ c4 bes8 c8 |
a2  aes2                  |
\break
% ****************************************************************
% Second "A" Section (melody) % ****************************************************************

a4    g     e     d       |
e1                        |
a4    g     e4.     c8    |
d8 e8 aes,2. | e'4 d c a |
c1                        |
\break

}

% ****************************************************************
% Ending   (melody)
% ****************************************************************

gis8 a c e a b gis ais |
g1                     |

}


harmonies = \chordmode {

% ****************************************************************
% First "A" Section  (chords)
% ****************************************************************
      c2:6      a2:m7       |
      d2:m7     g2:7        |
      c2:6      a2:m7       |
bes1:5-.7 | d2:m7 g2:7 |
      c2:6      g2:7sus4    |
c2:6 a2:m7 |
      d2:m7     g2:7        |
      c2:6      a2:m7       |
bes1:5-.7 | d2:m7 g2:7 |
      c1:6                  |
% ****************************************************************
% First "B" Section   (chords)
% ****************************************************************
fis2:m7 b2:7 |
      e2:maj7     cis2:m7  |
      fis2:m7     b2:7     |
      e1:maj7               |
      g2:m7      c2:7       |
      f2:maj7    d2:m7      |
      g2:m7      c2:7       |
      f2:maj7    g2:5-.7.9- |
% ****************************************************************
% Second "A" Section   (chords)
% **************************************************************** c2:6 a2:m7 |
      d2:m7     g2:7        |
      c2:6      a2:m7       |
bes1:5-.7 | d2:m7 g2:7 |
      c1:6                  |
% ****************************************************************
% Ending   (chords)
% ****************************************************************
      d2:7 ~ d4:7      des4:7       |  c1:6 |
      \bar "||"
}
=============================



..(below is contents of file template_boilerplate_AFTER.ly )...
=============================

\score {
   <<
   \new ChordNames {
     \set chordChanges = ##t
     \transposeHarmonies
   }
\new Voice = "melody" {
     \transposeMelody
   }
   \new Lyrics \lyricsto "melody" \theLyricsOne

   >>

   \layout{
     \context {
       \Score \override SpacingSpanner #'base-shortest-duration = 
#(ly:make-moment 1 16)
     }
   }
}


\score { <<
      \new ChordNames {
         \set chordChanges = ##t
         \transposeHarmonies
      }
   \new Staff \transposeMelody
   >>

   \midi{
     \context {
       \Score tempoWholesPerMinute = #(ly:make-moment 85 4)     % set midi tempo
     }
   }
}

=============================


_______________________________________________
lilypond-user mailing list
address@hidden
http://lists.gnu.org/mailman/listinfo/lilypond-user

--
=============================================
        Mats Bengtsson
        Signal Processing
        School of Electrical Engineering
        Royal Institute of Technology (KTH)
        SE-100 44  STOCKHOLM
        Sweden
        Phone: (+46) 8 790 8463                         
       Fax:   (+46) 8 790 7260
        Email: address@hidden
        WWW: http://www.s3.kth.se/~mabe
=============================================





reply via email to

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