Jump to content

New pitch language

From LilyPond wiki
Revision as of 22:49, 26 October 2025 by Jean Abou Samra (talk | contribs) (Import snippet from LSR)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

How to create your own notes language:

[edit | edit source]

For Example, pitches in my 'alpha' language: Only one letter per note, the whole alphabet is used "m, q, r & s": remaining available for minor chord, chord repeats, rest & blank.

For use with Frescobaldi (transposing, translating):

[edit | edit source]

Add the following lines to : ly/pitch/__init__.py
'alpha': ( ('c', 'd', 'e', 'f', 'g', 'a', 'b'), ('eses', 'eseh', 'es', 'eh', , 'ih', 'is', 'isih', 'isis'), (('aes', 'h'), ('bes', 'i'), ('ces', 'j'), ('des', 'k'), ('ees', 'l'), ('fes', 'n'), ('ges', 'o'), ('ais', 't'), ('bis', 'u'), ('cis', 'v'), ('dis', 'w'), ('eis', 'x'), ('fis', 'y'), ('gis', 'z')) ),


\version "2.24.0"

\version "2.24.0"
\header{footer = "" tagline = "" }

alpha = #(append (assoc-get 'nederlands language-pitch-names)
  `(
         (h . ,(ly:make-pitch -1 5 FLAT))
         (i . ,(ly:make-pitch -1 6 FLAT))
         (j . ,(ly:make-pitch -1 0 FLAT))
         (k . ,(ly:make-pitch -1 1 FLAT))
         (l . ,(ly:make-pitch -1 2 FLAT))
         (n . ,(ly:make-pitch -1 3 FLAT))
         (o . ,(ly:make-pitch -1 4 FLAT))
         (p . ,(ly:make-pitch -1 6 DOUBLE-FLAT))
         (t . ,(ly:make-pitch -1 5 SHARP))
         (u . ,(ly:make-pitch -1 6 SHARP))
         (v . ,(ly:make-pitch -1 0 SHARP))
         (w . ,(ly:make-pitch -1 1 SHARP))
         (x . ,(ly:make-pitch -1 2 SHARP))
         (y . ,(ly:make-pitch -1 3 SHARP))
         (z . ,(ly:make-pitch -1 4 SHARP))
  ))

pitchnames = \alpha
#(ly:parser-set-note-names pitchnames) 
\language "alpha"
\score {
  <<
    \new Voice = "one" {
\relative c''{
\time 7/4
t u v w x y z
<a a,> b, c d e f <g g,> 
h, i j k l n o 
p,  
}
    }
    \new Lyrics \lyricsto "one" {
t u v w x y z
a b c d e f g 
h i j k l n o 
p 
    }
  >>
}