Pulp 1.88.0
Cross-platform audio plugin framework
Loading...
Searching...
No Matches
value_channel_json.hpp
Go to the documentation of this file.
1// value_channel_json.hpp - one serializer for a processor's value channels.
2//
3// Two consumers describe the same channels: the scripted-UI bridge
4// (`listValueChannels()`) and the inspector (`State.getValueChannels`). They
5// share this rather than hand-rolling a payload each, for the same reason
6// param_json exists — a second implementation drifts the day either side gains
7// a field, and a UI built against one shape then silently mis-reads the other.
8
9#pragma once
10
12
13#include <choc/containers/choc_Value.h>
14
15#include <span>
16
17namespace pulp::dataplane {
18
22const char* value_channel_shape_name(ValueChannelShape shape) noexcept;
23
25choc::value::Value value_channel_to_value(const ValueChannelInfo& info);
26
30choc::value::Value value_channels_to_value(const ValueChannelSet* channels);
31
35choc::value::Value value_channels_to_value(std::span<const ValueChannelInfo> channels);
36
37} // namespace pulp::dataplane
A processor's declared channels.
Definition value_channel_set.hpp:61
Named value channels: what a processor's DSP is computing, reachable by name from its UI.
Definition audio_bridge.hpp:9
choc::value::Value value_channel_to_value(const ValueChannelInfo &info)
One channel as {name, unit, shape, neutral}.
const char * value_channel_shape_name(ValueChannelShape shape) noexcept
Stable wire name for a channel's shape.
choc::value::Value value_channels_to_value(const ValueChannelSet *channels)
Every declared channel, in declaration order.
ValueChannelShape
The shape of a channel's payload.
Definition value_channel_telemetry.hpp:21
What a channel is, for discovery and for a UI lint to check names against.
Definition value_channel_telemetry.hpp:29