summaryrefslogtreecommitdiffstats
path: root/src/osc
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2012-03-12 06:59:48 +0000
committerDavid Robillard <d@drobilla.net>2012-03-12 06:59:48 +0000
commit81e9fb3245bd461ebfee4cfa16d1792e48533f9e (patch)
treeeb1b30d79cba70dda9d832100dd7c14b08085b03 /src/osc
parente9d9569271ee962c09ab66c6babed1ca5655a6c6 (diff)
downloadingen-81e9fb3245bd461ebfee4cfa16d1792e48533f9e.tar.gz
ingen-81e9fb3245bd461ebfee4cfa16d1792e48533f9e.tar.bz2
ingen-81e9fb3245bd461ebfee4cfa16d1792e48533f9e.zip
Centralise atom creation in forge object.
Aside from being more greppable and making realtime violations more obvious, this is a step towards using LV2 atoms internally (which needs a factory since the type numbers are dynamic). git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@4054 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/osc')
-rw-r--r--src/osc/OSCEngineReceiver.cpp17
1 files changed, 10 insertions, 7 deletions
diff --git a/src/osc/OSCEngineReceiver.cpp b/src/osc/OSCEngineReceiver.cpp
index 0f9ab151..ad505b76 100644
--- a/src/osc/OSCEngineReceiver.cpp
+++ b/src/osc/OSCEngineReceiver.cpp
@@ -323,8 +323,9 @@ OSCEngineReceiver::_put_cb(const char* path, const char* types, lo_arg** argv, i
const char* ctx = &argv[2]->s;
Resource::Properties prop;
for (int i = 3; i < argc-1; i += 2)
- prop.insert(make_pair(&argv[i]->s,
- AtomLiblo::lo_arg_to_atom(types[i+1], argv[i+1])));
+ prop.insert(
+ make_pair(&argv[i]->s,
+ AtomLiblo::lo_arg_to_atom(_engine.world()->forge(), types[i+1], argv[i+1])));
_interface->put(obj_path, prop, Resource::uri_to_graph(ctx));
return 0;
}
@@ -342,16 +343,18 @@ OSCEngineReceiver::_delta_begin_cb(const char* path, const char* types, lo_arg**
int
OSCEngineReceiver::_delta_remove_cb(const char* path, const char* types, lo_arg** argv, int argc, lo_message msg)
{
- _delta_remove.insert(make_pair(&argv[1]->s,
- AtomLiblo::lo_arg_to_atom(types[2], argv[2])));
+ _delta_remove.insert(
+ make_pair(&argv[1]->s,
+ AtomLiblo::lo_arg_to_atom(_engine.world()->forge(), types[2], argv[2])));
return 0;
}
int
OSCEngineReceiver::_delta_add_cb(const char* path, const char* types, lo_arg** argv, int argc, lo_message msg)
{
- _delta_add.insert(make_pair(&argv[1]->s,
- AtomLiblo::lo_arg_to_atom(types[2], argv[2])));
+ _delta_add.insert(
+ make_pair(&argv[1]->s,
+ AtomLiblo::lo_arg_to_atom(_engine.world()->forge(), types[2], argv[2])));
return 0;
}
@@ -541,7 +544,7 @@ OSCEngineReceiver::_set_property_cb(const char* path, const char* types, lo_arg*
const char* object_path = &argv[1]->s;
const char* key = &argv[2]->s;
- Raul::Atom value = Raul::AtomLiblo::lo_arg_to_atom(types[3], argv[3]);
+ Raul::Atom value = Raul::AtomLiblo::lo_arg_to_atom(_engine.world()->forge(), types[3], argv[3]);
_interface->set_property(object_path, key, value);
return 0;