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

◆ update_phase_increment()

void MayaFlux::Nodes::Generator::Phasor::update_phase_increment ( double  frequency)
private

Updates the phase increment based on a new frequency.

Parameters
frequencyNew frequency in Hz

This method calculates the phase increment needed to produce a complete cycle at the specified frequency at the current sample rate.

Definition at line 59 of file Phasor.cpp.

60{
62}
double frequency
double m_phase_inc
Phase increment per sample.
Definition Phasor.hpp:294
uint32_t m_sample_rate
Sample rate for audio processing, used for normalization.
Definition Node.hpp:431

References frequency, m_phase_inc, and MayaFlux::Nodes::Node::m_sample_rate.

Referenced by Phasor(), Phasor(), Phasor(), Phasor(), process_sample(), reset(), and set_frequency().

+ Here is the caller graph for this function: