Skip to content

daisysp::Phasor

More...

#include <phasor.h>

Public Functions

Name
Phasor()
~Phasor()
void Init(float sample_rate, float freq, float initial_phase)
void Init(float sample_rate, float freq)
void Init(float sample_rate)
float Process()
void SetFreq(float freq)
float GetFreq()

Detailed Description

class daisysp::Phasor;

Todo: Selecting which channels should be initialized/included in the sequence conversion.

Setup a similar start function for an external mux, but that seems outside the scope of this file.

Generates a normalized signal moving from 0-1 at the specified frequency.

Public Functions Documentation

function Phasor

inline Phasor()

function ~Phasor

inline ~Phasor()

function Init

inline void Init(
    float sample_rate,
    float freq,
    float initial_phase
)

Initializes the Phasor module sample rate, and freq are in Hz initial phase is in radians Additional Init functions have defaults when arg is not specified:

  • phs = 0.0f
  • freq = 1.0f

function Init

inline void Init(
    float sample_rate,
    float freq
)

Initialize phasor with samplerate and freq


function Init

inline void Init(
    float sample_rate
)

Initialize phasor with samplerate


function Process

float Process()

processes Phasor and returns current value


function SetFreq

void SetFreq(
    float freq
)

Sets frequency of the Phasor in Hz


function GetFreq

inline float GetFreq()

Returns current frequency value in Hz

---

Updated on 2024-01-03 at 19:38:46 +0000