[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How can I create from my custom drum note to a pitch? (for fransposi
From: |
Thomas Morley |
Subject: |
Re: How can I create from my custom drum note to a pitch? (for fransposing) |
Date: |
Thu, 31 Mar 2016 20:33:46 +0200 |
2016-03-31 16:34 GMT+02:00 Bernard <address@hidden>:
> How can I create from my custom drum note to a pitch?
>
> Or, strongly related, how can I transpose from a custom drum note to a
> standard piano note (pitch)?
I've no idea what you're talking about.
Drum notes don't have pitches. Ergo, they can't be transposed. The
pitches in midiDrumPitches are somehow creating a midi, but I've no
clue about how it is done either.
You can access those pitches as mapped in midiDrumPitches and put them
into a normal Staff.
The result is crazy to say the least:
drms = \drummode { hh bd }
\new DrumStaff \drms
\new Staff {
\clef bass
$(music-clone
drms
'elements
(begin
(for-each
(lambda (n)
(ly:music-set-property! n 'pitch
(assoc-get (ly:music-property n 'drum-type) midiDrumPitches '()))
(ly:music-set-property! n 'drum-type '()))
(extract-named-music drms 'NoteEvent))
(extract-named-music drms 'NoteEvent)))
}
What do you really want?
-Harm