The audio-thread state of one switch. More...
#include <processing_switch_crossfade.hpp>
Public Member Functions | |
| void | begin (const ProcessingSwitchPlan &plan) noexcept |
| void | cancel () noexcept |
| bool | active () const noexcept |
| bool | finished () const noexcept |
| bool | warming () const noexcept |
| std::int64_t | position () const noexcept |
| const ProcessingSwitchPlan & | plan () const noexcept |
| void | mix (SampleType *const *output, const SampleType *const *incoming, int channels, int num_samples) noexcept |
| Blend num_samples of the outgoing output (in output) with the incoming output, in place, and advance. | |
The audio-thread state of one switch.
Allocation-free and lock-free.
While active(), the caller runs BOTH realisations on the same input — the outgoing one into output, the incoming one into a buffer of its own — and calls mix(), which leaves the heard result in output. Once finished() the caller drops the outgoing realisation and runs the incoming one alone; mix() has by then already been returning the incoming output exactly.
|
inlinenodiscardnoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenodiscardnoexcept |
|
inlinenoexcept |
Blend num_samples of the outgoing output (in output) with the incoming output, in place, and advance.
While warming output is left untouched; past the fade it becomes the incoming output exactly.
|
inlinenodiscardnoexcept |
|
inlinenodiscardnoexcept |
|
inlinenodiscardnoexcept |