At the moment I'm trying to resolve an specific issue that would not fall
on enharmonic ambiguity, so writing with those intervals made sense in this
situation (tonic and dominant being perfect, subdominant being perfect or
augmented, and all the rest being major or minor). Still, thank you very
much, Tim, for the contribution! I didn't know lilypond could be tweaked so
much like this.

Em qui., 20 de mar. de 2025 às 13:18, Timothy Lanfear <timo...@lanfear.me>
escreveu:

> On 20/03/2025 11:44, Lucas Cavalcanti wrote:
>
> Hello, Lukas. I've re-drafted a mock up of the function in question. but
> now the mock up actually worked... I was just not adding the hash "#" to
> the number argument.... Still, I'll attach the function below to see if it
> can be better optimized.
>
> You could write this function more briefly as below. I wonder if there is
> any ambiguity about transposition by, for example, one semitone: should it
> be \transpose c cis or \transpose c des ?
>
> \version "2.24.0"
>
> #(define pitches (vector #{c#} #{des#} #{d#} #{es#} #{e#} #{f#} #{fis#}
> #{g#} #{as#} #{a#} #{bes#} #{b#} #{c'#}))
>
> someFunction =
> #(define-music-function
>   (note transposeCoeficient)
>   (ly:music? integer?)
>   (make-relative (note) note
>      #{ $note \transpose c #(vector-ref pitches transposeCoeficient) $note
> #}))
>
> \score {\relative c' { \someFunction c4 12 }}
>
> --
> Timothy Lanfear, Bristol, UK.
>
>

Reply via email to