Skip to content

Commit 5ebf637

Browse files
committed
Set FFTSize fixed
1 parent 6d4e28b commit 5ebf637

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/components/FFT.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ const FFT = forwardRef(
3232
) => {
3333
const fftBufferRef = useRef<number[][]>(Array.from({ length: 16 }, () => []));
3434
const [fftData, setFftData] = useState<number[][]>(Array.from({ length: 16 }, () => []));
35-
const fftSize = Math.pow(2, Math.round(Math.log2(currentSamplingRate / 2)));
35+
const fftSize = 256;
3636
const sampleupdateref = useRef<number>(50);
3737
sampleupdateref.current = currentSamplingRate / 10;
3838
const canvasRef = useRef<HTMLCanvasElement>(null);

0 commit comments

Comments
 (0)