aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/jack.c4
-rw-r--r--src/port.h14
2 files changed, 12 insertions, 6 deletions
diff --git a/src/jack.c b/src/jack.c
index 6baa14e..de1542e 100644
--- a/src/jack.c
+++ b/src/jack.c
@@ -260,8 +260,8 @@ jack_process_cb(jack_nframes_t nframes, void* data)
static void
jack_latency_cb(const jack_latency_callback_mode_t mode, void* const data)
{
- const Jalv* const jalv = (const Jalv*)data;
- const enum PortFlow flow =
+ const Jalv* const jalv = (const Jalv*)data;
+ const PortFlow flow =
((mode == JackCaptureLatency) ? FLOW_INPUT : FLOW_OUTPUT);
// First calculate the min/max latency of all feeding ports
diff --git a/src/port.h b/src/port.h
index 260c37a..a6a6c5d 100644
--- a/src/port.h
+++ b/src/port.h
@@ -14,14 +14,20 @@
JALV_BEGIN_DECLS
-enum PortFlow { FLOW_UNKNOWN, FLOW_INPUT, FLOW_OUTPUT };
+typedef enum { FLOW_UNKNOWN, FLOW_INPUT, FLOW_OUTPUT } PortFlow;
-enum PortType { TYPE_UNKNOWN, TYPE_CONTROL, TYPE_AUDIO, TYPE_EVENT, TYPE_CV };
+typedef enum {
+ TYPE_UNKNOWN,
+ TYPE_CONTROL,
+ TYPE_AUDIO,
+ TYPE_EVENT,
+ TYPE_CV
+} PortType;
typedef struct {
const LilvPort* lilv_port; ///< LV2 port
- enum PortType type; ///< Data type
- enum PortFlow flow; ///< Data flow direction
+ PortType type; ///< Data type
+ PortFlow flow; ///< Data flow direction
void* sys_port; ///< For audio/MIDI ports, otherwise NULL
LV2_Evbuf* evbuf; ///< For MIDI ports, otherwise NULL
void* widget; ///< Control widget, if applicable