summaryrefslogtreecommitdiffstats
path: root/src/libs/engine
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2007-10-07 23:34:14 +0000
committerDavid Robillard <d@drobilla.net>2007-10-07 23:34:14 +0000
commit19a9eb15d1c918b10fe169db1b8f4fd0c6ffe8fa (patch)
treeebe897479e882241343196b6b33cf309917e7ae9 /src/libs/engine
parent971c02f3707c4872a2da9a3b946b6508290c5ab4 (diff)
downloadingen-19a9eb15d1c918b10fe169db1b8f4fd0c6ffe8fa.tar.gz
ingen-19a9eb15d1c918b10fe169db1b8f4fd0c6ffe8fa.tar.bz2
ingen-19a9eb15d1c918b10fe169db1b8f4fd0c6ffe8fa.zip
Move DataType into Shared namespace.
git-svn-id: http://svn.drobilla.net/lad/ingen@841 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/libs/engine')
-rw-r--r--src/libs/engine/Buffer.hpp10
-rw-r--r--src/libs/engine/BufferFactory.cpp6
2 files changed, 8 insertions, 8 deletions
diff --git a/src/libs/engine/Buffer.hpp b/src/libs/engine/Buffer.hpp
index cb8f09d4..d18270f5 100644
--- a/src/libs/engine/Buffer.hpp
+++ b/src/libs/engine/Buffer.hpp
@@ -31,7 +31,7 @@ namespace Ingen {
class Buffer : public boost::noncopyable, public Raul::Deletable
{
public:
- Buffer(DataType type, size_t size)
+ Buffer(Shared::DataType type, size_t size)
: _type(type)
, _size(size)
{}
@@ -55,12 +55,12 @@ public:
virtual void resize(size_t size) { _size = size; }
- DataType type() const { return _type; }
- size_t size() const { return _size; }
+ Shared::DataType type() const { return _type; }
+ size_t size() const { return _size; }
protected:
- DataType _type;
- size_t _size;
+ Shared::DataType _type;
+ size_t _size;
};
diff --git a/src/libs/engine/BufferFactory.cpp b/src/libs/engine/BufferFactory.cpp
index 882e1805..84ff721b 100644
--- a/src/libs/engine/BufferFactory.cpp
+++ b/src/libs/engine/BufferFactory.cpp
@@ -27,11 +27,11 @@ namespace BufferFactory {
Buffer*
create(DataType type, size_t size)
{
- if (type == DataType::CONTROL || type == DataType::AUDIO)
+ if (type.is_control() || type.is_audio())
return new AudioBuffer(size);
- else if (type == DataType::MIDI)
+ else if (type.is_midi())
return new MidiBuffer(size);
- else if (type == DataType::OSC)
+ else if (type.is_osc())
return new OSCBuffer(size);
else
return NULL;