30 QVariant destinationPort READ destinationPort WRITE setDestinationPort
31 NOTIFY destinationPortChanged)
35 struct ChannelSendProcessingCaches
39 std::vector<dsp::AudioPort *> audio_ins_rt_;
40 std::vector<dsp::AudioPort *> audio_outs_rt_;
51 dsp::PortType signal_type,
54 QObject * parent =
nullptr);
82 void setDestinationPort (
const QVariant &port);
84 Q_SIGNAL
void destinationPortChanged ();
95 const dsp::TempoMap &tempo_map)
noexcept override;
97 void custom_prepare_for_processing (
99 units::sample_rate_t sample_rate,
102 void custom_release_resources ()
override;
106 bool is_prefader ()
const {
return is_prefader_; }
107 bool is_audio ()
const {
return signal_type_ == dsp::PortType::Audio; }
108 bool is_midi ()
const {
return signal_type_ == dsp::PortType::Midi; }
112 assert (is_audio ());
113 return *get_input_ports ().at (0).get_object_as<
dsp::AudioPort> ();
118 return *get_input_ports ().front ().get_object_as<
dsp::MidiPort> ();
120 dsp::AudioPort &get_stereo_out_port ()
const
122 assert (is_audio ());
123 return *get_output_ports ().front ().get_object_as<dsp::AudioPort> ();
125 dsp::MidiPort &get_midi_out_port ()
const
128 return *get_output_ports ().front ().get_object_as<dsp::MidiPort> ();
153 bool has_destination ()
const {
return destination_port_.has_value (); }
156 static constexpr auto kSignalTypeKey =
"signalType"sv;
157 static constexpr auto kIsPrefaderKey =
"isPrefader"sv;
158 static constexpr auto kDestinationPortKey =
"destinationPort"sv;
159 friend void to_json (nlohmann::json &j,
const ChannelSend &p);
160 friend void from_json (
const nlohmann::json &j,
ChannelSend &p);
162 friend void init_from (
168 dsp::PortType signal_type_;
180 std::optional<dsp::PortUuidReference> destination_port_;
183 std::unique_ptr<ChannelSendProcessingCaches> processing_caches_;
void custom_process_block(EngineProcessTimeInfo time_nfo, const dsp::ITransport &transport, const dsp::TempoMap &tempo_map) noexcept override
Custom processor logic after processing all owned parameters.