2 * Copyright 2003-2009, Haiku, Inc. All rights reserved.
3 * Distributed under the terms of the MIT License.
10 #ifndef PORT_DRIVERS_H
11 #define PORT_DRIVERS_H
14 #include <MidiProducer.h>
15 #include <MidiConsumer.h>
17 class MidiPortConsumer
: public BMidiLocalConsumer
{
19 MidiPortConsumer(int fd
, const char* path
);
21 void Data(uchar
* data
, size_t length
, bool atomic
, bigtime_t time
);
28 class MidiPortProducer
: public BMidiLocalProducer
{
30 MidiPortProducer(int fd
, const char* path
= NULL
);
31 virtual ~MidiPortProducer(void);
36 static int32
_ReaderThread(void* data
);
39 volatile bool fKeepRunning
;
40 thread_id fReaderThread
;
43 #endif // PORT_DRIVERS_H