summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/pcm/PcmConvert.cxx20
-rw-r--r--src/pcm/PcmConvert.hxx2
2 files changed, 11 insertions, 11 deletions
diff --git a/src/pcm/PcmConvert.cxx b/src/pcm/PcmConvert.cxx
index 6e57cf541..d78b3c1e8 100644
--- a/src/pcm/PcmConvert.cxx
+++ b/src/pcm/PcmConvert.cxx
@@ -30,8 +30,8 @@ pcm_convert_global_init(const ConfigData &config)
}
PcmConvert::PcmConvert(const AudioFormat _src_format,
- const AudioFormat _dest_format)
- :src_format(_src_format), dest_format(_dest_format)
+ const AudioFormat dest_format)
+ :src_format(_src_format)
{
assert(src_format.IsValid());
assert(dest_format.IsValid());
@@ -40,19 +40,19 @@ PcmConvert::PcmConvert(const AudioFormat _src_format,
if (format.format == SampleFormat::DSD)
format.format = SampleFormat::FLOAT;
- enable_resampler = format.sample_rate != _dest_format.sample_rate;
+ enable_resampler = format.sample_rate != dest_format.sample_rate;
if (enable_resampler) {
- resampler.Open(format, _dest_format.sample_rate);
+ resampler.Open(format, dest_format.sample_rate);
format.format = resampler.GetOutputSampleFormat();
- format.sample_rate = _dest_format.sample_rate;
+ format.sample_rate = dest_format.sample_rate;
}
- enable_format = format.format != _dest_format.format;
+ enable_format = format.format != dest_format.format;
if (enable_format) {
try {
format_converter.Open(format.format,
- _dest_format.format);
+ dest_format.format);
} catch (...) {
if (enable_resampler)
resampler.Close();
@@ -60,13 +60,13 @@ PcmConvert::PcmConvert(const AudioFormat _src_format,
}
}
- format.format = _dest_format.format;
+ format.format = dest_format.format;
- enable_channels = format.channels != _dest_format.channels;
+ enable_channels = format.channels != dest_format.channels;
if (enable_channels) {
try {
channels_converter.Open(format.format, format.channels,
- _dest_format.channels);
+ dest_format.channels);
} catch (...) {
if (enable_format)
format_converter.Close();
diff --git a/src/pcm/PcmConvert.hxx b/src/pcm/PcmConvert.hxx
index e90accd97..7595db138 100644
--- a/src/pcm/PcmConvert.hxx
+++ b/src/pcm/PcmConvert.hxx
@@ -47,7 +47,7 @@ class PcmConvert {
PcmFormatConverter format_converter;
PcmChannelsConverter channels_converter;
- const AudioFormat src_format, dest_format;
+ const AudioFormat src_format;
bool enable_resampler, enable_format, enable_channels;