compress: Warn when samples are clipped.
[paraslash.git] / compress_filter.c
index d013259..f98fb41 100644 (file)
@@ -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;