summaryrefslogtreecommitdiff
path: root/mutex.h
blob: 2f3c6537abebaf950eb59322b3c475769f53e982 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#ifndef MUTEX_H
#define MUTEX_H

#include <pthread.h>

typedef struct {
	int note;
	int state;
	int velocity;
	int preset;
	int action;
} SharedData;

extern SharedData shared_data;

extern pthread_mutex_t mutex;
extern pthread_cond_t cond_midi;
extern pthread_cond_t cond_synth;

void initialize_mutex();
void destroy_mutex();

#endif // MUTEX_H