PluginHost - MIDI Input not working


#1

Is anyone else having problems with PluginHost’s MIDI Input?
(XP SP3)

MIDI seems to flows between plugins, but MIDI Input doesn’t seem to be working
(Tested on my own build and the latest prebuilt version)

Also, I can’t be sure this isn’t broken on OSX, too - I’m using an M-Audio Uno MIDI dongle and I’m not sure if the drivers are Snow Leopard compatible


#2

{Bump}… So… MIDI Input is working for everyone else / No-one has any issues with it? OK


#3

I can’t even remember if I implemented midi-in in the plugin host, TBH. Have you stuck some breakpoints in the midi capture callbacks to see if any events are arriving, and if so, where they get sent to?


#4

It used to work, though I know there was quite a re-write for 1.50, so I realise that something may have broken.

I have tried debugging (hint: I put breakpoints whereever “midiInDesc” is mentioned), and I can see something happening (a breakpoint gets triggered), but I’m pretty certain I’m not looking at the right place, but TBH I really still don’t understand how the thing works! {It’s all magic and wizzardry to me!}

My appologies for being so rubbish. I will try again, I suspect I’ll have to look in AudioGraphIOProcessor


#5

Try adding this in the GraphDocumentComponent constructor:

const StringArray& midiInDevices = MidiInput::getDevices();
for (int i=0; i<midiInDevices.size(); ++i)
{
	if (deviceManager->isMidiInputEnabled(midiInDevices[i]))
	deviceManager->addMidiInputCallback (midiInDevices[i], &graphPlayer);
}

Note that this won’t update when inputs are enabled/disabled. hth


#6

Thanks… I’ve been up to my neck in other stuff for the past few weeks, I’ll try as soon as I can :smiley:


#7

[quote=“bodisiw”]Try adding this in the GraphDocumentComponent constructor:


[/quote]
That worked a treat. Thanks.
I think that (perhaps) the Keyboard’s state (keyState) should be being treated as a MIDI source, so I also tried adding:

	deviceManager->addMidiInputCallback (T("MIDI Kbd"), &graphPlayer.getMidiMessageCollector());

To try to capture the Midi Keyboard Component’s output (but this didn’t seem to work).