From d8578fe6d9853f6ccab359331c8494d515ebac0d Mon Sep 17 00:00:00 2001 From: Sam Ellicott Date: Wed, 20 May 2020 20:34:37 -0400 Subject: [PATCH] Fix TCC being dumb --- colorchord2/OutputVoronoi.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/colorchord2/OutputVoronoi.c b/colorchord2/OutputVoronoi.c index c43c1af..714b429 100644 --- a/colorchord2/OutputVoronoi.c +++ b/colorchord2/OutputVoronoi.c @@ -126,7 +126,8 @@ static void DPOUpdate(void * id, struct NoteFinder*nf) { float sat = nf->note_amplitudes_out[bestmatch] * d->satamp; if( sat > 1.0 ) sat = 1.0; - color = CCtoHEX( nf->note_positions[bestmatch] / nf->freqbins, 1.0, sat ); + float note_color = nf->note_positions[bestmatch] / nf->freqbins; + color = CCtoHEX( note_color, 1.0, sat ); } OutLEDs[led*3+0] = color & 0xff;