aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-12-24 23:38:11 +0100
committerMax Kellermann <max@duempel.org>2013-12-24 23:38:11 +0100
commitd1b7473418b413d28aee091ec79b11334f2abd5b (patch)
tree25c465598fefb74b306f5cc8026ce56dd7f9fe7c /src
parent1ad52f131c7adf3396ea03d8da0da807da222bba (diff)
downloadmpd-d1b7473418b413d28aee091ec79b11334f2abd5b.tar.gz
mpd-d1b7473418b413d28aee091ec79b11334f2abd5b.tar.xz
mpd-d1b7473418b413d28aee091ec79b11334f2abd5b.zip
pcm/Dither: rename DitherShift() to DitherConvert()
Diffstat (limited to 'src')
-rw-r--r--src/pcm/PcmDither.cxx14
-rw-r--r--src/pcm/PcmDither.hxx8
2 files changed, 11 insertions, 11 deletions
diff --git a/src/pcm/PcmDither.cxx b/src/pcm/PcmDither.cxx
index 71ec5db1e..62214ce28 100644
--- a/src/pcm/PcmDither.cxx
+++ b/src/pcm/PcmDither.cxx
@@ -64,7 +64,7 @@ PcmDither::Dither(T sample)
template<typename ST, typename DT>
inline typename DT::value_type
-PcmDither::DitherShift(typename ST::value_type sample)
+PcmDither::DitherConvert(typename ST::value_type sample)
{
static_assert(ST::BITS > DT::BITS,
"Sample formats cannot be dithered");
@@ -77,12 +77,12 @@ PcmDither::DitherShift(typename ST::value_type sample)
template<typename ST, typename DT>
inline void
-PcmDither::DitherShift(typename DT::pointer_type dest,
- typename ST::const_pointer_type src,
- typename ST::const_pointer_type src_end)
+PcmDither::DitherConvert(typename DT::pointer_type dest,
+ typename ST::const_pointer_type src,
+ typename ST::const_pointer_type src_end)
{
while (src < src_end)
- *dest++ = DitherShift<ST, DT>(*src++);
+ *dest++ = DitherConvert<ST, DT>(*src++);
}
void
@@ -91,7 +91,7 @@ PcmDither::Dither24To16(int16_t *dest, const int32_t *src,
{
typedef SampleTraits<SampleFormat::S24_P32> ST;
typedef SampleTraits<SampleFormat::S16> DT;
- DitherShift<ST, DT>(dest, src, src_end);
+ DitherConvert<ST, DT>(dest, src, src_end);
}
void
@@ -100,5 +100,5 @@ PcmDither::Dither32To16(int16_t *dest, const int32_t *src,
{
typedef SampleTraits<SampleFormat::S32> ST;
typedef SampleTraits<SampleFormat::S16> DT;
- DitherShift<ST, DT>(dest, src, src_end);
+ DitherConvert<ST, DT>(dest, src, src_end);
}
diff --git a/src/pcm/PcmDither.hxx b/src/pcm/PcmDither.hxx
index 2b75cdaeb..0d81b8794 100644
--- a/src/pcm/PcmDither.hxx
+++ b/src/pcm/PcmDither.hxx
@@ -43,12 +43,12 @@ private:
T Dither(T sample);
template<typename ST, typename DT>
- typename DT::value_type DitherShift(typename ST::value_type sample);
+ typename DT::value_type DitherConvert(typename ST::value_type sample);
template<typename ST, typename DT>
- void DitherShift(typename DT::pointer_type dest,
- typename ST::const_pointer_type src,
- typename ST::const_pointer_type src_end);
+ void DitherConvert(typename DT::pointer_type dest,
+ typename ST::const_pointer_type src,
+ typename ST::const_pointer_type src_end);
};
#endif