MCPcopy Create free account
hub / github.com/LabSound/LabSound / setFftSize

Method setFftSize

src/core/RealtimeAnalyser.cpp:62–73  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

60}
61
62void RealtimeAnalyser::setFftSize(int fftSize)
63{
64 m_writeIndex = 0;
65
66 int size = max(min(RoundNextPow2(fftSize), MaxFFTSize), MinFFTSize);
67 m_fftSize = size;
68
69 m_analysisFrame = std::unique_ptr<FFTFrame>(new FFTFrame(size));
70
71 m_inputBuffer.zero();
72 m_magnitudeBuffer.allocate(size / 2);
73}
74
75void RealtimeAnalyser::writeInput(ContextRenderLock & r, AudioBus * bus, int framesToProcess)
76{

Callers

nothing calls this directly

Calls 3

RoundNextPow2Function · 0.85
allocateMethod · 0.80
zeroMethod · 0.45

Tested by

no test coverage detected