summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/server/ConnectionImpl.cpp3
-rw-r--r--src/server/ControlBindings.cpp3
-rw-r--r--src/server/JackDriver.cpp5
-rw-r--r--src/server/ingen_lv2.cpp3
-rw-r--r--src/server/internals/Controller.cpp5
-rw-r--r--src/server/internals/Note.cpp8
-rw-r--r--src/server/internals/Trigger.cpp5
-rw-r--r--src/shared/AtomReader.cpp7
8 files changed, 15 insertions, 24 deletions
diff --git a/src/server/ConnectionImpl.cpp b/src/server/ConnectionImpl.cpp
index 1350d16c..6c17618e 100644
--- a/src/server/ConnectionImpl.cpp
+++ b/src/server/ConnectionImpl.cpp
@@ -120,8 +120,7 @@ ConnectionImpl::queue(Context& context)
}
LV2_Atom_Sequence* seq = (LV2_Atom_Sequence*)src_buf->atom();
- LV2_SEQUENCE_FOREACH(seq, i) {
- LV2_Atom_Event* const ev = lv2_sequence_iter_get(i);
+ LV2_ATOM_SEQUENCE_FOREACH(seq, ev) {
_queue->write(sizeof(LV2_Atom) + ev->body.size, &ev->body);
context.engine().message_context()->run(
_dst_port->parent_node(), context.start() + ev->time.frames);
diff --git a/src/server/ControlBindings.cpp b/src/server/ControlBindings.cpp
index 96cc669c..0cfd5042 100644
--- a/src/server/ControlBindings.cpp
+++ b/src/server/ControlBindings.cpp
@@ -355,8 +355,7 @@ ControlBindings::pre_process(ProcessContext& context, Buffer* buffer)
}
LV2_Atom_Sequence* seq = (LV2_Atom_Sequence*)buffer->atom();
- LV2_SEQUENCE_FOREACH(seq, i) {
- LV2_Atom_Event* const ev = lv2_sequence_iter_get(i);
+ LV2_ATOM_SEQUENCE_FOREACH(seq, ev) {
if (ev->body.type == uris.midi_MidiEvent) {
const uint8_t* buf = (const uint8_t*)LV2_ATOM_BODY(&ev->body);
const Key key = midi_event_key(ev->body.size, buf, value);
diff --git a/src/server/JackDriver.cpp b/src/server/JackDriver.cpp
index 102bcd17..68a2d683 100644
--- a/src/server/JackDriver.cpp
+++ b/src/server/JackDriver.cpp
@@ -166,9 +166,8 @@ JackPort::post_process(ProcessContext& context)
jack_midi_clear_buffer(jack_buf);
LV2_Atom_Sequence* seq = (LV2_Atom_Sequence*)patch_buf->atom();
- LV2_SEQUENCE_FOREACH(seq, i) {
- LV2_Atom_Event* const ev = lv2_sequence_iter_get(i);
- const uint8_t* buf = (const uint8_t*)LV2_ATOM_BODY(&ev->body);
+ LV2_ATOM_SEQUENCE_FOREACH(seq, ev) {
+ const uint8_t* buf = (const uint8_t*)LV2_ATOM_BODY(&ev->body);
if (ev->body.type == _patch_port->bufs().uris().midi_MidiEvent) {
jack_midi_event_write(jack_buf, ev->time.frames, buf, ev->body.size);
}
diff --git a/src/server/ingen_lv2.cpp b/src/server/ingen_lv2.cpp
index 3129ee36..70a1482f 100644
--- a/src/server/ingen_lv2.cpp
+++ b/src/server/ingen_lv2.cpp
@@ -105,8 +105,7 @@ public:
patch_buf->copy((Sample*)_buffer, 0, context.nframes() - 1);
} else {
LV2_Atom_Sequence* seq = (LV2_Atom_Sequence*)_buffer;
- LV2_SEQUENCE_FOREACH(seq, i) {
- LV2_Atom_Event* ev = lv2_sequence_iter_get(i);
+ LV2_ATOM_SEQUENCE_FOREACH(seq, ev) {
// FIXME: Not RT safe, need to send these through a ring
handle_message(_driver, &ev->body);
}
diff --git a/src/server/internals/Controller.cpp b/src/server/internals/Controller.cpp
index 607d4d1e..6abdaf64 100644
--- a/src/server/internals/Controller.cpp
+++ b/src/server/internals/Controller.cpp
@@ -95,9 +95,8 @@ ControllerNode::process(ProcessContext& context)
Buffer* const midi_in = _midi_in_port->buffer(0).get();
LV2_Atom_Sequence* seq = (LV2_Atom_Sequence*)midi_in->atom();
- LV2_SEQUENCE_FOREACH(seq, i) {
- LV2_Atom_Event* const ev = lv2_sequence_iter_get(i);
- const uint8_t* buf = (const uint8_t*)LV2_ATOM_BODY(&ev->body);
+ LV2_ATOM_SEQUENCE_FOREACH(seq, ev) {
+ const uint8_t* buf = (const uint8_t*)LV2_ATOM_BODY(&ev->body);
if (ev->body.type == _midi_in_port->bufs().uris().midi_MidiEvent &&
ev->body.size >= 3 && (buf[0] & 0xF0) == MIDI_CMD_CONTROL) {
control(context, buf[1], buf[2], ev->time.frames + context.start());
diff --git a/src/server/internals/Note.cpp b/src/server/internals/Note.cpp
index 0608972f..c770177f 100644
--- a/src/server/internals/Note.cpp
+++ b/src/server/internals/Note.cpp
@@ -138,11 +138,9 @@ NoteNode::process(ProcessContext& context)
Buffer* const midi_in = _midi_in_port->buffer(0).get();
LV2_Atom_Sequence* seq = (LV2_Atom_Sequence*)midi_in->atom();
- LV2_SEQUENCE_FOREACH(seq, i) {
- LV2_Atom_Event* const ev = lv2_sequence_iter_get(i);
- const uint8_t* buf = (const uint8_t*)LV2_ATOM_BODY(&ev->body);
- const FrameTime time = context.start() + (FrameTime)ev->time.frames;
-
+ LV2_ATOM_SEQUENCE_FOREACH(seq, ev) {
+ const uint8_t* buf = (const uint8_t*)LV2_ATOM_BODY(&ev->body);
+ const FrameTime time = context.start() + (FrameTime)ev->time.frames;
if (ev->body.type == _midi_in_port->bufs().uris().midi_MidiEvent &&
ev->body.size >= 3) {
switch (buf[0] & 0xF0) {
diff --git a/src/server/internals/Trigger.cpp b/src/server/internals/Trigger.cpp
index 09766f15..15921ae9 100644
--- a/src/server/internals/Trigger.cpp
+++ b/src/server/internals/Trigger.cpp
@@ -97,9 +97,8 @@ TriggerNode::process(ProcessContext& context)
Buffer* const midi_in = _midi_in_port->buffer(0).get();
LV2_Atom_Sequence* seq = (LV2_Atom_Sequence*)midi_in->atom();
- LV2_SEQUENCE_FOREACH(seq, i) {
- LV2_Atom_Event* const ev = lv2_sequence_iter_get(i);
- const uint8_t* buf = (const uint8_t*)LV2_ATOM_BODY(&ev->body);
+ LV2_ATOM_SEQUENCE_FOREACH(seq, ev) {
+ const uint8_t* buf = (const uint8_t*)LV2_ATOM_BODY(&ev->body);
if (ev->body.type == _midi_in_port->bufs().uris().midi_MidiEvent &&
ev->body.size >= 3) {
const FrameTime time = context.start() + ev->time.frames;
diff --git a/src/shared/AtomReader.cpp b/src/shared/AtomReader.cpp
index 9bb614cb..f7c5d7e4 100644
--- a/src/shared/AtomReader.cpp
+++ b/src/shared/AtomReader.cpp
@@ -42,7 +42,7 @@ AtomReader::write(const LV2_Atom* msg)
const LV2_Atom_Object* obj = (const LV2_Atom_Object*)msg;
const LV2_Atom* subject = NULL;
- lv2_object_get(obj, (LV2_URID)_uris.patch_subject, &subject, NULL);
+ lv2_atom_object_get(obj, (LV2_URID)_uris.patch_subject, &subject, NULL);
const char* subject_uri = NULL;
if (subject && subject->type == _uris.atom_URI) {
subject_uri = (const char*)LV2_ATOM_BODY(subject);
@@ -55,15 +55,14 @@ AtomReader::write(const LV2_Atom* msg)
_iface.get(subject_uri);
} else if (obj->body.otype == _uris.patch_Put) {
const LV2_Atom_Object* body = NULL;
- lv2_object_get(obj, (LV2_URID)_uris.patch_body, &body, 0);
+ lv2_atom_object_get(obj, (LV2_URID)_uris.patch_body, &body, 0);
if (!body) {
Raul::warn << "Put message has no body" << std::endl;
return;
}
Ingen::Resource::Properties props;
- LV2_OBJECT_FOREACH(body, i) {
- LV2_Atom_Property_Body* p = lv2_object_iter_get(i);
+ LV2_ATOM_OBJECT_FOREACH(body, p) {
Raul::Atom val;
if (p->value.type == _uris.atom_URID) {
const LV2_Atom_URID* urid = (const LV2_Atom_URID*)&p->value;