开发者

Read MIDI Device Input In Ruby

Is is possible to trap the M开发者_如何学编程IDI signals being sent by my keyboard connected via MIDI-USB in Ruby? If not Ruby, how would I do it in C so I can make a Ruby extension?


Use PortMidi, which is part of the PortMedia project. A little Googling showed several references to existing Ruby bindings to PortMidi, so you may not need to do much/any work to get things running.

What is PortMedia?

  • PortMedia is a set of APIs and library implementations for music and other media.
  • PortMedia is open-source and runs on Windows, Macintosh, and Linux.
  • Currently, libraries support Audio I/O and MIDI I/O.
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