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

◆ operator*() [1/2]

std::shared_ptr< Node > MayaFlux::Nodes::operator* ( std::shared_ptr< Node lhs,
std::shared_ptr< Node rhs 
)

Multiplies the outputs of two nodes (multiplication operator)

Parameters
lhsFirst node
rhsSecond node
Returns
A new node that outputs the product of both nodes' outputs

Creates a new node that processes both input nodes and multiplies their outputs. This is useful for amplitude modulation, scaling operations, and other multiplicative transformations:

auto modulated = carrier * modulator;

The resulting node takes an input, passes it to both source nodes, and returns the product of their outputs.

Definition at line 21 of file NodeOperators.cpp.

22{
23 auto result = std::make_shared<BinaryOpNode>(lhs, rhs, [](double a, double b) { return a * b; });
24 result->initialize();
25 return result;
26}