lilypond-user-fr
[Top][All Lists]
Advanced

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

Re: Chiffrage des accords de jazz


From: Vincent Gay
Subject: Re: Chiffrage des accords de jazz
Date: Fri, 12 Nov 2021 21:23:56 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.2.1

Le 12/11/2021 à 19:17, xtof pno a écrit :
Merci Martial,
L'exemple me parle effectivement, mais je n'arrive pas à ce résultat.
Un truc qui bloque :


\version ""


est-ce que ceci correspond à tes attentes ? Si oui te reporter à ma première réponse, sinon je ne comprends pas ce sue tu cherche



%%%%%%%%%%%%%%%%%%


\version "2.18.2"

globalC = {
  \key c \major
  \numericTimeSignature
  \time 4/4 }


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Creating jazz-style chords
% Borrowed from Jean-Pierre's good work at:
%               https://sites.google.com/site/jpgzic/home
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


% modification of the procedure "chordRootNamer"
%---- Definition of chord alterations -------
#(define (JazzChordNames pitch majmin)    ;majmin is a required argument for "chordNamer", but not used here
  (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 (= alt 0)            ; alteration ?
      (markup "")        ; do nothing
      (if (= alt FLAT)    ; flat or sharp
        (markup "♭")
        (markup "♯")
      )
    )
      )
    )
  )
)

