aboutsummaryrefslogtreecommitdiffhomepage
path: root/artnet.h
diff options
context:
space:
mode:
Diffstat (limited to 'artnet.h')
-rw-r--r--artnet.h29
1 files changed, 20 insertions, 9 deletions
diff --git a/artnet.h b/artnet.h
index 806d125..eb60115 100644
--- a/artnet.h
+++ b/artnet.h
@@ -1,5 +1,11 @@
#include "midimonster.h"
+/*
+ * TODO
+ * bind per instance
+ * destination per instance
+ */
+
int artnet_init();
static int artnet_configure(char* option, char* value);
static int artnet_configure_instance(instance* instance, char* option, char* value);
@@ -10,23 +16,28 @@ static int artnet_handle(size_t num, managed_fd* fds);
static int artnet_start();
static int artnet_shutdown();
+typedef struct /*_artnet_universe_model*/ {
+ uint8_t last_frame;
+ uint8_t data[512];
+} artnet_universe;
+
typedef struct /*_artnet_instance_model*/ {
uint8_t net;
uint8_t uni;
uint8_t mode;
char* dest;
+ artnet_universe data;
} artnet_instance_data;
+typedef union /*_artnet_instance_id*/ {
+ struct {
+ uint8_t net;
+ uint8_t uni;
+ } fields;
+ uint64_t label;
+} artnet_instance_id;
+
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;