From: Andre Noll Date: Sat, 18 Aug 2018 17:17:11 +0000 (+0200) Subject: compress: Warn when samples are clipped. X-Git-Tag: v0.6.3~42^2~2 X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=commitdiff_plain;h=6b966e1df730ab787014b4bd5dd08214d3722bfe compress: Warn when samples are clipped. --- diff --git a/compress_filter.c b/compress_filter.c index d0132596..f98fb413 100644 --- a/compress_filter.c +++ b/compress_filter.c @@ -80,6 +80,7 @@ next_buffer: sample *= pcd->current_gain; sample >>= gain_shift; if (sample > 32767) { /* clip */ + PARA_WARNING_LOG("clip: %d\n", sample); sample = 32767; pcd->current_gain = (3 * pcd->current_gain + (1 << inertia)) / 4;