Classes | UGens > Triggers | UGens > Filters > Linear

Changed : Filter : PureUGen : UGen : AbstractFunction : Object

Triggers when a value changes
Source: Filter.sc

Description

Triggers when a value changes.

Class Methods

Changed.ar(input, threshold: 0)

Changed.kr(input, threshold: 0)

A special case fixed filter.

Arguments:

input

signal input

threshold

threshold

Discussion:

Implements the formula:

out(i) = abs(in(i) - in(i-1)) > thresh

Inherited class methods

Instance Methods

Inherited instance methods

Examples

detect changes in a signal:

(
{
    var changingSignal = LFNoise0.ar(1000);
    var changed = Changed.ar(changingSignal);
    [changingSignal, changed]
}.plot2
);