diff options
author | Max Kellermann <max@duempel.org> | 2014-03-14 20:08:12 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2014-03-14 20:53:22 +0100 |
commit | 044134eba0854aef1b7015c1b67f3b854d90ca2b (patch) | |
tree | eb193a6b2ac57b0be7f27b3b35fb6d30cfc65d0b | |
parent | 9fa6fa522e5642df8898574636ef10c8cf0349e3 (diff) | |
download | mpd-044134eba0854aef1b7015c1b67f3b854d90ca2b.tar.gz mpd-044134eba0854aef1b7015c1b67f3b854d90ca2b.tar.xz mpd-044134eba0854aef1b7015c1b67f3b854d90ca2b.zip |
pcm/PcmFormat: eliminate local variable "bits"
-rw-r--r-- | src/pcm/PcmFormat.cxx | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/pcm/PcmFormat.cxx b/src/pcm/PcmFormat.cxx index bbd3eb6f5..96f515f84 100644 --- a/src/pcm/PcmFormat.cxx +++ b/src/pcm/PcmFormat.cxx @@ -60,9 +60,7 @@ static void ConvertFromFloat(typename Traits::pointer_type dest, const float *src, size_t n) { - constexpr auto bits = Traits::BITS; - - const float factor = 1 << (bits - 1); + const float factor = 1 << (Traits::BITS - 1); for (size_t i = 0; i != n; ++i) { typename Traits::long_type sample(src[i] * factor); |