aboutsummaryrefslogtreecommitdiffstats
path: root/src/pcm_utils.h
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-10-23 16:58:07 +0200
committerMax Kellermann <max@duempel.org>2008-10-23 16:58:07 +0200
commit0078837a9760b8b5a14c87af0cb44a107462db7b (patch)
treeaef6736cc2cfab4b5912480e93ba5deae5dd163e /src/pcm_utils.h
parent80603cf6f13960a771889f59634b312f8d389381 (diff)
downloadmpd-0078837a9760b8b5a14c87af0cb44a107462db7b.tar.gz
mpd-0078837a9760b8b5a14c87af0cb44a107462db7b.tar.xz
mpd-0078837a9760b8b5a14c87af0cb44a107462db7b.zip
pcm_dither: added generic 24 to 16 bit dithering
Copied and adapted code from the mp3 decoder plugin. This library now replaces the old and low-quality function pcm_convert_24_to_16().
Diffstat (limited to 'src/pcm_utils.h')
-rw-r--r--src/pcm_utils.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/pcm_utils.h b/src/pcm_utils.h
index 3fc15e8b7..835ba187f 100644
--- a/src/pcm_utils.h
+++ b/src/pcm_utils.h
@@ -20,6 +20,7 @@
#define PCM_UTILS_H
#include "../config.h"
+#include "pcm_dither.h"
#include <stdint.h>
#include <stddef.h>
@@ -40,6 +41,9 @@ struct pcm_convert_state {
uint32_t lastInSampleRate;
uint32_t lastOutSampleRate;
#endif
+
+ struct pcm_dither_24 dither;
+
/* Strict C99 doesn't allow empty structs */
int error;
};