aboutsummaryrefslogtreecommitdiffstats
path: root/src/jalv_internal.h
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2011-06-19 23:43:48 +0000
committerDavid Robillard <d@drobilla.net>2011-06-19 23:43:48 +0000
commitbe2a8ef955c2091a2639d4fc93dbc978615733a6 (patch)
tree21a9056c9f7ab0ffff6f551abd6a2aa833b9aa5d /src/jalv_internal.h
parent3e6c580c197929c126613fcfc546308abdc18c09 (diff)
downloadjalv-be2a8ef955c2091a2639d4fc93dbc978615733a6.tar.gz
jalv-be2a8ef955c2091a2639d4fc93dbc978615733a6.tar.bz2
jalv-be2a8ef955c2091a2639d4fc93dbc978615733a6.zip
Send control output port updates to UIs (commonly used for metering).
git-svn-id: http://svn.drobilla.net/lad/trunk/jalv@3407 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/jalv_internal.h')
-rw-r--r--src/jalv_internal.h14
1 files changed, 12 insertions, 2 deletions
diff --git a/src/jalv_internal.h b/src/jalv_internal.h
index 5ee7755..950d1b7 100644
--- a/src/jalv_internal.h
+++ b/src/jalv_internal.h
@@ -32,16 +32,23 @@
extern "C" {
#endif
+#define JALV_UI_UPDATE_HZ 15
+
typedef struct {
LilvWorld* world; /**< Lilv World */
Symap* symap; /**< Symbol (URI) map */
jack_client_t* jack_client; /**< Jack client */
- jack_ringbuffer_t* events; /**< Control change events */
+ jack_ringbuffer_t* ui_events; /**< Port events from UI */
+ jack_ringbuffer_t* plugin_events; /**< Port events from plugin */
sem_t* done; /**< Exit semaphore */
const LilvPlugin* plugin; /**< Plugin class (RDF data) */
+ const LilvUI* ui; /**< Plugin UI (RDF data) */
LilvInstance* instance; /**< Plugin instance (shared library) */
- uint32_t num_ports; /**< Size of the two following arrays: */
+ SuilInstance* ui_instance; /**< Plugin UI instance (shared library) */
struct Port* ports; /**< Port array of size num_ports */
+ uint32_t num_ports; /**< Size of the two following arrays: */
+ jack_nframes_t sample_rate; /**< Sample rate */
+ jack_nframes_t event_delta_t; /**< Frames since last update sent to UI */
LilvNode* input_class; /**< Input port class (URI) */
LilvNode* output_class; /**< Output port class (URI) */
LilvNode* control_class; /**< Control port class (URI) */
@@ -62,6 +69,9 @@ int
jalv_open_ui(Jalv* jalv,
SuilInstance* instance);
+bool
+jalv_emit_ui_events(Jalv* jalv);
+
#ifdef __cplusplus
} // extern "C"