diff options
author | David Robillard <d@drobilla.net> | 2010-10-27 01:37:53 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2010-10-27 01:37:53 +0000 |
commit | 62940482c29913124fc8f499994a345f76af17b5 (patch) | |
tree | ee161b9abbed09fe174a68b2bc999b7836dfbf87 | |
parent | 5177aa485f28e40e087042c2b7292fb9a94e7a3c (diff) | |
download | ingen-62940482c29913124fc8f499994a345f76af17b5.tar.gz ingen-62940482c29913124fc8f499994a345f76af17b5.tar.bz2 ingen-62940482c29913124fc8f499994a345f76af17b5.zip |
Update for new Atom extension.
Add RDF read (parse) and RDF write (serialise) plugins.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@2649 a436a847-0d15-0410-975c-d299462d15a1
-rw-r--r-- | src/client/PortModel.cpp | 2 | ||||
-rw-r--r-- | src/common/interface/PortType.hpp | 4 | ||||
-rw-r--r-- | src/engine/LV2BlobFeature.hpp | 26 | ||||
-rw-r--r-- | src/engine/LV2Info.cpp | 4 | ||||
-rw-r--r-- | src/engine/LV2Node.cpp | 6 | ||||
-rw-r--r-- | src/engine/PortImpl.cpp | 2 | ||||
-rw-r--r-- | src/module/World.cpp | 1 | ||||
-rw-r--r-- | src/shared/LV2URIMap.cpp | 6 | ||||
-rw-r--r-- | src/shared/LV2URIMap.hpp | 6 | ||||
-rw-r--r-- | src/shared/ResourceImpl.cpp | 4 |
10 files changed, 30 insertions, 31 deletions
diff --git a/src/client/PortModel.cpp b/src/client/PortModel.cpp index c473772e..6f21351b 100644 --- a/src/client/PortModel.cpp +++ b/src/client/PortModel.cpp @@ -38,7 +38,7 @@ PortModel::set_property(const Raul::URI& uri, bool PortModel::supports(const Raul::URI& value_type) const { - return has_property(_uris.aport_supports, value_type); + return has_property(_uris.atom_supports, value_type); } diff --git a/src/common/interface/PortType.hpp b/src/common/interface/PortType.hpp index 192ea458..fa28bfa4 100644 --- a/src/common/interface/PortType.hpp +++ b/src/common/interface/PortType.hpp @@ -84,8 +84,8 @@ private: "http://lv2plug.in/ns/lv2core#AudioPort", "http://lv2plug.in/ns/lv2core#ControlPort", "http://lv2plug.in/ns/ext/event#EventPort", - "http://lv2plug.in/ns/ext/atom-port#ValuePort", - "http://lv2plug.in/ns/ext/atom-port#MessagePort" + "http://lv2plug.in/ns/ext/atom#ValuePort", + "http://lv2plug.in/ns/ext/atom#MessagePort" }; return uris[symbol_num]; } diff --git a/src/engine/LV2BlobFeature.hpp b/src/engine/LV2BlobFeature.hpp index b071a067..8d2977c1 100644 --- a/src/engine/LV2BlobFeature.hpp +++ b/src/engine/LV2BlobFeature.hpp @@ -26,30 +26,30 @@ struct BlobFeature : public Shared::LV2Features::Feature { BlobFeature() { LV2_Blob_Support* data = (LV2_Blob_Support*)malloc(sizeof(LV2_Blob_Support)); data->data = NULL; - data->ref_size = sizeof(LV2_Blob*); - data->blob_new = &blob_new; + data->ref_size = sizeof(LV2_Blob); data->ref_get = &ref_get; data->ref_copy = &ref_copy; data->ref_reset = &ref_reset; + data->blob_new = &blob_new; _feature.URI = LV2_BLOB_SUPPORT_URI; _feature.data = data; } - static void blob_new(LV2_Blob_Support_Data data, - LV2_Atom* reference, - LV2_Blob_Destroy destroy, - uint32_t type, - size_t size) {} - - static LV2_Blob* ref_get(LV2_Blob_Support_Data data, - LV2_Atom* ref) { return 0; } + static LV2_Blob ref_get(LV2_Blob_Support_Data data, + LV2_Atom_Reference* ref) { return 0; } static void ref_copy(LV2_Blob_Support_Data data, - LV2_Atom* dst, - LV2_Atom* src) {} + LV2_Atom_Reference* dst, + LV2_Atom_Reference* src) {} static void ref_reset(LV2_Blob_Support_Data data, - LV2_Atom* ref) {} + LV2_Atom_Reference* ref) {} + + static void blob_new(LV2_Blob_Support_Data data, + LV2_Atom_Reference* reference, + LV2_Blob_Destroy destroy, + uint32_t type, + size_t size) {} SharedPtr<LV2_Feature> feature(Shared::Node*) { return SharedPtr<LV2_Feature>(&_feature, NullDeleter<LV2_Feature>); diff --git a/src/engine/LV2Info.cpp b/src/engine/LV2Info.cpp index c96d5874..fcd303ef 100644 --- a/src/engine/LV2Info.cpp +++ b/src/engine/LV2Info.cpp @@ -37,9 +37,9 @@ LV2Info::LV2Info(Ingen::Shared::World* world) , audio_class(slv2_value_new_uri(world->slv2_world(), SLV2_PORT_CLASS_AUDIO)) , event_class(slv2_value_new_uri(world->slv2_world(), SLV2_PORT_CLASS_EVENT)) , value_port_class(slv2_value_new_uri(world->slv2_world(), - "http://lv2plug.in/ns/ext/atom-port#ValuePort")) + "http://lv2plug.in/ns/ext/atom#ValuePort")) , message_port_class(slv2_value_new_uri(world->slv2_world(), - "http://lv2plug.in/ns/ext/atom-port#MessagePort")) + "http://lv2plug.in/ns/ext/atom#MessagePort")) , _world(world) { assert(world); diff --git a/src/engine/LV2Node.cpp b/src/engine/LV2Node.cpp index e6593d13..8291adf2 100644 --- a/src/engine/LV2Node.cpp +++ b/src/engine/LV2Node.cpp @@ -203,7 +203,7 @@ LV2Node::instantiate(BufferFactory& bufs) "http://lv2plug.in/ns/lv2core#portProperty"); SLV2Value supports_pred = slv2_value_new_uri(info->lv2_world(), - "http://lv2plug.in/ns/ext/atom-port#supports"); + "http://lv2plug.in/ns/ext/atom#supports"); //SLV2Value as_large_as_pred = slv2_value_new_uri(info->lv2_world(), // "http://lv2plug.in/ns/ext/resize-port#asLargeAs"); @@ -307,12 +307,12 @@ LV2Node::instantiate(BufferFactory& bufs) } } - // Set aport:supports properties + // Set atom:supports properties SLV2Values types = slv2_port_get_value(plug, id, supports_pred); for (uint32_t i = 0; i < slv2_values_size(types); ++i) { SLV2Value type = slv2_values_get_at(types, i); if (slv2_value_is_uri(type)) { - port->add_property(uris.aport_supports, Raul::URI(slv2_value_as_uri(type))); + port->add_property(uris.atom_supports, Raul::URI(slv2_value_as_uri(type))); } } diff --git a/src/engine/PortImpl.cpp b/src/engine/PortImpl.cpp index 60d2ea26..67699bd7 100644 --- a/src/engine/PortImpl.cpp +++ b/src/engine/PortImpl.cpp @@ -88,7 +88,7 @@ PortImpl::~PortImpl() bool PortImpl::supports(const Raul::URI& value_type) const { - return has_property(_bufs.uris().aport_supports, value_type); + return has_property(_bufs.uris().atom_supports, value_type); } diff --git a/src/module/World.cpp b/src/module/World.cpp index 5b21e9ec..204cbdfa 100644 --- a/src/module/World.cpp +++ b/src/module/World.cpp @@ -129,7 +129,6 @@ struct WorldImpl : public boost::noncopyable { rdf_world->add_prefix("rdfs", "http://www.w3.org/2000/01/rdf-schema#"); rdf_world->add_prefix("xsd", "http://www.w3.org/2001/XMLSchema#"); rdf_world->add_prefix("atom", "http://lv2plug.in/ns/ext/atom#"); - rdf_world->add_prefix("aport", "http://lv2plug.in/ns/ext/atom-port#"); rdf_world->add_prefix("xsd", "http://www.w3.org/2001/XMLSchema#"); } diff --git a/src/shared/LV2URIMap.cpp b/src/shared/LV2URIMap.cpp index 623ad69d..d1e72844 100644 --- a/src/shared/LV2URIMap.cpp +++ b/src/shared/LV2URIMap.cpp @@ -96,9 +96,9 @@ LV2URIMap::LV2URIMap() , midi_controllerNumber(NS_MIDI "controllerNumber") , midi_event("http://lv2plug.in/ns/ext/midi#MidiEvent") , midi_noteNumber(NS_MIDI "noteNumber") - , aport_MessagePort("http://lv2plug.in/ns/ext/atom-port#MessagePort") - , aport_ValuePort("http://lv2plug.in/ns/ext/atom-port#ValuePort") - , aport_supports("http://lv2plug.in/ns/ext/atom-port#supports") + , atom_MessagePort("http://lv2plug.in/ns/ext/atom#MessagePort") + , atom_ValuePort("http://lv2plug.in/ns/ext/atom#ValuePort") + , atom_supports("http://lv2plug.in/ns/ext/atom#supports") , object_class_bool(LV2_ATOM_URI "#Bool") , object_class_float32(LV2_ATOM_URI "#Float32") , object_class_int32(LV2_ATOM_URI "#Int32") diff --git a/src/shared/LV2URIMap.hpp b/src/shared/LV2URIMap.hpp index d34be8f9..15ef4283 100644 --- a/src/shared/LV2URIMap.hpp +++ b/src/shared/LV2URIMap.hpp @@ -121,9 +121,9 @@ public: const Quark midi_controllerNumber; const Quark midi_event; const Quark midi_noteNumber; - const Quark aport_MessagePort; - const Quark aport_ValuePort; - const Quark aport_supports; + const Quark atom_MessagePort; + const Quark atom_ValuePort; + const Quark atom_supports; const Quark object_class_bool; const Quark object_class_float32; const Quark object_class_int32; diff --git a/src/shared/ResourceImpl.cpp b/src/shared/ResourceImpl.cpp index af706e15..5d79ed9b 100644 --- a/src/shared/ResourceImpl.cpp +++ b/src/shared/ResourceImpl.cpp @@ -149,10 +149,10 @@ ResourceImpl::type( } else if (atom == uris.lv2ev_EventPort) { data_type = PortType::EVENTS; port = true; - } else if (atom == uris.aport_ValuePort) { + } else if (atom == uris.atom_ValuePort) { data_type = PortType::VALUE; port = true; - } else if (atom == uris.aport_MessagePort) { + } else if (atom == uris.atom_MessagePort) { data_type = PortType::MESSAGE; port = true; } else { |