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

◆ restore_state()

void MayaFlux::Nodes::Generator::Sine::restore_state ( )
overridevirtual

Restores the node's state from the last save Recursively cascades through all connected modulator nodes Protected - only NodeSourceProcessor and NodeBuffer can call.

Implements MayaFlux::Nodes::Node.

Definition at line 192 of file Sine.cpp.

193{
199
201 m_frequency_modulator->restore_state();
203 m_amplitude_modulator->restore_state();
204
205 m_state_saved = false;
206}
float m_frequency
Base frequency of the generator.
double m_phase
Current phase of the generator.
float m_offset
DC offset added to the output.
Definition Sine.hpp:217
double m_phase_inc
Phase increment per sample.
Definition Sine.hpp:212
std::shared_ptr< Node > m_frequency_modulator
Node that modulates the frequency.
Definition Sine.hpp:222
std::shared_ptr< Node > m_amplitude_modulator
Node that modulates the amplitude.
Definition Sine.hpp:227
bool m_state_saved
tracks if the node's state has been saved by a snapshot operation
Definition Node.hpp:426
double m_last_output
The most recent sample value generated by this oscillator.
Definition Node.hpp:374

References m_amplitude_modulator, MayaFlux::Nodes::Generator::Generator::m_frequency, m_frequency_modulator, MayaFlux::Nodes::Node::m_last_output, m_offset, MayaFlux::Nodes::Generator::Generator::m_phase, m_phase_inc, m_saved_frequency, m_saved_last_output, m_saved_offset, m_saved_phase, m_saved_phase_inc, and MayaFlux::Nodes::Node::m_state_saved.