From: Mike Brady Date: Mon, 14 Dec 2015 17:12:03 +0000 (+0000) Subject: Add a little diagnostic to the output of the alac decoder. X-Git-Tag: 2.7.4~14 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6802f4ae2af1193d97d5804e62959aa0217644d1;p=thirdparty%2Fshairport-sync.git Add a little diagnostic to the output of the alac decoder. --- diff --git a/alac.c b/alac.c index 7259d458..d5833c61 100644 --- a/alac.c +++ b/alac.c @@ -810,7 +810,7 @@ void alac_decode_frame(alac_file *alac, } else { - fprintf(stderr, "FIXME: unhandled predicition type: %i\n", prediction_type); + fprintf(stderr, "FIXME: unhandled prediction type for compressed case: %i\n", prediction_type); /* i think the only other prediction type (or perhaps this is just a * boolean?) runs adaptive fir twice.. like: * predictor_decompress_fir_adapt(predictor_error, tempout, ...) @@ -1010,7 +1010,7 @@ void alac_decode_frame(alac_file *alac, } else { /* see mono case */ - fprintf(stderr, "FIXME: unhandled predicition type: %i\n", prediction_type_a); + fprintf(stderr, "FIXME: unhandled prediction type on channel 1: %i\n", prediction_type_a); } /* channel 2 */ @@ -1035,7 +1035,7 @@ void alac_decode_frame(alac_file *alac, } else { - fprintf(stderr, "FIXME: unhandled predicition type: %i\n", prediction_type_b); + fprintf(stderr, "FIXME: unhandled prediction type on channel 2: %i\n", prediction_type_b); } } else diff --git a/player.c b/player.c index de2a980f..3a8e7542 100644 --- a/player.c +++ b/player.c @@ -242,7 +242,13 @@ static void alac_decode(short *dest, uint8_t *buf, int len) { } else { alac_decode_frame(decoder_info, buf, dest, &outsize); } - + if (outsize!=FRAME_BYTES(frame_size)) { + if(outsize> 1); //*outptr++ = dithered_vol(((long)inptr[-1] + (long)inptr[1]) >> 1); *outptr++ = dithered_vol(shortmean(inptr[-2], inptr[0])); *outptr++ = dithered_vol(shortmean(inptr[-1], inptr[1])); } else if (stuff == -1) { - debug(3, "---------"); + // debug(3, "---------"); inptr++; inptr++; }