A block of samples for a scope-style display — an envelope curve, a detector's output, a window of the signal a processor is actually working on. More...
#include <value_source.hpp>
Public Attributes | |
| std::array< float, kMaxSamples > | samples {} |
| int | count = 0 |
| Valid samples in samples. | |
Static Public Attributes | |
| static constexpr int | kMaxSamples = 4096 |
A block of samples for a scope-style display — an envelope curve, a detector's output, a window of the signal a processor is actually working on.
Fixed capacity with a runtime valid count, the same shape as MeterFrame and AudioProbeSnapshot. That is what keeps it trivially copyable, which is what lets it ride a TripleBuffer with no allocation on the publish path and no new lock-free code to get wrong. The cost is a flat 3 × 16 KB per vector channel whether or not the publisher fills it; a channel is opt-in, so a plugin that declares none pays nothing.
| int pulp::dataplane::VectorFrame::count = 0 |
Valid samples in samples.
Consumers must still bound their index by min(count, kMaxSamples) — publish() clamps, but a frame read back from anywhere else is not guaranteed to have.
|
staticconstexpr |
| std::array<float, kMaxSamples> pulp::dataplane::VectorFrame::samples {} |