9

I've already googled the **** out of the web in search of a simple way to get data from a connected midi device. I'm using I Visual Studio 2010 on a Win7 64bit PC.

I've already tried libaries like Improv, JDKSmidi, Portmidi All their example programs compiled with errors and Portmidi did not really provide a useful documentation.

All I want to do, is to read midi input on windows in my program. (Maybe even without an extern libary?)

user1511417
  • 1,880
  • 3
  • 20
  • 41

2 Answers2

8

Take a look at rtmidi. It is small (2 headers and one .cpp file) and very easy to use. http://www.music.mcgill.ca/~gary/rtmidi/

  • Tried id. It's compiling but it keeps saysing "MidiInDummy: This class provides no functionality. There are 0 MIDI input sources available." I tried different midi devices with this. It's not working. Thanks anyway. – user1511417 Sep 22 '12 at 12:51
  • @user1511417 You're not compiling it correctly. You need to do a #define for whatever platform you're on. For example, on Windows compile with `__WINDOWS_MM__` defined. It's explained on the rtmidi website. – Imbue May 16 '19 at 22:17
  • Here is a step by step guide for visual studio: http://beatinginfinity.blogspot.com/2013/05/use-rtmidi-in-windows-in-microsoft.html – Ilyssis Oct 13 '19 at 21:17
2

If you are on windows, you may use Windows multimedia API.

It's quite simple.

MSDN MIDI Reference

There are several articles on codeproject :

http://www.codeproject.com/Articles/2771/Wrapper-Library-for-Windows-MIDI-API

http://www.codeproject.com/Articles/36313/MIDI-Star

rkosegi
  • 14,165
  • 5
  • 50
  • 83