[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Changing notes based on fingerings
From: |
Eric Knapp |
Subject: |
Changing notes based on fingerings |
Date: |
Wed, 16 Jul 2008 09:13:21 -0500 |
The next issue in trying to extend Lilypond for my instrument is that
I want to change things in the Note based on the text in the
Fingering. Here's an example, this displayMusic call results in the
make-music call that is after it. I have code working that gives me
the "2" from the FingeringEvent that I got from the very helpful Neil
Puttock. Now I need to be able to retrieve the NoteEvent that is in
the same list.
\displayMusic {a''2-2}
(make-music
'SequentialMusic
'elements
(list (make-music
'EventChord
'elements
(list (make-music
'NoteEvent <------ I want to make changes here.
'duration
(ly:make-duration 1 0 1 1)
'pitch
(ly:make-pitch 1 5 0))
(make-music
'FingeringEvent
'digit
2))))) <---- Based on this.
If I'm in a function that was delivered a Fingering grob, can I
navigate up to the containing list and then up to the SequentialMusic
object? Or is this not the direction that will give me a solution? The
other idea I have about this is to override the creation of all music
notes and if there is a Fingering object then rewrite the entire
make-music call. I don't know how to do that, either.
Thanks,
-Eric
- Changing notes based on fingerings,
Eric Knapp <=