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

◆ connect()

void MayaFlux::Nodes::NodeGraphManager::connect ( const std::string &  source_id,
const std::string &  target_id 
)

Connects two nodes by their string identifiers.

Parameters
source_idIdentifier of the source node
target_idIdentifier of the target node

Looks up both nodes by their identifiers and establishes a connection where the output of the source node becomes an input to the target node.

Equivalent to:

connect(get_node(source_id), get_node(target_id));
void connect(const std::string &source_id, const std::string &target_id)
Connects two nodes by their string identifiers.
std::shared_ptr< Node > get_node(const std::string &id)
Looks up a node by its string identifier.

Throws an exception if either node identifier is not found.

Definition at line 459 of file NodeGraphManager.cpp.

460{
461 auto source = get_node(source_id);
462 auto target = get_node(target_id);
463
464 if (source && target) {
465 auto chain = std::make_shared<ChainNode>(source, target, *this);
466 chain->initialize();
467 }
468}

References get_node().

+ Here is the call graph for this function: