From 87597f85c5a69a9accd3ce2ed88f2a006173e885 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Wed, 3 Feb 2010 04:46:56 +0000 Subject: Comprehensive use of cached URIs and more advanced Value (Atom) system. Atoms (e.g. property values or port values) can now be an Atom::DICT, which maps directly to/from an RDF resource. This is now used to store control bindings as a port property, eliminating the special API. Full interned URIs used everywhere, instead of CURIEs pretending to be URIs. Avoid converting string literals to URIs all over the place. Support for binding MIDI pitch bender and MIDI channel pressure. Saving/restoring of MIDI bindings as a free side-effect of the above. git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@2409 a436a847-0d15-0410-975c-d299462d15a1 --- src/client/NodeModel.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/client/NodeModel.cpp') diff --git a/src/client/NodeModel.cpp b/src/client/NodeModel.cpp index df72c9e2..bed43e7a 100644 --- a/src/client/NodeModel.cpp +++ b/src/client/NodeModel.cpp @@ -19,6 +19,8 @@ #include #include "ingen-config.h" #include "interface/Port.hpp" +#include "module/World.hpp" +#include "shared/LV2URIMap.hpp" #include "NodeModel.hpp" using namespace std; @@ -204,13 +206,14 @@ NodeModel::default_port_value_range(SharedPtr port, float& min, float void NodeModel::port_value_range(SharedPtr port, float& min, float& max) const { + const Shared::LV2URIMap& uris = Shared::LV2URIMap::instance(); assert(port->parent().get() == this); default_port_value_range(port, min, max); // Possibly overriden - const Atom& min_atom = port->get_property("lv2:minimum"); - const Atom& max_atom = port->get_property("lv2:maximum"); + const Atom& min_atom = port->get_property(uris.lv2_minimum); + const Atom& max_atom = port->get_property(uris.lv2_maximum); if (min_atom.type() == Atom::FLOAT) min = min_atom.get_float(); if (max_atom.type() == Atom::FLOAT) -- cgit v1.2.1