public class Integrate extends UnitGenerator
Output accumulated sum of the input signal. This can be used to transform one signal into another, or to generate ramps between the limits by setting the input signal positive or negative. For a "leaky integrator" use a FilterOnePoleOneZero.
output = output + input;
if( output < lowerLimit )
output = lowerLimit;
else if( output > upperLimit )
output = upperLimit;
FilterOnePoleOneZero| Modifier and Type | Field and Description |
|---|---|
UnitInputPort |
input |
UnitInputPort |
lowerLimit
Output will be stopped internally from going below this value.
|
UnitOutputPort |
output |
UnitInputPort |
upperLimit
Output will be stopped internally from going above this value.
|
FALSE, TRUE| Constructor and Description |
|---|
Integrate() |
| Modifier and Type | Method and Description |
|---|---|
void |
generate(int start,
int limit)
Perform essential synthesis function.
|
addPort, addPort, convertHalfLifeToMultiplier, flattenOutputs, generate, getCircuit, getFramePeriod, getFrameRate, getPortByName, getPorts, getSynthesisEngine, getSynthesizer, getTopUnit, getUnitGenerator, isEnabled, pullData, setCircuit, setEnabled, setFrameRate, setPort, setSynthesisEngine, start, start, stop, stoppublic UnitInputPort input
public UnitInputPort lowerLimit
public UnitInputPort upperLimit
public UnitOutputPort output
public void generate(int start,
int limit)
UnitGeneratorgenerate in class UnitGeneratorstart - offset into port bufferslimit - limit offset into port buffers for loop