diff options
author | Andreas Claesson <andreas.claesson@gmail.com> | 2005-05-24 15:55:08 +0000 |
---|---|---|
committer | Andreas Claesson <andreas.claesson@gmail.com> | 2005-05-24 15:55:08 +0000 |
commit | 505424285045f8b43c8b806c1cbd6e8e4431de7f (patch) | |
tree | 02b9c3348eab31b542ff10f21df5fa90e5ad90e2 /src/pcm_utils.c | |
parent | 29cc42bf9781f2407cc7ccfe801329b07434e50b (diff) | |
download | mpd-505424285045f8b43c8b806c1cbd6e8e4431de7f.tar.gz mpd-505424285045f8b43c8b806c1cbd6e8e4431de7f.tar.xz mpd-505424285045f8b43c8b806c1cbd6e8e4431de7f.zip |
Removing debug output from pcm_utils.c
git-svn-id: https://svn.musicpd.org/mpd/branches/ancl@3282 09075e82-0dd4-0310-85a5-a0d7c8717e4f
Diffstat (limited to '')
-rw-r--r-- | src/pcm_utils.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/src/pcm_utils.c b/src/pcm_utils.c index 8341272e7..0a9aa2c0b 100644 --- a/src/pcm_utils.c +++ b/src/pcm_utils.c @@ -77,27 +77,22 @@ void pcm_convertToIntWithDither(int bits, mpd_fixed_t max = (1L << (fracBits)) - 1; mpd_fixed_t min = ~0L << (fracBits); mpd_fixed_t sample; -ERROR("conv: max=%x, min=%x \n", max, min); -//buffer += samples - 25; -//samples = 20; while(samples--) { -//ERROR("*buffer=%x, mask=%x\n", *buffer, mask); sample = *buffer + (ditherRandom & mask); if(sample > max || sample < min) ERROR("clipping! %x\n", sample); sample = sample>max ? max : (sample<min ? min : sample); *buffer = sample >> (fracBits - bits + 1); -//ERROR("sample=%x, *buffer=%x, dither=%x\n", sample, *buffer, ditherRandom & mask); buffer++; ditherRandom = prng(ditherRandom); } -//exit(EXIT_FAILURE); } char *pcm_convertSampleRate(AudioFormat *inFormat, char *inBuffer, size_t inFrames, AudioFormat *outFormat, size_t outFrames) { + return NULL; /* Input must be float32, 1 or 2 channels */ /* Interpolate using a second order polynomial */ /* k0 = s0 * @@ -290,13 +285,11 @@ void pcm_volumeChange(char * buffer, int bufferSize, AudioFormat * format, iScale = (mpd_uint32)(volume * 256) / 1000; shift = 8; -ERROR("vol1: iScale=%i, shift=%i, volume=%i\n", iScale, shift, volume); /* lower shifting value as much as possible */ while(!(iScale & 1) && shift) { iScale >>= 1; shift--; } -ERROR("vol2: iScale=%i, shift=%i\n", iScale, shift); /* change */ if(iScale == 1) { while(samples--) @@ -372,10 +365,6 @@ void pcm_convertAudioFormat(AudioFormat * inFormat, char * inBuffer, size_t inFormat->sampleRate; const int outSamples = outFrames * outFormat->channels; -ERROR("0 inSamples=%i in:bits=%i, fracBits=%i\n", - inSamples, inFormat->bits, inFormat->fracBits); -ERROR(" out:bits=%i, fracBits=%i\n", - outFormat->bits, outFormat->fracBits); /* make sure convBuffer is big enough for 2 channels of 32 bit samples */ dataLen = inFrames << 3; if(dataLen > convBufferLength) { |