From 1db60b79965fb64e24fa4a7c253d11bb7e38b897 Mon Sep 17 00:00:00 2001 From: MysteryPancake Date: Sat, 8 Aug 2020 16:55:30 +1000 Subject: [PATCH] Is this a bug? array is a Float32Array The original code would be setting this.prevRaw = Float32Array, which doesn't make sense because it cannot be sliced. From the other page it seems this should be set to buffer instead. --- stft.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stft.js b/stft.js index aca9e5f..abbd8be 100644 --- a/stft.js +++ b/stft.js @@ -64,7 +64,7 @@ class STFT{ for(let i = 0; i < this.hopSize; i++){ this.prevProcessed[i] += overlapWindow[i +this.hopSize]; } - this.prevRaw = array; + this.prevRaw = buffer; return result; }