59void operator*(
const std::shared_ptr<Node>& node,
double value)
61 if (
auto gen = std::dynamic_pointer_cast<Generator>(node)) {
62 gen->set_amplitude(value);
65 "Cannot multiply non-generator node by a scalar. "
66 "Use set_[params] methods or create a BinaryOpNode.");
#define MF_ERROR(comp, ctx,...)
double amplitude
Current amplitude of the generator.
double phase
Current phase of the generator.
float frequency
Current frequency of the generator.
GeneratorContext m_context
virtual void set_frequency(float frequency)
Sets the generator's frequency.
virtual bool should_mock_process() const
Checks if the generator should mock process.
virtual double get_amplitude() const
Gets the current base amplitude.
GeneratorContextGpu m_context_gpu
virtual void set_amplitude(double amplitude)
Sets the generator's amplitude.
float m_frequency
Base frequency of the generator.
NodeContext & get_last_context() override
Gets the last created context object.
double m_amplitude
Base amplitude of the generator.
virtual void update_context(double value) override
Updates the context object for callbacks.
virtual void enable_mock_process(bool mock_process)
Allows RootNode to process the Generator without using the processed sample.
double m_phase
Current phase of the generator.
double value
Current sample value.
Base context class for node callbacks.
std::atomic< NodeState > m_state
Atomic state flag tracking the node's processing status.
bool is_gpu_compatible() const
Checks if the node supports GPU processing.
bool m_gpu_compatible
Flag indicating if the node supports GPU processing This flag is set by derived classes to indicate w...
@ NodeProcessing
Node graph processing (Nodes::NodeGraphManager)
@ API
MayaFlux/API Wrapper and convenience functions.
void operator*(const std::shared_ptr< Node > &node, double value)
Sets the generator's amplitude.
@ MOCK_PROCESS
Node should be processed but output ignored.
void atomic_add_flag(std::atomic< NodeState > &state, NodeState flag)
Atomically adds a flag to a node state.
void atomic_remove_flag(std::atomic< NodeState > &state, NodeState flag)
Atomically removes a flag from a node state.