summaryrefslogtreecommitdiffstats
path: root/src/libs/engine/PortImpl.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/libs/engine/PortImpl.cpp')
-rw-r--r--src/libs/engine/PortImpl.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/libs/engine/PortImpl.cpp b/src/libs/engine/PortImpl.cpp
index 7ef4a82a..800ba011 100644
--- a/src/libs/engine/PortImpl.cpp
+++ b/src/libs/engine/PortImpl.cpp
@@ -39,7 +39,7 @@ PortImpl::PortImpl(NodeImpl* const node,
uint32_t poly,
DataType type,
size_t buffer_size)
- : GraphObjectImpl(node, name, true)
+ : GraphObjectImpl(node, name, (type == DataType::AUDIO || type == DataType::CONTROL))
, _index(index)
, _poly(poly)
, _buffer_size(buffer_size)
@@ -73,6 +73,16 @@ PortImpl::~PortImpl()
delete _buffers;
}
+
+bool
+PortImpl::set_polyphonic(Raul::Maid& maid, bool p)
+{
+ if (_type == DataType::CONTROL || _type == DataType::AUDIO)
+ return GraphObjectImpl::set_polyphonic(maid, p);
+ else
+ return (!p);
+}
+
bool
PortImpl::prepare_poly(uint32_t poly)