%----- markup commands to make it easier to write chords -----
%----- this section can be adapted as desired (I don't like "MI" and "MA", for example)
% for minor chords, use "acMin" to print a small "m"
#(define-markup-command (acMin layout props extension) (string?)
  (interpret-markup layout props
    (markup #:small "m" #:super extension)))

% for major chords, use "acMaj" to print a small "M"
#(define-markup-command (acMaj layout props extension) (string?)
  (interpret-markup layout props
    (markup #:super "^" #:super extension)))

% for chords with up to three alterations, stacked on top of each other
#(define-markup-command (acAlt layout props strA strB strC) (string? string? string?)
  (interpret-markup layout props
    (markup
      #:super strA
      #:fontsize 1.5 "["
      #:fontsize -4
      #:raise 2
      #:center-column (strB strC)
      #:fontsize 1.5 "]"
    )
  )
)

% modify the built-in "chordNameExceptions"
%----- change chord exceptions for jazz notation -----
%
%    degrés             markup                % écriture
JazzChordsList = {

% minor third chords - 3 notes
  <c es ges>1-\markup { \raise #0.7 "°" } % :dim
  <c es g>-\markup { \acMin #"" } % :m

% minor third chords - 4 notes
  <c es ges beses>-\markup { \raise #0.7 "°7" } % :dim7
  <c es gis>-\markup { \acMin #"aug" } % :m5+ (Ab/C)
  <c es g a>-\markup { \acMin #"6" } % :m6
  <c es g as>-\markup { \acMin #">6" } % :m6
  <c es ges bes>-\markup { Ø } % :m7.5-
  <c es g bes>-\markup { \acMin #"7" } % :m7
  <c es gis bes>-\markup { \acMin #"7 <5" } % :m7.5+
  <c es g b>-\markup { \acMin #"^" } % :m7+
  <c es g d'>-\markup { \acMin #"add9" } % :m5.9

% minor third chords - 5+ notes
  <c es g a d'>-\markup { \acMin #"6/9" } % :m6.9
  <c es g bes des'>-\markup { \acMin #"7(>9)" } % :m7.9-
  <c es g bes d'>-\markup { \acMin #"9" } % :m9
  <c es ges bes d'>-\markup { \acMin #"9(>5)" } % :m9.5-
  <c es g b d'>-\markup { \acMin #"^9" } % :m9.7+
  <c es g bes dis'>-\markup { \acMin #"7(<9)" } % :m7.9+
  <c es g bes f'>-\markup { \acMin #"7(add 11)" } % :m7.11
  <c es ges bes f'>-\markup { @ \super #"(11)" } % :m7.11
  <c es g bes a'>-\markup { \acMin #"7(add 13)" } % :m7.13
  <c es g bes d' f'>-\markup { \acMin #"11" } % :m11
  <c es ges bes d' f'>-\markup { \acMin #"11(>5)" } % :m11.5-
  <c es g bes d' f' a'>-\markup { \acMin #"13" } % :m13

% major third chords - 3 notes
  <c e ges>-\markup { \super ">5" } % :5-
  <c e gis>-\markup { \super "aug" } % :aug

% major third chords - 4 notes
  <c e g a d'>-\markup {
      \super "6"
      \hspace #-0.5 \raise #0.7 \tiny "/"
      \hspace #-0.5 \tiny "9"
      }    % :6.9
% special chords
  <c> -\markup { \small \super "bass" } % :c:1
  <c g> -\markup { \small \super "power" } % :c:1.5
  <c e g bes c'>-\markup { \super "7alt" } % :c:8
%  <c e g b>-\markup { ^ } % :maj
  <c e g b>-\markup { \acMaj #""} % :maj
  <c e ges b>-\markup { \acMaj #">5" } % :maj.5-
  <c e gis b>-\markup { \acMaj #"<5" } % :maj.5+

  <c e ges bes>-\markup { \super "7(>5)" } % :7.5-
  <c e gis bes>-\markup { \super "7+" } % :7.5+
  <c e g d'>-\markup { \super "add9" } % :1.3.5.9
 
% major third chords - 5+ notes
  <c e g b d'>-\markup { \acMaj #"9" } % :maj9
  <c e g bes des'>-\markup { \super "7(>9)" } % :9-
  <c e g bes d' fis'>-\markup { \super "9(<11)" } % :9.11+
  <c e g bes dis'>-\markup { \super "7(<9)" } % :9+
  <c e g bes fis'>-\markup { \super "7(<11)" } % :7.11+
  <c e g b fis'>1-\markup { \acMaj "(<11)"}
  <c e g b d' fis'>1-\markup { \acMaj #"9" \super "(<11)"}
  <c e g bes aes'>-\markup { \super "7(>13)" } % :7.13-
  <c e g b d' f'>-\markup { \acMaj #"11" } % :maj11
  <c e g b d' a' >-\markup { \acMaj #"13" } % :maj13
  <c e g bes d' a' >-\markup { \super "13" } % :13
  <c e g b d' aes' >-\markup { \acMaj #"9(>13)" } % :13
  %<c e g bes des' a' >-\markup { \super "13(>9)" } % :13.9-
  <c e g bes des' a' >-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #">9" #"13" } % :13.9-
  <c e g bes dis' aes'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #"<9" #">13" } % :9+.13-
  <c e g bes d' fis' a'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #"<11" #"13" } % :11+.13  
  <c e g bes des' fis'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #">9" #"<11" } % :9-11+  
 
  %<c e ges bes des'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #">5" #">9" } % :5-9-
  <c e ges bes d' a'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #"13" #">5" } % :13.5-
  <c e g bes des' as'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #">13" #">9" } % :9-13-


%   <c e ges bes des'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #">9" #">5" } % :5-9-
%    <c e gis bes des'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #">9" #"<5" } % :5+9-
%   <c e ges bes dis'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #"<9" #">5" } % :5-9+
%    <c e gis bes dis'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #"<9" #"<5" } % :5+9+

  <c e ges bes des'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #">9" #">5" } % :9-5-
  <c e gis bes des'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #">9" #"<5" } % :9-5+
  <c e ges bes dis'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #"<9" #">5" } % :9+5-
  <c e gis bes dis'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #"<9" #"<5" } % :9+5+



%   <c e gis des'>-\markup { \override #'(baseline-skip . 2) \acAlt #"7" #"<9" #">5" } % :9-.5+



% sustained chords
  <c d g>-\markup { \super "sus2" } % :sus2
  <c f g>-\markup { \super "sus" } % :sus4
  <c f g bes>-\markup { \super "7sus" }  % :sus4.7
  <c f g bes d'>-\markup { \super "9sus" }  % :sus4.7.9
  <c f g dis'>-\markup { \super "<9sus" }  % :sus4.9+
   <c f g bes d' a' >-\markup { \override #'(baseline-skip . 2) \acAlt #"" #"13" #"sus" } % :13sus4
% sans septième
   <c e g d'>-\markup { \super "add9" } % c1:3.5.9
  <c f g d'>-\markup { \override #'(baseline-skip . 2) \acAlt #"" #"sus" #"add9" } % c:3.5.9sus4
  <c e g d' aes' >-\markup { \override #'(baseline-skip . 2) \acAlt #"" #"add9" #">13" }
  %-\markup { \super "add9(>13)" } % c:3.5.9.13-
 
 
 
}

% variable needed to use chord exceptions
JazzChords = #(append (sequential-music-to-chord-exceptions JazzChordsList #t) ignatzekExceptions)

% modify the default ChordNames context
\layout {
  \context {
    \ChordNames
    chordRootNamer = #JazzChordNames    % update the chord names
    chordNameExceptions = #JazzChords    % update the chord exceptions
    %\override ChordName.font-name = #"lilyjazz-chord"  % use the custom font for displaying the chords
  }
}


chordNames = \chordmode {
  \globalC
  % Ajouter ici des chiffrages.
   \set additionalPitchPrefix = "add"
  c2:maj7 13
  a:m7 11
 f4:min7.5-
aes4/b
e:min7 9  
 es4/a
  d4:min7  }

%    \set chordNameExceptions = #chExceptions
%   g:9-.13-
%      \unset chordNameExceptions
% e:min7  a: 7
% }

rightC = \relative c' {
  % En avant la musique !
<c e g a c>4 c' <g c d g> <g g'>
<a c e fis a>8 b' <es, aes c> b'16 a! <g, d' f a>8 g' <bes, es g> e!
<a, c f>8 g' <b,! es aes> g'16 f <g, b e>8 d' <cis, f! a! c!> e' |
}

leftC = \relative c {
  % En avant la musique !
<c, c'>4. <c c'>16 <b b'> <a a'>4 <b'' c e>
<fis e'>4 <b dis a'> <e, d'> <a cis g'>
<d, c'>4 <g f'!> <e d'> <a, g'> |
}


chordsPart = \new ChordNames \chordNames

pianoPart = \new PianoStaff \with {
  instrumentName = "Piano"
} <<
  \new Staff = "right" \with {
    midiInstrument = "acoustic grand"}  
  { << \globalC \rightC >> }
  \new Staff = "left" \with {
    midiInstrument = "acoustic grand"
  }  { \clef bass << \globalC \leftC>> }
>>

\score {
  <<
    \chordsPart
    \pianoPart
       >>
  \header {
    title = "Niveau 3"
  }
  \layout { }
  \midi {
    \tempo 4=80
  } }




-- 
Vincent Gay
Envoyé depuis mon saxo-phone :)
https://myrealbook.vintherine.org/ - http://photos.vintherine.org/

Attachment: OpenPGP_signature
Description: OpenPGP digital signature


reply via email to

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