From 2d641d087fe923c94f3d3c558cb317db1b0041a7 Mon Sep 17 00:00:00 2001 From: Přemysl Eric Janouch Date: Fri, 9 Jul 2021 06:25:48 +0200 Subject: Spectrum analyser: add some useful comments --- nncmpp.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/nncmpp.c b/nncmpp.c index b422298..8677635 100644 --- a/nncmpp.c +++ b/nncmpp.c @@ -569,6 +569,9 @@ item_list_resize (struct item_list *self, size_t len) // --- Spectrum analyzer ------------------------------------------------------- +// See http://www.zytrax.com/tech/audio/equalization.html +// for a good write-up about this problem domain + #ifdef WITH_FFTW struct spectrum @@ -809,6 +812,7 @@ spectrum_init (struct spectrum *s, char *format, int bars, struct error **e) if (s->samples < 1) s->samples = 1; + // XXX: we average the channels but might want to average the DFT results if (s->bits == 8) s->decode = spectrum_decode_8; if (s->bits == 16) s->decode = spectrum_decode_16; -- cgit v1.2.3-70-g09d2