Deluge Firmware 1.3.0
Build date: 2026.11.13
Loading...
Searching...
No Matches
deluge::modulation::EnvelopeCurve Class Reference

#include <envelope_curve.h>

Public Member Functions

constexpr EnvelopeCurve (float k)
constexpr float falling (float x) const
 x in [0, 1]
constexpr float rising (float x) const
 The rising mirror image: 0 at x = 0, 1 at x = 1. With k > 0 it's fast at the start, like an RC charge.
float risingInverse (float value) const
 Inverse of rising(): where on the segment the curve reaches value. Not for the render path (uses log2).
constexpr float k () const

Private Attributes

float k_
float floor_
float scale_

Detailed Description

A falling segment from 1 at x = 0 to 0 at x = 1, normalised so its length doesn't depend on its shape.

k is how many octaves (6 dB steps) an unnormalised exponential would fall over the segment:

  • k = 0 is a straight line
  • k > 0 is a decaying exponential, steep at the start
  • k < 0 bends the other way: slow at the start, steep at the end The Deluge's original lookup tables decayTableSmall4 and decayTableSmall8 are exactly k = 4 and k = 8.

The documentation for this class was generated from the following file: