JMSL Tutorial: JScore
Implementing your own Binary Copy Buffer Transform, part 2
We will implement a Binary Copy Buffer Transform that generates the morphological mean of the two aux sources.
We implement a mutation function where
each resulting Noten is the function of Aux1Noten and Aux2Note n
Specifically:
- the pitch of the resulting Noten = mean pitch of Aux1Noten and Aux2Noten
- the duration of the resulting Noten = mean duration of Aux1Noten and Aux2Noten
Note that this is a very simple mutation function, and you are encouraged to investigate Larry Polansky's exhaustive
listing of morphological mutations
Try It
In the scoreframe opened by this applet,
- select and copy the melody in top staff to aux buffer 1
- select and copy the melody in second staff to aux buffer 2
- Select MutationMean from Transforms -> binary Copy Buffer Transforms menu
- Click in the third staff and select Freeflow Paste. You will see four dotted 32nd notes (the dur mean) and four unaltered notes.
The unaltered notes are there because the buffers were of unequal size.
Recall again that Freeflow Paste is appropriate here because the two sources came from different staves. Paste preserves measure and
staff numbering, while Freeflow Paste simply pours resulting notes into one staff.
Source
View the applet source and mutation source.
(C) 2000 Nick Didkovsky and Phil Burk, All Rights Reserved
JMSL is based upon HMSL (C) Phil Burk, Larry Polansky and David Rosenboom.