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

◆ reset()

void MayaFlux::Nodes::Generator::Logic::reset ( )

Resets internal state to initial conditions.

Clears history buffers, resets state variables, and returns the node to its initial configuration. Essential for restarting sequential processing or clearing accumulated state.

Definition at line 293 of file Logic.cpp.

294{
295 std::ranges::fill(m_history_ring, false);
296 m_history_head = 0;
298 m_edge_detected = false;
299 m_last_output = 0.0;
300 m_hysteresis_state = false;
301 m_temporal_time = 0.0;
302 m_input_buffer.assign(m_input_count, 0.0);
303}
size_t m_history_size
Maximum size of the history buffer.
Definition Logic.hpp:588
double m_temporal_time
Time tracking for temporal mode.
Definition Logic.hpp:596
std::vector< double > m_input_buffer
Definition Logic.hpp:598
bool m_edge_detected
Whether an edge was detected in the last processing.
Definition Logic.hpp:594
std::vector< uint8_t > m_history_ring
Ring buffer for history storage.
Definition Logic.hpp:600
bool m_hysteresis_state
State for hysteresis operator.
Definition Logic.hpp:595
size_t m_history_count
Number of valid entries in the history buffer.
Definition Logic.hpp:587
size_t m_history_head
Head index for the history ring buffer.
Definition Logic.hpp:586
size_t m_input_count
Expected number of inputs for multi-input mode.
Definition Logic.hpp:589
double m_last_output
The most recent sample value generated by this oscillator.
Definition Node.hpp:377

References m_edge_detected, m_history_count, m_history_head, m_history_ring, m_history_size, m_hysteresis_state, m_input_buffer, m_input_count, MayaFlux::Nodes::Node::m_last_output, and m_temporal_time.