summaryrefslogtreecommitdiffstats
path: root/src/server/BlockImpl.hpp
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2015-08-12 04:46:29 +0000
committerDavid Robillard <d@drobilla.net>2015-08-12 04:46:29 +0000
commitdd79e76e41446833088482588456afed37231bff (patch)
treec0f3c5c2fc74b286d529df69ad2206e2fddd96f9 /src/server/BlockImpl.hpp
parent44af7b7b66e2083819103c760ab3bf4980469f86 (diff)
downloadingen-dd79e76e41446833088482588456afed37231bff.tar.gz
ingen-dd79e76e41446833088482588456afed37231bff.tar.bz2
ingen-dd79e76e41446833088482588456afed37231bff.zip
Server-side presets.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@5703 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/server/BlockImpl.hpp')
-rw-r--r--src/server/BlockImpl.hpp16
1 files changed, 10 insertions, 6 deletions
diff --git a/src/server/BlockImpl.hpp b/src/server/BlockImpl.hpp
index 44271cc3..2dcc4762 100644
--- a/src/server/BlockImpl.hpp
+++ b/src/server/BlockImpl.hpp
@@ -20,6 +20,7 @@
#include <list>
#include <boost/intrusive/slist.hpp>
+#include <boost/optional.hpp>
#include "lilv/lilv.h"
@@ -28,6 +29,7 @@
#include "BufferRef.hpp"
#include "Context.hpp"
#include "NodeImpl.hpp"
+#include "PluginImpl.hpp"
#include "PortType.hpp"
#include "types.hpp"
@@ -36,9 +38,6 @@ class Maid;
}
namespace Ingen {
-
-class Plugin;
-
namespace Server {
class Buffer;
@@ -106,6 +105,11 @@ public:
/** Restore `state`. */
virtual void apply_state(LilvState* state) {}
+ /** Save current state as preset. */
+ virtual boost::optional<Resource>
+ save_preset(const Raul::URI& bundle,
+ const Properties& props) { return boost::optional<Resource>(); }
+
/** Learn the next incoming MIDI event (for internals) */
virtual void learn() {}
@@ -152,14 +156,14 @@ public:
ProcessContext& context, Raul::Maid& maid, uint32_t poly);
/** Information about the Plugin this Block is an instance of.
- * Not the best name - not all blocks come from plugins (e.g. Graph)
+ * Not the best name - not all blocks come from plugins (ie Graph)
*/
- virtual PluginImpl* plugin_impl() const { return _plugin; }
+ virtual const Resource* plugin() const;
/** Information about the Plugin this Block is an instance of.
* Not the best name - not all blocks come from plugins (ie Graph)
*/
- virtual const Plugin* plugin() const;
+ virtual const PluginImpl* plugin_impl() const;
virtual void plugin(PluginImpl* pi) { _plugin = pi; }