summaryrefslogtreecommitdiff
path: root/src/drumgizmo.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/drumgizmo.h')
-rw-r--r--src/drumgizmo.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/drumgizmo.h b/src/drumgizmo.h
index e79dad0..92faa3c 100644
--- a/src/drumgizmo.h
+++ b/src/drumgizmo.h
@@ -41,6 +41,8 @@
#include "mutex.h"
+#include "message.h"
+
#define MAX_NUM_CHANNELS 512
class DrumGizmo {
@@ -68,7 +70,20 @@ public:
std::string midimapfile;
std::string kitfile;
+ /*
+ * Send a message to the engine. The engine takes over the memory.
+ */
+ void sendMessage(Message *msg);
+
+ /*
+ * Receive message from the engine. The caller takes over the memory.
+ */
+ Message *receiveMessage();
+
private:
+ Mutex message_mutex;
+ std::list<Message *> message_queue;
+
DrumKitLoader loader;
Mutex mutex;