m_inputFrameBuffer: Use vector of SampleFrame

Also, refactor buffer resizing into one function, and avoid useless
static method.
This commit is contained in:
Johannes Lorenz
2025-04-07 22:13:59 +02:00
parent 25ddb1f347
commit ecd6a63a0f
2 changed files with 20 additions and 12 deletions

View File

@@ -96,6 +96,7 @@ private slots:
private:
bool initJackClient();
void resizeInputBuffer(jack_nframes_t nframes);
void startProcessing() override;
void stopProcessing() override;
@@ -106,7 +107,6 @@ private:
int processCallback(jack_nframes_t nframes);
static int setBufferSizeCallback(jack_nframes_t nframes, void* udata);
static int staticProcessCallback(jack_nframes_t nframes, void* udata);
static void shutdownCallback(void* _udata);
@@ -119,7 +119,7 @@ private:
std::vector<jack_port_t*> m_outputPorts;
std::vector<jack_port_t*> m_inputPorts;
jack_default_audio_sample_t** m_tempOutBufs;
std::vector<jack_default_audio_sample_t> m_inputFrameBuffer;
std::vector<SampleFrame> m_inputFrameBuffer;
SampleFrame* m_outBuf;
SampleFrame* m_inBuf;