Midi player question

Karl Ramberg karl.ramberg at chello.se
Sun Apr 6 08:29:51 UTC 2003

Stephane Ducasse wrote:
> Hi all
> My sons discovered the MidiPlayer in Squeak and I have the following
> questions:
>         - is there anybody that builds other simple music tools for kids on
> top on that?
Have not done any work on it yes but I have been thinking of using 
a SketchMorph for the for the sequenser so one can paint the music 
and relate different colors to different instruments. 

>         - the pianoMorph does not refresh well (some keys stay red once
> pressed)
>         - is there a way to select other intruments (when we do not load a
> midi file). 
This is described in a class comment:
"This class adds state and controls to the basic PianoKeyboardMorph so
 that notes of reliable duration can be keyed into a score without the
 need for a real keyboard.

 To try this out, execute...

       | n score | n _ 3.
       score _ (MIDIScore new tracks: ((1 to: n) collect: [:i | Array new]);
               trackInfo: ((1 to: n) collect: [:i | 'Instrument' , i printString]);
               tempoMap: nil; ticksPerQuarterNote: 96). 
      ScorePlayerMorph openOn: score title: 'empty score'

 Then open a pianoRoll and, from that, open a keyboard.  The rule is that
 the keyboard will append after the current selection.  If the current
 selection is muted or nil, then input will go to the end of the first
 non-muted track."


More information about the Squeak-dev mailing list