aboutsummaryrefslogtreecommitdiffhomepage
path: root/artnet.h
blob: 00a75a732bf3591c0d7509146f312596bd0d8419 (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
25
26
27
28
29
30
31
32
#include "midimonster.h"

int artnet_init();
static int artnet_configure(char* option, char* value);
static int artnet_configure_instance(instance* instance, char* option, char* value);
static instance* artnet_instance();
static channel* artnet_channel(instance* instance, char* spec);
static int artnet_set(instance* inst, size_t num, channel* c, channel_value* v);
static int artnet_handle(size_t num, managed_fd* fds);
static int artnet_start();
static int artnet_shutdown();

typedef struct /*_artnet_instance_model*/ {
	uint8_t net;
	uint8_t uni;
	uint8_t mode;
	char* dest;
} artnet_instance_data;

enum {
	output = 1,
	mark = 2
};

typedef struct /*_artnet_universe_model*/ {
	uint8_t net;
	uint8_t uni;
	uint8_t flags;
	uint8_t last_frame;
	uint8_t data[512];
	uint8_t mask[512];
} artnet_universe;