From 0c268ac09c933046395cf35f93e8f706955e3383 Mon Sep 17 00:00:00 2001 From: gvnnz Date: Mon, 20 May 2024 00:15:46 +0200 Subject: [PATCH] Refactor: change parameter type in Renderer::advanceChannels() method --- src/core/rendering/renderer.cpp | 6 +++--- src/core/rendering/renderer.h | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/core/rendering/renderer.cpp b/src/core/rendering/renderer.cpp index d103e1802..d57f52303 100644 --- a/src/core/rendering/renderer.cpp +++ b/src/core/rendering/renderer.cpp @@ -119,7 +119,7 @@ void Renderer::render(mcl::AudioBuffer& out, const mcl::AudioBuffer& in, const m const Sequencer::EventBuffer& events = m_sequencer.advance(sequencer, bufferSize, kernelAudio.samplerate, actions); m_sequencer.render(out, document_RT); if (!document_RT.locked) - advanceChannels(events, channels, renderRange, quantizerStep); + advanceChannels(events, channels.getAll(), renderRange, quantizerStep); } /* Then render Mixer, channels and finalize output. */ @@ -151,9 +151,9 @@ void Renderer::render(mcl::AudioBuffer& out, const mcl::AudioBuffer& in, const m /* -------------------------------------------------------------------------- */ void Renderer::advanceChannels(const Sequencer::EventBuffer& events, - const model::Channels& channels, geompp::Range block, int quantizerStep) const + const std::vector& channels, geompp::Range block, int quantizerStep) const { - for (const Channel& c : channels.getAll()) + for (const Channel& c : channels) if (!c.isInternal()) advanceChannel(c, events, block, quantizerStep); } diff --git a/src/core/rendering/renderer.h b/src/core/rendering/renderer.h index 0da10ebf9..62024e8c3 100644 --- a/src/core/rendering/renderer.h +++ b/src/core/rendering/renderer.h @@ -70,10 +70,10 @@ class Renderer private: /* advanceChannels - Processes Channels' static events (e.g. pre-recorded actions or sequencer + Processes Channels' static events (e.g. pre-recorded actions or sequencer events) in the current audio block. Called when the sequencer is running. */ - void advanceChannels(const Sequencer::EventBuffer&, const model::Channels&, + void advanceChannels(const Sequencer::EventBuffer&, const std::vector&, geompp::Range, int quantizerStep) const; void advanceChannel(const Channel&, const Sequencer::EventBuffer&, geompp::Range, Frame quantizerStep) const;