From e96c36c1a7abb062e36efc0ac95c35fedcef922e Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sun, 8 Apr 2007 06:04:32 +0000 Subject: De-template-ification of port types (req. for LV2 MIDI, but nice code size reduction). LV2 MIDI patching support (LV2 style MIDI throughout, inc. internal plugins). git-svn-id: http://svn.drobilla.net/lad/ingen@415 a436a847-0d15-0410-975c-d299462d15a1 --- src/libs/engine/Driver.h | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) (limited to 'src/libs/engine/Driver.h') diff --git a/src/libs/engine/Driver.h b/src/libs/engine/Driver.h index 6cbfbdff..fbddc828 100644 --- a/src/libs/engine/Driver.h +++ b/src/libs/engine/Driver.h @@ -21,10 +21,11 @@ #include #include #include "raul/Path.h" +#include "DataType.h" namespace Ingen { -template class DuplexPort; +class DuplexPort; /** Representation of a "system" (eg outside Ingen) port. @@ -58,15 +59,15 @@ protected: * interface for managing system ports. An implementation of Driver basically * needs to manage DriverPorts, and handle writing/reading data to/from them. * - * The template parameter T is the type of data this driver manages (ie the - * data type of the bridge ports it will handle). - * * \ingroup engine */ -template class Driver : boost::noncopyable { public: + Driver(DataType type) + : _type(type) + {} + virtual ~Driver() {} virtual void activate() = 0; @@ -78,10 +79,13 @@ public: * * May return NULL if the Driver can not drive the port for some reason. */ - virtual DriverPort* create_port(DuplexPort* patch_port) = 0; + virtual DriverPort* create_port(DuplexPort* patch_port) = 0; virtual void add_port(DriverPort* port) = 0; virtual DriverPort* remove_port(const Raul::Path& path) = 0; + +protected: + DataType _type; }; -- cgit v1.2.1