From 398af87ce75b1fd9933e84a81b82af33a68f8725 Mon Sep 17 00:00:00 2001 From: Ryan Suchocki Date: Thu, 19 Jan 2023 15:16:57 +0000 Subject: [PATCH] Init spectrogram filter outputs to zero --- src/display/spectrogram.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/display/spectrogram.c b/src/display/spectrogram.c index f74822e..9845fe8 100644 --- a/src/display/spectrogram.c +++ b/src/display/spectrogram.c @@ -41,6 +41,7 @@ void spectrogram_init(unsigned width, unsigned height, unsigned left, unsigned t sgam_left = left; sgam_top = top; smoothed_values = (double *)malloc(sizeof(double) * width); + memset(smoothed_values, 0, sizeof(double) * width); } void spectrogram_render_bg(fb_buf_t *fb)