MayaFlux 0.4.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ bind_node()

void MayaFlux::Kakshya::PlotProcessor::bind_node ( uint32_t  series_index,
std::shared_ptr< Nodes::Node node 
)

Bind a series slot to a Node.

Each process() calls Buffers::extract_multiple_samples(node, series_size), which handles snapshot context, save/restore state, and buffer lifecycle identically to NodeSourceProcessor. The series is filled with one full batch of node output per process() call.

Parameters
series_indexIndex returned by PlotContainer::add_series().
nodeNode to read from.

Definition at line 23 of file PlotProcessor.cpp.

25{
26 if (!node) {
27 MF_ERROR(C, X, "PlotProcessor::bind_node: null node for series {}", series_index);
28 return;
29 }
30 auto& b = m_bindings[series_index];
31 b.source_type = SourceType::NODE;
32 b.node = std::move(node);
33 b.node->add_buffer_reference();
34 b.audio_buffer.reset();
35 b.network.reset();
36 b.callable = {};
37}
#define MF_ERROR(comp, ctx,...)
size_t b
std::unordered_map< uint32_t, SeriesBinding > m_bindings

References b, m_bindings, MF_ERROR, and NODE.