Thanks for your reply Lenard,
I looked at the examples and created this working program (see program
below). When I close the program, this error message appears in the
terminal:
PortMidi call failed...
PortMidi: `Bad pointer'
type ENTER...
What can I change in the program to avoid the
Hi,
See below:
On 17/12/10 05:13 PM, Brian Gryder wrote:
#--start miditest.py--
import pygame
import pygame.midi
from pygame.locals import *
[snip some code]
print exit button clicked.
i.close()
Replace i.close() with del i
pygame.midi.quit()
pygame.quit()
How can I detect midi events in pygame? I am able to detect the count of
MIDI devices and input and output device names (see program below) I'd like
to display the midi note names like C3 ON or D3 OFF. I am using the JACK
Audio Connection Kit. Any code snippets, links to articles, or suggestions
Hi Brian,
The pygame midi.py example has an input event display mode.
python -m pygame.examples.midi -i
It is in the examples subdirectory in the pygame package directory.
Unfortunately, the PortMidi with pygame.midi wraps does not have a midi
event callback option, so midi events must be