summaryrefslogtreecommitdiffstats
path: root/src/server
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2011-10-01 16:44:45 +0000
committerDavid Robillard <d@drobilla.net>2011-10-01 16:44:45 +0000
commit55c9839597021cb01b290b442ad0c9054b934520 (patch)
treeff0c73db270dc4896d87ad3d1ca49aa6441abb0f /src/server
parent625e1c0c58931caec50cdbe5be80312550be4991 (diff)
downloadingen-55c9839597021cb01b290b442ad0c9054b934520.tar.gz
ingen-55c9839597021cb01b290b442ad0c9054b934520.tar.bz2
ingen-55c9839597021cb01b290b442ad0c9054b934520.zip
Make PortImpl::get_buffers const.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@3520 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/server')
-rw-r--r--src/server/DuplexPort.cpp4
-rw-r--r--src/server/DuplexPort.hpp4
-rw-r--r--src/server/InputPort.cpp2
-rw-r--r--src/server/InputPort.hpp2
-rw-r--r--src/server/OutputPort.cpp4
-rw-r--r--src/server/OutputPort.hpp4
-rw-r--r--src/server/PortImpl.hpp2
7 files changed, 15 insertions, 7 deletions
diff --git a/src/server/DuplexPort.cpp b/src/server/DuplexPort.cpp
index 773aab37..e4b854a2 100644
--- a/src/server/DuplexPort.cpp
+++ b/src/server/DuplexPort.cpp
@@ -55,7 +55,9 @@ DuplexPort::DuplexPort(
}
bool
-DuplexPort::get_buffers(BufferFactory& bufs, Raul::Array<BufferFactory::Ref>* buffers, uint32_t poly)
+DuplexPort::get_buffers(BufferFactory& bufs,
+ Raul::Array<BufferFactory::Ref>* buffers,
+ uint32_t poly) const
{
if (_is_output)
return InputPort::get_buffers(bufs, buffers, poly);
diff --git a/src/server/DuplexPort.hpp b/src/server/DuplexPort.hpp
index ed00e072..aa174132 100644
--- a/src/server/DuplexPort.hpp
+++ b/src/server/DuplexPort.hpp
@@ -52,7 +52,9 @@ public:
virtual ~DuplexPort() {}
- bool get_buffers(BufferFactory& bufs, Raul::Array<BufferFactory::Ref>* buffers, uint32_t poly);
+ bool get_buffers(BufferFactory& bufs,
+ Raul::Array<BufferFactory::Ref>* buffers,
+ uint32_t poly) const;
void pre_process(Context& context);
void post_process(Context& context);
diff --git a/src/server/InputPort.cpp b/src/server/InputPort.cpp
index b0866fde..01a5c414 100644
--- a/src/server/InputPort.cpp
+++ b/src/server/InputPort.cpp
@@ -78,7 +78,7 @@ InputPort::apply_poly(Maid& maid, uint32_t poly)
bool
InputPort::get_buffers(BufferFactory& bufs,
Raul::Array<BufferFactory::Ref>* buffers,
- uint32_t poly)
+ uint32_t poly) const
{
size_t num_connections = (ThreadManager::thread_is(THREAD_PROCESS))
? _connections.size() : _num_connections;
diff --git a/src/server/InputPort.hpp b/src/server/InputPort.hpp
index a5e81b6c..ec3a14ef 100644
--- a/src/server/InputPort.hpp
+++ b/src/server/InputPort.hpp
@@ -68,7 +68,7 @@ public:
bool get_buffers(BufferFactory& bufs,
Raul::Array<BufferFactory::Ref>* buffers,
- uint32_t poly);
+ uint32_t poly) const;
void pre_process(Context& context);
void post_process(Context& context);
diff --git a/src/server/OutputPort.cpp b/src/server/OutputPort.cpp
index c96c6b04..ca217b49 100644
--- a/src/server/OutputPort.cpp
+++ b/src/server/OutputPort.cpp
@@ -46,7 +46,9 @@ OutputPort::OutputPort(BufferFactory& bufs,
}
bool
-OutputPort::get_buffers(BufferFactory& bufs, Raul::Array<BufferFactory::Ref>* buffers, uint32_t poly)
+OutputPort::get_buffers(BufferFactory& bufs,
+ Raul::Array<BufferFactory::Ref>* buffers,
+ uint32_t poly) const
{
for (uint32_t v = 0; v < poly; ++v)
buffers->at(v) = bufs.get(buffer_type(), _buffer_size);
diff --git a/src/server/OutputPort.hpp b/src/server/OutputPort.hpp
index f16a5ff7..a076209b 100644
--- a/src/server/OutputPort.hpp
+++ b/src/server/OutputPort.hpp
@@ -48,7 +48,9 @@ public:
const Raul::Atom& value,
size_t buffer_size=0);
- bool get_buffers(BufferFactory& bufs, Raul::Array<BufferFactory::Ref>* buffers, uint32_t poly);
+ bool get_buffers(BufferFactory& bufs,
+ Raul::Array<BufferFactory::Ref>* buffers,
+ uint32_t poly) const;
void pre_process(Context& context);
void post_process(Context& context);
diff --git a/src/server/PortImpl.hpp b/src/server/PortImpl.hpp
index b00504f8..caf291f0 100644
--- a/src/server/PortImpl.hpp
+++ b/src/server/PortImpl.hpp
@@ -109,7 +109,7 @@ public:
virtual bool get_buffers(BufferFactory& bufs,
Raul::Array<BufferFactory::Ref>* buffers,
- uint32_t poly) = 0;
+ uint32_t poly) const = 0;
void setup_buffers(BufferFactory& bufs, uint32_t poly) {
get_buffers(bufs, _buffers, poly);