csl::ADSR Class Reference

ADSR = 4-segment attack/decay/sustain/release envelope class. More...

#include <Envelope.h>

Inheritance diagram for csl::ADSR:

csl::Envelope csl::UnitGenerator csl::Scalable csl::Model csl::Controllable

List of all members.

Public Member Functions

 ADSR ()
 ADSR (LineMode mode, float t, float a, float d, float s, float r)
 Minimal version - ADSR.
 ADSR (LineMode mode, float t, float i, float a, float d, float s, float r)
 with initial delay - IADSR
 ADSR (float t, float a, float d, float s, float r)
 Minimal version - ADSR.
 ADSR (float t, float i, float a, float d, float s, float r)
 with initial delay - IADSR
 ~ADSR ()
void setAttack (float attack)
 Special accessors.
void setDecay (float decay)
void setSustain (float sustain)
void setRelease (float release)
void release (void)


Detailed Description

ADSR = 4-segment attack/decay/sustain/release envelope class.

Most of this is inherited from Envelope. This design is an extended ADSR envelope with an initial constant segment and offset (default = 0; this can be used to make an attack delay as on ARP ADSRs), attack time and max. val (default = 1.0), decay time, sustain level, and release time and final value (default = 0.0). All times are assumed to be given in seconds. Note that there are many variations on the constructor. The 5 line segments used internally look something like the following

| / . | / \ . | / \--------------- . | / \ . |---/ \ . | \----- . --------------------------------------------------------------------

Note that, internally, the breakpoints are kept with cumulative times, whereas the line segments only have start/stop Y values and durations (i.e., no absolute time reference).


Constructor & Destructor Documentation

csl::ADSR::ADSR (  )  [inline]

ADSR::ADSR ( LineMode  mode,
float  t,
float  a,
float  d,
float  s,
float  r 
)

Minimal version - ADSR.

~~~~~~~ Atack / Decay / Sustain / Release Envelope ~~~~~~~~~~~

Minimal version - ADSR . . . call the Super constructor, passing the appropriate points.

ADSR::ADSR ( LineMode  mode,
float  t,
float  i,
float  a,
float  d,
float  s,
float  r 
)

with initial delay - IADSR

ADSR::ADSR ( float  t,
float  a,
float  d,
float  s,
float  r 
)

Minimal version - ADSR.

Minimal version - ADSR . . . call the Super constructor, passing the appropriate points.

ADSR::ADSR ( float  t,
float  i,
float  a,
float  d,
float  s,
float  r 
)

with initial delay - IADSR

csl::ADSR::~ADSR (  )  [inline]


Member Function Documentation

void ADSR::setAttack ( float  attack  ) 

void ADSR::setDecay ( float  decay  ) 

void ADSR::setSustain ( float  sustain  ) 

void ADSR::setRelease ( float  release  ) 

void ADSR::release ( void   ) 


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

Generated on Thu Sep 17 23:14:17 2009 for CSL by  doxygen 1.5.8