Virtual Endpoints in CoreMidi

2 posts / 0 new
Last post
bensmiley
Virtual Endpoints in CoreMidi
bensmiley

MyMIDIReadProc called twice per event

Thanks Ben, your tutorial was very helpful!

But I'm a bit puzzled by the fact that MyMIDIReadProc is called with two 'note on event' per event, where only one 'note on event' is expected. Can you explain that? And is there a work-around to fix this?

All the best.

There could be a several reasons. It could be that the MIDI track you're playing has multiple parts i.e. piano and guitar. If the notes for these parts were the same it would cause the problem you're describing. Have you replicated this problem for different tracks? Another possibility is that it's actually ending the previous note and immediately starting the next note. A weird issue I noticed is that sometimes instead of using a note off command, the player sends a note command with a zero velocity. This has the same effect but can be confusing.

Add new comment

Filtered HTML

  • Web page addresses and e-mail addresses turn into links automatically.
  • You can enable syntax highlighting of source code with the following tags: <code>, <blockcode>, <c>, <cpp>, <drupal5>, <drupal6>, <java>, <javascript>, <php>, <python>, <ruby>. The supported tag styles are: <foo>, [foo].
  • Allowed HTML tags: <a> <em> <strong> <cite> <blockquote> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.