diff options
author | David Robillard <d@drobilla.net> | 2024-11-16 14:59:31 -0500 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2024-11-24 19:03:19 -0500 |
commit | 25593e614eb3ef6a62a603aa4704d9a4ff49364d (patch) | |
tree | 78140112afa4d764aaeb687104b36fdbc688e0ac /src/process.c | |
parent | 23c175f6b91cfe1a21c7218b27901a600aa5af86 (diff) | |
download | jalv-25593e614eb3ef6a62a603aa4704d9a4ff49364d.tar.gz jalv-25593e614eb3ef6a62a603aa4704d9a4ff49364d.tar.bz2 jalv-25593e614eb3ef6a62a603aa4704d9a4ff49364d.zip |
Factor out jalv_write_get_message() from process callbacks
Diffstat (limited to 'src/process.c')
-rw-r--r-- | src/process.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/process.c b/src/process.c index d069851..2b5a11e 100644 --- a/src/process.c +++ b/src/process.c @@ -18,6 +18,19 @@ #include <assert.h> #include <stddef.h> +int +jalv_write_get_message(LV2_Evbuf_Iterator* const iter, + const JalvURIDs* const urids) +{ + const LV2_Atom_Object get = { + {sizeof(LV2_Atom_Object_Body), urids->atom_Object}, + {0U, urids->patch_Get}, + }; + + return lv2_evbuf_write( + iter, 0, 0, get.atom.type, get.atom.size, LV2_ATOM_BODY_CONST(&get)); +} + static int ring_error(const char* const message) { |