clamp fft value to prevent hard error

This commit is contained in:
Felix Roos
2023-08-28 09:02:31 +02:00
parent 2dc079b950
commit 15233c6d34
+1
View File
@@ -276,6 +276,7 @@ export const superdough = async (value, deadline, hapDuration) => {
// analyser
let analyserSend;
if (analyze) {
fft = clamp(fft, 1, 10);
const analyserNode = getAnalyser(/* orbit, */ 2 ** (fft + 5));
analyserSend = effectSend(post, analyserNode, analyze);
}