hail monks,

well, i must say, you monks were so much help on my last post, i must tap some more of this bottomless knowledge...

OK, i am playing around with the Win32::MIDI module ( on a win32 machine ) and i wanted to know if it were possible to play a chord with this module? basically a snippet of the example is as follows:
my $midi_obj = Win32::MIDI->new(); # print number of available (writing) devices print $midi_obj->numDevices() . "\n"; # open a device $midi_obj->openDevice(0); # set default channel $midi_obj->cur_channel(1); # play a note by absolute value (numeric) # middle C - 60 # note,dur,velocity $midi_obj->play_note(60,2.5,127) || print $midi_obj->error() . "\n" an +d $midi_obj->reset_error();


there are some neat things you can do with this module, but i couldnt seem to find anything on playing chords... i was thinking maybe if you had two channels open each note would play on the each channel simultaneously, but that did not work... i dont know if this module is just not built to play chords, or what? but if you monks can suggest another module that can be used on win32 for chords, i would be much obliged.

thanks alot for the help!

In reply to playing chords with MIDI modules... by primus

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.