Skip to content

daisysp::FractalRandomGenerator

Fractal Noise, stacks octaves of a noise source. More...

#include <fractal_noise.h>

Public Functions

Name
FractalRandomGenerator()
~FractalRandomGenerator()
void Init(float sample_rate)
float Process()
void SetFreq(float freq)
void SetColor(float color)

Detailed Description

template <typename T ,
int order>
class daisysp::FractalRandomGenerator;

Fractal Noise, stacks octaves of a noise source.

Author: Ported by Ben Sergentanis

Date: Jan 2021 T is the noise source to use. T must have SetFreq() and Init(sample_rate) functions.

Order is the number of noise sources to stack.

Ported from pichenettes/eurorack/plaits/dsp/noise/fractal_random_generator.h

to an independent module.

Original code written by Emilie Gillet in 2016.

Public Functions Documentation

function FractalRandomGenerator

inline FractalRandomGenerator()

function ~FractalRandomGenerator

inline ~FractalRandomGenerator()

function Init

inline void Init(
    float sample_rate
)

Parameters:

  • sample_rate Audio engine sample rate.

Initialize the module


function Process

inline float Process()

Get the next sample.


function SetFreq

inline void SetFreq(
    float freq
)

Parameters:

  • freq Frequency of the lowest noise source in Hz.

Set the lowest noise frequency.


function SetColor

inline void SetColor(
    float color
)

Sets the amount of high frequency noise. ** Works 0-1. 1 is the brightest, and 0 is the darkest.

---

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