A minor or major triad is created with three interface boxes : multiple-items-list-box, button-box, and check-box.
On the left the build note!
button calls a series of boxes :
two list-boxes allow to choose a note name from A to G, and an octave index, from 1 to 5.
the resulting reference is returned as a list with three lisp functions to n->mc[1] ,
n->mc returns a midicents value to a chord box.
On the right, the build chord!
button calls another series of boxes :
The minor
check box is checked and returns "true" to OMIF,
OMIF returns 300, which makes a minor third. If it isn't checked, OMIF returns the value of a major third – 400 mc.
The value of the root is added with 300 and 700 to build a minor triad, via two om+ boxes.
The resulting values are gathered by x-append into one single list and returned to a chord box.
As n->mc returns a list, we have to use a chord box, and not a note box, to create the root of the chord. A note box doesn't accept lists, but atoms.
This pop-up box returns two types of results :
Input #1 is connected to a textfile box, which contains a list of midi channel names . When output #1 is evaluated, it returns the midichannel number.
Input #2 is connected to a lambda patch, which can play the sound of a selected sample.
A sequence function evaluates two elements successively :
The action programmed in the patch is executed when an item is selected in the pop-up-menu box. |
Converts a note name or list of note names into corresponding midi cents values. The reference is the standard notation, where the medium C (6000 midicents) = C3.