summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Glöckner <cgloeckner@freenet.de>2016-03-29 10:02:10 +0200
committerAndré Nusser <andre.nusser@googlemail.com>2016-03-31 17:35:47 +0200
commit53909b3a74e9c752d3405fda7bc63146b9abdc7a (patch)
tree9f95c3666b5209021cb4d5a076693e1290a56be6
parent9a61e61db6d811c32a25beec8c34e790170662e0 (diff)
pass channels to output engine by const ref
-rw-r--r--drumgizmo/output/alsa.cc2
-rw-r--r--drumgizmo/output/alsa.h2
-rw-r--r--drumgizmo/output/jackaudio.cc2
-rw-r--r--drumgizmo/output/jackaudio.h2
-rw-r--r--drumgizmo/output/outputdummy.cc2
-rw-r--r--drumgizmo/output/outputdummy.h2
-rw-r--r--drumgizmo/output/wavfile.cc2
-rw-r--r--drumgizmo/output/wavfile.h2
-rw-r--r--plugin/drumgizmo_plugin.cc2
-rw-r--r--plugin/drumgizmo_plugin.h2
-rw-r--r--src/audiooutputengine.h2
11 files changed, 11 insertions, 11 deletions
diff --git a/drumgizmo/output/alsa.cc b/drumgizmo/output/alsa.cc
index 3686656..66a78c0 100644
--- a/drumgizmo/output/alsa.cc
+++ b/drumgizmo/output/alsa.cc
@@ -71,7 +71,7 @@ AlsaOutputEngine::~AlsaOutputEngine()
}
}
-bool AlsaOutputEngine::init(Channels channels)
+bool AlsaOutputEngine::init(const Channels& channels)
{
// try to initialize alsa
try
diff --git a/drumgizmo/output/alsa.h b/drumgizmo/output/alsa.h
index 4973f0b..a769c54 100644
--- a/drumgizmo/output/alsa.h
+++ b/drumgizmo/output/alsa.h
@@ -42,7 +42,7 @@ public:
~AlsaOutputEngine();
// based on AudioOutputEngine
- bool init(Channels chan) override;
+ bool init(const Channels& chan) override;
void setParm(const std::string& parm, const std::string& value) override;
bool start() override;
void stop() override;
diff --git a/drumgizmo/output/jackaudio.cc b/drumgizmo/output/jackaudio.cc
index 9f68edd..52e1d41 100644
--- a/drumgizmo/output/jackaudio.cc
+++ b/drumgizmo/output/jackaudio.cc
@@ -43,7 +43,7 @@ JackAudioOutputEngine::~JackAudioOutputEngine()
client.remove(*this);
}
-bool JackAudioOutputEngine::init(Channels data)
+bool JackAudioOutputEngine::init(const Channels& data)
{
channels.clear();
channels.reserve(data.size());
diff --git a/drumgizmo/output/jackaudio.h b/drumgizmo/output/jackaudio.h
index 24348f6..b71ff8e 100644
--- a/drumgizmo/output/jackaudio.h
+++ b/drumgizmo/output/jackaudio.h
@@ -40,7 +40,7 @@ public:
~JackAudioOutputEngine();
// based on AudioOutputEngine
- bool init(Channels chan) override;
+ bool init(const Channels& chan) override;
void setParm(const std::string& parm, const std::string& value) override;
bool start() override;
void stop() override;
diff --git a/drumgizmo/output/outputdummy.cc b/drumgizmo/output/outputdummy.cc
index 5899ead..4ff0816 100644
--- a/drumgizmo/output/outputdummy.cc
+++ b/drumgizmo/output/outputdummy.cc
@@ -34,7 +34,7 @@ DummyOutputEngine::~DummyOutputEngine()
{
}
-bool DummyOutputEngine::init(Channels data)
+bool DummyOutputEngine::init(const Channels& data)
{
return true;
}
diff --git a/drumgizmo/output/outputdummy.h b/drumgizmo/output/outputdummy.h
index caa9e5f..5a1b2fa 100644
--- a/drumgizmo/output/outputdummy.h
+++ b/drumgizmo/output/outputdummy.h
@@ -35,7 +35,7 @@ public:
~DummyOutputEngine();
// based on AudioOutputEngine
- bool init(Channels chan) override;
+ bool init(const Channels& chan) override;
void setParm(const std::string& parm, const std::string& value) override;
bool start() override;
void stop() override;
diff --git a/drumgizmo/output/wavfile.cc b/drumgizmo/output/wavfile.cc
index e81fb2d..78f7899 100644
--- a/drumgizmo/output/wavfile.cc
+++ b/drumgizmo/output/wavfile.cc
@@ -50,7 +50,7 @@ WavfileOutputEngine::~WavfileOutputEngine()
}
}
-bool WavfileOutputEngine::init(Channels data)
+bool WavfileOutputEngine::init(const Channels& data)
{
channels.clear();
channels.resize(data.size()); // value-initialized with null
diff --git a/drumgizmo/output/wavfile.h b/drumgizmo/output/wavfile.h
index 331733b..a0019d3 100644
--- a/drumgizmo/output/wavfile.h
+++ b/drumgizmo/output/wavfile.h
@@ -40,7 +40,7 @@ public:
~WavfileOutputEngine();
// based on AudioOutputEngine
- bool init(Channels data) override;
+ bool init(const Channels& data) override;
void setParm(const std::string& parm, const std::string& value) override;
bool start() override;
void stop() override;
diff --git a/plugin/drumgizmo_plugin.cc b/plugin/drumgizmo_plugin.cc
index f1cebd3..b41879d 100644
--- a/plugin/drumgizmo_plugin.cc
+++ b/plugin/drumgizmo_plugin.cc
@@ -241,7 +241,7 @@ DrumGizmoPlugin::Output::Output(DrumGizmoPlugin& plugin)
{
}
-bool DrumGizmoPlugin::Output::init(Channels channels)
+bool DrumGizmoPlugin::Output::init(const Channels& channels)
{
return true;
}
diff --git a/plugin/drumgizmo_plugin.h b/plugin/drumgizmo_plugin.h
index 767060c..8cddef6 100644
--- a/plugin/drumgizmo_plugin.h
+++ b/plugin/drumgizmo_plugin.h
@@ -130,7 +130,7 @@ private:
public:
Output(DrumGizmoPlugin& plugin);
- bool init(Channels channels) override;
+ bool init(const Channels& channels) override;
void setParm(const std::string& parm, const std::string& value) override;
diff --git a/src/audiooutputengine.h b/src/audiooutputengine.h
index a99d273..530ca13 100644
--- a/src/audiooutputengine.h
+++ b/src/audiooutputengine.h
@@ -37,7 +37,7 @@ class AudioOutputEngine {
public:
virtual ~AudioOutputEngine() {}
- virtual bool init(Channels channels) = 0;
+ virtual bool init(const Channels& channels) = 0;
virtual void setParm(const std::string& parm, const std::string& value) = 0;