|
DSPark 1.6.1
Header-only audio DSP framework in pure C++20 — zero dependencies
|
#include <Saturation.h>

Public Member Functions | |
| virtual | ~SaturationAlgorithm ()=default |
| virtual void | prepare (const AudioSpec &spec) noexcept=0 |
| Prepares the algorithm with the current audio specification. | |
| virtual void | reset () noexcept=0 |
| Resets internal states (filters, phase, memory). | |
| virtual void | update (T, T, const AudioSpec &) noexcept |
| Updates internal coefficients dependent on block-rate parameters. | |
| virtual Saturation< T >::Algorithm | getType () const noexcept=0 |
| Identifies the exact algorithm type for CRTP static dispatch. | |
| void | setAntialias (bool on) noexcept |
| Enables 1st-order antiderivative anti-aliasing (ADAA) on the memoryless curves (Tanh/Tube/HardClip). Combined with oversampling this is the cleanest known approach (Parker/Zavalishin DAFx-16, Bilbao et al. 2017). No-op for algorithms that do not implement it. Default off (transparent). | |
Static Public Attributes | |
| static constexpr int | kAaCh = 16 |
Protected Attributes | |
| std::atomic< bool > | antialias_ { false } |
Definition at line 78 of file Saturation.h.
|
virtualdefault |
|
pure virtualnoexcept |
Identifies the exact algorithm type for CRTP static dispatch.
Implemented in dspark::detail::TanhAlgorithm< T >, dspark::detail::TubeAlgorithm< T >, dspark::detail::HardClipAlgorithm< T >, dspark::detail::ExciterAlgorithm< T >, dspark::detail::WavefolderAlgorithm< T >, dspark::detail::BitcrusherAlgorithm< T >, dspark::detail::TapeAlgorithm< T >, dspark::detail::TransformerAlgorithm< T >, dspark::detail::DownsampleAlgorithm< T >, and dspark::detail::MultiStageAlgorithm< T >.
|
pure virtualnoexcept |
Prepares the algorithm with the current audio specification.
Implemented in dspark::detail::TanhAlgorithm< T >, dspark::detail::TubeAlgorithm< T >, dspark::detail::HardClipAlgorithm< T >, dspark::detail::ExciterAlgorithm< T >, dspark::detail::WavefolderAlgorithm< T >, dspark::detail::BitcrusherAlgorithm< T >, dspark::detail::TapeAlgorithm< T >, dspark::detail::TransformerAlgorithm< T >, dspark::detail::DownsampleAlgorithm< T >, and dspark::detail::MultiStageAlgorithm< T >.
|
pure virtualnoexcept |
Resets internal states (filters, phase, memory).
Implemented in dspark::detail::TanhAlgorithm< T >, dspark::detail::TubeAlgorithm< T >, dspark::detail::HardClipAlgorithm< T >, dspark::detail::ExciterAlgorithm< T >, dspark::detail::WavefolderAlgorithm< T >, dspark::detail::BitcrusherAlgorithm< T >, dspark::detail::TapeAlgorithm< T >, dspark::detail::TransformerAlgorithm< T >, dspark::detail::DownsampleAlgorithm< T >, and dspark::detail::MultiStageAlgorithm< T >.
|
inlinenoexcept |
Enables 1st-order antiderivative anti-aliasing (ADAA) on the memoryless curves (Tanh/Tube/HardClip). Combined with oversampling this is the cleanest known approach (Parker/Zavalishin DAFx-16, Bilbao et al. 2017). No-op for algorithms that do not implement it. Default off (transparent).
Definition at line 103 of file Saturation.h.
|
inlinevirtualnoexcept |
Updates internal coefficients dependent on block-rate parameters.
Reimplemented in dspark::detail::MultiStageAlgorithm< T >, dspark::detail::BitcrusherAlgorithm< T >, dspark::detail::TapeAlgorithm< T >, dspark::detail::DownsampleAlgorithm< T >, and dspark::detail::TransformerAlgorithm< T >.
Definition at line 92 of file Saturation.h.
|
protected |
Definition at line 106 of file Saturation.h.
|
staticconstexpr |
Definition at line 81 of file Saturation.h.