summaryrefslogtreecommitdiff
path: root/libs/ardour/ardour/chan_count.h
diff options
context:
space:
mode:
Diffstat (limited to 'libs/ardour/ardour/chan_count.h')
-rw-r--r--libs/ardour/ardour/chan_count.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/libs/ardour/ardour/chan_count.h b/libs/ardour/ardour/chan_count.h
index b613f67a3c..fc76734817 100644
--- a/libs/ardour/ardour/chan_count.h
+++ b/libs/ardour/ardour/chan_count.h
@@ -120,6 +120,14 @@ public:
return ret;
}
+ ChanCount operator*(const unsigned int factor) const {
+ ChanCount ret;
+ for (DataType::iterator t = DataType::begin(); t != DataType::end(); ++t) {
+ ret.set(*t, get(*t) * factor );
+ }
+ return ret;
+ }
+
ChanCount& operator+=(const ChanCount& other) {
for (DataType::iterator t = DataType::begin(); t != DataType::end(); ++t) {
_counts[*t] += other._counts[*t];