Tone.ScaleExp

↳ EXTENDS Tone.SignalBase

Performs an exponential scaling on an input signal. Scales a NormalRange value [0,1] exponentially to the output range of outputMin to outputMax.

CONSTRUCTOR

new Tone.ScaleExp ( [
outputMin
= 0 ] , [
outputMax
= 1 ] , [
exponent
= 2 ] )
outputMin

The output value when the input is 0.

type: number
default: 0
outputMax

The output value when the input is 1.

type: number
default: 1
exponent

The exponent which scales the incoming signal.

type: number
default: 2

EXAMPLE

var scaleExp = new Tone.ScaleExp(0, 100, 2);
var signal = new Tone.Signal(0.5).connect(scaleExp);

Members

.exponent

number #

Instead of interpolating linearly between the min and max values, setting the exponent will interpolate between the two values with an exponential curve.

</>

.max

number #

The maximum output value. This number is output when the value input value is 1.

</>

.min

number #

The minimum output value. This number is output when the value input value is 0.

</>

Methods

.dispose ( )

#
↪ returns Tone.ScaleExp

this

Clean up.

</>
inherited from Tone.SignalBase

.connect ( )

#
node
type: AudioParam or AudioNode or Tone.Signal or Tone
outputNumber

The output number to connect from.

type: number
default: 0
inputNumber

The input number to connect to.

type: number
default: 0
↪ returns Tone.SignalBase

this

When signals connect to other signals or AudioParams, they take over the output value of that signal or AudioParam. For all other nodes, the behavior is the same as a default connect.

</>
docs generated Sep 15 2019