libpsynth 0.2.1
Public Types | Public Member Functions
psynth::synth::envelope< Range > Class Template Reference

Basic envelope interface. More...

#include <envelope.hpp>

Inheritance diagram for psynth::synth::envelope< Range >:
Inheritance graph
[legend]

List of all members.

Public Types

typedef Range range
typedef Range::value_type value_type

Public Member Functions

virtual value_type update ()=0
 Updates the envelope for one sample.
virtual value_type update (std::size_t samples)=0
 Updates the envelope for several samples.
virtual void update (const range &samples)=0
 Fills a buffer with samples from the envelope.
virtual void press ()=0
 Start the envelope effect.
virtual void release ()=0
 Start finishing the envelope.
virtual bool finished ()=0
 Returns wether the envelope has finished.

Detailed Description

template<class Range>
class psynth::synth::envelope< Range >

Basic envelope interface.


Member Typedef Documentation

template<class Range>
typedef Range psynth::synth::envelope< Range >::range
template<class Range>
typedef Range::value_type psynth::synth::envelope< Range >::value_type

Member Function Documentation

template<class Range>
virtual bool psynth::synth::envelope< Range >::finished ( ) [pure virtual]

Returns wether the envelope has finished.

Returns:
true if the envelope has finished and false otherwise.

Implemented in psynth::synth::multi_point_envelope< Range, ValuesPtr >, psynth::synth::simple_envelope< Range >, psynth::synth::multi_point_envelope< sample_range >, and psynth::synth::simple_envelope< sample_range >.

template<class Range>
virtual void psynth::synth::envelope< Range >::press ( ) [pure virtual]
template<class Range>
virtual void psynth::synth::envelope< Range >::release ( ) [pure virtual]
template<class Range>
virtual value_type psynth::synth::envelope< Range >::update ( std::size_t  samples) [pure virtual]

Updates the envelope for several samples.

Parameters:
samplesthe number of samples to advance.
Returns:
The value of the envelope after.

Implemented in psynth::synth::multi_point_envelope< Range, ValuesPtr >, psynth::synth::simple_envelope< Range >, psynth::synth::multi_point_envelope< sample_range >, and psynth::synth::simple_envelope< sample_range >.

template<class Range>
virtual void psynth::synth::envelope< Range >::update ( const range &  samples) [pure virtual]

Fills a buffer with samples from the envelope.

Parameters:
samplesThe buffer to fill.
n_samplesThe number of samples to fill.

Implemented in psynth::synth::multi_point_envelope< Range, ValuesPtr >, psynth::synth::simple_envelope< Range >, psynth::synth::multi_point_envelope< sample_range >, and psynth::synth::simple_envelope< sample_range >.

template<class Range>
virtual value_type psynth::synth::envelope< Range >::update ( ) [pure virtual]

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