1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 07:07:45 +00:00

Piano+LibDSP: Move Track to LibDSP

This is a tangly commit and it fixes all the bugs that a plain move
would have caused (i.e. we need to touch other logic which had wrong
assumptions).
This commit is contained in:
kleines Filmröllchen 2022-07-13 12:44:19 +02:00 committed by Linus Groh
parent 125122a9ab
commit 4941cffdd0
29 changed files with 322 additions and 413 deletions

View file

@ -20,6 +20,11 @@ Delay::Delay(NonnullRefPtr<Transport> transport)
m_parameters.append(m_delay_decay);
m_parameters.append(m_delay_time);
m_parameters.append(m_dry_gain);
m_delay_time.register_change_listener([this](auto const&) {
this->handle_delay_time_change();
});
handle_delay_time_change();
}
void Delay::handle_delay_time_change()
@ -35,9 +40,6 @@ void Delay::handle_delay_time_change()
void Delay::process_impl(Signal const& input_signal, Signal& output_signal)
{
// FIXME: This is allocating and needs to happen on a different thread.
handle_delay_time_change();
auto const& samples = input_signal.get<FixedArray<Sample>>();
auto& output = output_signal.get<FixedArray<Sample>>();
for (size_t i = 0; i < output.size(); ++i) {