Single particle-percussion voice composed from the shared collision model and Pulp's existing resonators. More...
#include <particle_percussion_voice.hpp>
Public Types | |
| enum class | Model : std::uint8_t { shaker , maraca , rattle , tambourine } |
Public Member Functions | |
| ParticlePercussionVoiceT () | |
| void | prepare (double sample_rate) |
| Prepares at 8 kHz or above. | |
| void | set_model (Model model) |
| Changes the body recipe and clears the voice's exciter and resonators. | |
| void | set_seed (std::uint64_t seed) noexcept |
| void | set_particle_count (int count) noexcept |
| void | set_event_rate (SampleType rate) noexcept |
| void | set_energy_decay (SampleType milliseconds) noexcept |
| void | set_sustain_floor (SampleType floor) noexcept |
| void | set_collision_energy_loss (SampleType loss) noexcept |
| void | reset () noexcept |
| void | excite (SampleType amount01) noexcept |
| SampleType | process () noexcept |
| void | process (SampleType *output, int num_samples) noexcept |
| Model | model () const noexcept |
| double | sample_rate () const noexcept |
| bool | prepared () const noexcept |
| std::size_t | retained_bytes () const noexcept |
| Heap storage retained by the prepared five-mode ModalBankT. | |
| int | tail_samples () const noexcept |
| Conservative render tail: remaining collision-envelope settling plus six T60 intervals for the longest configured body resonance. | |
Static Public Member Functions | |
| static constexpr int | latency_samples () noexcept |
Static Public Attributes | |
| static constexpr std::size_t | kMaxBands = 4 |
| static constexpr std::size_t | kTambourineModes = 5 |
| static constexpr double | kMinSupportedSampleRate |
Single particle-percussion voice composed from the shared collision model and Pulp's existing resonators.
This type owns no graph or instrument-level voice allocation.
prepare() may allocate through ModalBankT. Parameter setters and set_model() are control-side operations. process(), excite(), and reset() are bounded and allocation-free after preparation.
|
strong |
|
inline |
|
inlinenoexcept |
|
inlinestaticconstexprnoexcept |
|
inlinenodiscardnoexcept |
|
inline |
Prepares at 8 kHz or above.
Invalid, non-finite, or lower rates retain the prior valid rate; every call consistently resets dynamic state.
|
inlinenodiscardnoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenodiscardnoexcept |
Heap storage retained by the prepared five-mode ModalBankT.
Its seven aligned buffers each round one 16-lane group to the SIMD alignment.
|
inlinenodiscardnoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inline |
Changes the body recipe and clears the voice's exciter and resonators.
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenodiscardnoexcept |
Conservative render tail: remaining collision-envelope settling plus six T60 intervals for the longest configured body resonance.
|
staticconstexpr |
|
staticconstexpr |
|
staticconstexpr |