MidiKeyboardComponent?


#1

i’m testing the new MidiKeyboard component, and it integrates well into the filter. apart from a “little” overhead add to each calls of audio processing, i’ve tried to play my synth with the mouse. incidentally, when moving too fast between the keys, some noteoff seems to be lost in the process. but playing my vst synth with midi input (e.g. sequencer or external midi keyboard) in a “crazy performer mode” i don’t get note stucks (i’ve tested widely the voice’s start/stop and allocation/deallocation, and is working perfectly). also sometimes when i press some notes on the keyboard, i see some cpu spikes when releasing notes…
i’ve tried also integrating Daniel’s VirtualPiano component, and my synth treat midi messages injected from the gui as expected.
if you need some more info i’m here.

lou


#2

another thing i’ve discovered casually testing the synth + keyboard component on tracktion. when u minimize the app during play (and there is no background processing activated) the playback stops, but there is no midi allNotesOff or allSoundOff message triggered, cause i see in the keyboard component that the last midi notes played are still on (coloured with yellow)…
this is mostly related with tracktion than with the component, but just to signal the strange behaviour :o


#3

Ta. It’s only a first stab at a keyboard component, I didn’t expect it to be bulletproof just yet. I wanted a keyboard to use in a project I’m working on, and needed some features that weren’t in Daniel’s component, so thought I’d have a go.


#4

i’ve found that there is a lacking note off when u click on a note, then you drag fast to other keys and then u return back to the first key you clicked on . something like pressing C-D-D#-C notes, then C remains on. i’ve not investigated too much into the code but sure is the updateNoteUnderMouse that is loosing a case…
another question, why

bool MidiKeyboardComponent::mouseDownOnKey (int midiNoteNumber, const MouseEvent& e) { return true; }

returns true always ?


#5

Can’t see any bugs in that myself. Are you getting the key being drawn as stuck down, or just the sound continuing?

And mouseDownOnKey is virtual - have a read of its comment.


#6

hey jules i don’t know why but now is working. me crappy i’ve made some tweak to the voice allocation engine that i didn’t managed to catch off. sorry for arising stuff that was perfect already… everything in these days is going bad… :roll:


#7

Ah - glad to see I’m not losing my touch!


#8