aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-10-23 16:57:58 +0200
committerMax Kellermann <max@duempel.org>2008-10-23 16:57:58 +0200
commit80603cf6f13960a771889f59634b312f8d389381 (patch)
tree786a0feda176099261fd274b998963a8431e0c2b /src
parent980f2ca56dbedb60aa3f880f66a97d151a107e62 (diff)
downloadmpd-80603cf6f13960a771889f59634b312f8d389381.tar.gz
mpd-80603cf6f13960a771889f59634b312f8d389381.tar.xz
mpd-80603cf6f13960a771889f59634b312f8d389381.zip
audio: allow 24 and 8 bit output
I added 24 bit support a while ago, but it wasn't possible to force 24 bit output. Add 24 and 8 bit to the list of allowed sample sizes. Although 8 bit audio isn't as widely used as 24 bit, there is no reason to exclude it.
Diffstat (limited to 'src')
-rw-r--r--src/audio.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/audio.c b/src/audio.c
index 7d8e49f77..ce8b06151 100644
--- a/src/audio.c
+++ b/src/audio.c
@@ -149,10 +149,8 @@ int parseAudioConfig(struct audio_format *audioFormat, char *conf)
return -1;
}
- switch (audioFormat->bits) {
- case 16:
- break;
- default:
+ if (audioFormat->bits != 16 && audioFormat->bits != 24 &&
+ audioFormat->bits != 8) {
ERROR("bits %u can not be used for audio output\n",
audioFormat->bits);
return -1;