#include "portlib.h"
int process_event(port_t *p, int type, snd_seq_event_t *ev, int *priate_data)
{
port_write_event(p, ev, 0);
}
int main()
{
unsigned int caps = SND_SEQ_PORT_CAP_WRITE | SND_SEQ_PORT_CAP_SUBS_WRITE | SND_SEQ_PORT_CAP_READ | SND_SEQ_PORT_CAP_SUBS_READ;
port_client_t *client = port_client_new("MIDI filter", SND_SEQ_OPEN_DUPLEX);
port_t *port = port_attach(client, "FILTER port", caps, SND_SEQ_PORT_TYPE_MIDI_GENERIC);
int *priv_data;
/* add callback */
port_add_callback(port, PORT_MIDI_EVENT_CB, (port_callback_t)process_event, priv_data);
port_client_do_loop(client);
return port_detach(port); }
------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Alsa-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/alsa-devel