aboutsummaryrefslogtreecommitdiffstats
path: root/src/output/Init.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'src/output/Init.cxx')
-rw-r--r--src/output/Init.cxx18
1 files changed, 11 insertions, 7 deletions
diff --git a/src/output/Init.cxx b/src/output/Init.cxx
index 79ef4f998..f9648e0d4 100644
--- a/src/output/Init.cxx
+++ b/src/output/Init.cxx
@@ -58,7 +58,7 @@ AudioOutput::AudioOutput(const AudioOutputPlugin &_plugin)
filter(nullptr),
replay_gain_filter(nullptr),
other_replay_gain_filter(nullptr),
- command(AO_COMMAND_NONE)
+ command(Command::NONE)
{
assert(plugin.finish != nullptr);
assert(plugin.open != nullptr);
@@ -94,7 +94,7 @@ audio_output_detect(Error &error)
* mixer_enabled, if the mixer_type setting is not configured.
*/
gcc_pure
-static enum mixer_type
+static MixerType
audio_output_mixer_type(const config_param &param)
{
/* read the local "mixer_type" setting */
@@ -104,7 +104,7 @@ audio_output_mixer_type(const config_param &param)
/* try the local "mixer_enabled" setting next (deprecated) */
if (!param.GetBlockValue("mixer_enabled", true))
- return MIXER_TYPE_NONE;
+ return MixerType::NONE;
/* fall back to the global "mixer_type" setting (also
deprecated) */
@@ -123,18 +123,22 @@ audio_output_load_mixer(EventLoop &event_loop, AudioOutput &ao,
Mixer *mixer;
switch (audio_output_mixer_type(param)) {
- case MIXER_TYPE_NONE:
- case MIXER_TYPE_UNKNOWN:
+ case MixerType::NONE:
+ case MixerType::UNKNOWN:
return nullptr;
- case MIXER_TYPE_HARDWARE:
+ case MixerType::NULL_:
+ return mixer_new(event_loop, null_mixer_plugin, ao, listener,
+ param, error);
+
+ case MixerType::HARDWARE:
if (plugin == nullptr)
return nullptr;
return mixer_new(event_loop, *plugin, ao, listener,
param, error);
- case MIXER_TYPE_SOFTWARE:
+ case MixerType::SOFTWARE:
mixer = mixer_new(event_loop, software_mixer_plugin, ao,
listener,
config_param(),