tone 15.0.0 → 15.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Tone/component/analysis/Analyser.ts +1 -6
- package/Tone/component/analysis/FFT.ts +1 -1
- package/Tone/component/analysis/Follower.ts +1 -5
- package/Tone/component/analysis/Meter.ts +1 -3
- package/Tone/component/analysis/Waveform.ts +1 -3
- package/Tone/component/channel/Channel.ts +1 -6
- package/Tone/component/channel/CrossFade.ts +1 -7
- package/Tone/component/channel/Merge.ts +1 -3
- package/Tone/component/channel/MultibandSplit.ts +1 -6
- package/Tone/component/channel/PanVol.ts +1 -6
- package/Tone/component/channel/Panner.ts +1 -5
- package/Tone/component/channel/Panner3D.ts +1 -7
- package/Tone/component/channel/Recorder.ts +1 -1
- package/Tone/component/channel/Solo.ts +1 -1
- package/Tone/component/channel/Split.ts +1 -3
- package/Tone/component/channel/Volume.ts +1 -3
- package/Tone/component/dynamics/Compressor.ts +1 -6
- package/Tone/component/dynamics/Gate.ts +1 -8
- package/Tone/component/dynamics/Limiter.ts +1 -7
- package/Tone/component/dynamics/MidSideCompressor.ts +1 -5
- package/Tone/component/dynamics/MultibandCompressor.ts +1 -8
- package/Tone/component/envelope/Envelope.ts +1 -8
- package/Tone/component/envelope/FrequencyEnvelope.ts +1 -8
- package/Tone/component/filter/BiquadFilter.ts +1 -6
- package/Tone/component/filter/Convolver.ts +1 -6
- package/Tone/component/filter/EQ3.ts +1 -7
- package/Tone/component/filter/FeedbackCombFilter.ts +1 -6
- package/Tone/component/filter/Filter.ts +1 -7
- package/Tone/component/filter/LowpassCombFilter.ts +1 -7
- package/Tone/component/filter/OnePoleFilter.ts +1 -6
- package/Tone/core/clock/Clock.ts +1 -6
- package/Tone/core/clock/TickParam.ts +1 -3
- package/Tone/core/clock/TickSignal.ts +1 -3
- package/Tone/core/clock/TickSource.ts +1 -5
- package/Tone/core/clock/Transport.ts +1 -1
- package/Tone/core/context/AudioContext.ts +8 -3
- package/Tone/core/context/Delay.ts +1 -7
- package/Tone/core/context/Destination.ts +1 -1
- package/Tone/core/context/Gain.ts +1 -6
- package/Tone/core/context/Param.ts +1 -8
- package/Tone/effect/AutoFilter.ts +1 -7
- package/Tone/effect/AutoPanner.ts +1 -5
- package/Tone/effect/AutoWah.ts +1 -7
- package/Tone/effect/BitCrusher.ts +2 -4
- package/Tone/effect/Chebyshev.ts +1 -3
- package/Tone/effect/Chorus.ts +1 -7
- package/Tone/effect/Distortion.ts +1 -5
- package/Tone/effect/FeedbackDelay.ts +1 -6
- package/Tone/effect/Freeverb.ts +1 -6
- package/Tone/effect/FrequencyShifter.ts +1 -5
- package/Tone/effect/JCReverb.ts +1 -5
- package/Tone/effect/Phaser.ts +1 -7
- package/Tone/effect/PingPongDelay.ts +1 -6
- package/Tone/effect/PitchShift.ts +1 -3
- package/Tone/effect/Reverb.ts +1 -1
- package/Tone/effect/StereoWidener.ts +2 -5
- package/Tone/effect/Tremolo.ts +1 -6
- package/Tone/effect/Vibrato.ts +1 -6
- package/Tone/event/Loop.ts +1 -6
- package/Tone/event/Part.ts +1 -6
- package/Tone/event/Pattern.ts +1 -7
- package/Tone/event/Sequence.ts +1 -7
- package/Tone/event/ToneEvent.ts +1 -6
- package/Tone/instrument/DuoSynth.ts +1 -1
- package/Tone/instrument/FMSynth.ts +1 -1
- package/Tone/instrument/Instrument.ts +1 -1
- package/Tone/instrument/MembraneSynth.ts +1 -1
- package/Tone/instrument/MetalSynth.ts +1 -1
- package/Tone/instrument/ModulationSynth.ts +1 -1
- package/Tone/instrument/MonoSynth.ts +1 -1
- package/Tone/instrument/Monophonic.ts +1 -1
- package/Tone/instrument/NoiseSynth.ts +2 -1
- package/Tone/instrument/PluckSynth.ts +1 -1
- package/Tone/instrument/PolySynth.ts +1 -6
- package/Tone/instrument/Sampler.ts +1 -8
- package/Tone/instrument/Synth.ts +1 -1
- package/Tone/signal/Add.ts +1 -5
- package/Tone/signal/GreaterThan.ts +1 -7
- package/Tone/signal/GreaterThanZero.ts +1 -5
- package/Tone/signal/Multiply.ts +1 -7
- package/Tone/signal/Pow.ts +1 -5
- package/Tone/signal/Scale.ts +1 -8
- package/Tone/signal/ScaleExp.ts +1 -9
- package/Tone/signal/Signal.ts +1 -7
- package/Tone/signal/SignalOperator.ts +3 -5
- package/Tone/signal/Subtract.ts +1 -5
- package/Tone/signal/SyncedSignal.ts +1 -6
- package/Tone/signal/ToneConstantSource.ts +1 -5
- package/Tone/signal/WaveShaper.ts +1 -8
- package/Tone/signal/Zero.ts +1 -3
- package/Tone/source/Noise.ts +1 -1
- package/Tone/source/UserMedia.ts +1 -3
- package/Tone/source/buffer/GrainPlayer.ts +1 -6
- package/Tone/source/buffer/Player.ts +1 -6
- package/Tone/source/buffer/Players.ts +1 -8
- package/Tone/source/buffer/ToneBufferSource.ts +1 -6
- package/Tone/source/oscillator/AMOscillator.ts +1 -7
- package/Tone/source/oscillator/FMOscillator.ts +1 -7
- package/Tone/source/oscillator/FatOscillator.ts +1 -7
- package/Tone/source/oscillator/LFO.ts +1 -7
- package/Tone/source/oscillator/OmniOscillator.ts +1 -6
- package/Tone/source/oscillator/Oscillator.ts +1 -6
- package/Tone/source/oscillator/PWMOscillator.ts +1 -6
- package/Tone/source/oscillator/PulseOscillator.ts +1 -6
- package/Tone/source/oscillator/ToneOscillatorNode.ts +1 -6
- package/Tone/version.ts +1 -1
- package/build/Tone.js +1 -1
- package/build/Tone.js.map +1 -1
- package/build/esm/component/analysis/Analyser.js +2 -5
- package/build/esm/component/analysis/Analyser.js.map +1 -1
- package/build/esm/component/analysis/FFT.js +2 -2
- package/build/esm/component/analysis/FFT.js.map +1 -1
- package/build/esm/component/analysis/Follower.js +2 -4
- package/build/esm/component/analysis/Follower.js.map +1 -1
- package/build/esm/component/analysis/Meter.js +2 -2
- package/build/esm/component/analysis/Meter.js.map +1 -1
- package/build/esm/component/analysis/Waveform.js +2 -2
- package/build/esm/component/analysis/Waveform.js.map +1 -1
- package/build/esm/component/channel/Channel.js +2 -5
- package/build/esm/component/channel/Channel.js.map +1 -1
- package/build/esm/component/channel/CrossFade.js +2 -4
- package/build/esm/component/channel/CrossFade.js.map +1 -1
- package/build/esm/component/channel/Merge.js +2 -2
- package/build/esm/component/channel/Merge.js.map +1 -1
- package/build/esm/component/channel/MultibandSplit.js +2 -5
- package/build/esm/component/channel/MultibandSplit.js.map +1 -1
- package/build/esm/component/channel/PanVol.js +2 -5
- package/build/esm/component/channel/PanVol.js.map +1 -1
- package/build/esm/component/channel/Panner.js +4 -4
- package/build/esm/component/channel/Panner.js.map +1 -1
- package/build/esm/component/channel/Panner3D.js +2 -6
- package/build/esm/component/channel/Panner3D.js.map +1 -1
- package/build/esm/component/channel/Recorder.js +2 -2
- package/build/esm/component/channel/Recorder.js.map +1 -1
- package/build/esm/component/channel/Solo.js +2 -2
- package/build/esm/component/channel/Solo.js.map +1 -1
- package/build/esm/component/channel/Split.js +2 -2
- package/build/esm/component/channel/Split.js.map +1 -1
- package/build/esm/component/channel/Volume.js +2 -2
- package/build/esm/component/channel/Volume.js.map +1 -1
- package/build/esm/component/dynamics/Compressor.js +2 -5
- package/build/esm/component/dynamics/Compressor.js.map +1 -1
- package/build/esm/component/dynamics/Gate.js +2 -5
- package/build/esm/component/dynamics/Gate.js.map +1 -1
- package/build/esm/component/dynamics/Limiter.js +2 -4
- package/build/esm/component/dynamics/Limiter.js.map +1 -1
- package/build/esm/component/dynamics/MidSideCompressor.js +2 -2
- package/build/esm/component/dynamics/MidSideCompressor.js.map +1 -1
- package/build/esm/component/dynamics/MultibandCompressor.js +2 -2
- package/build/esm/component/dynamics/MultibandCompressor.js.map +1 -1
- package/build/esm/component/envelope/Envelope.js +2 -7
- package/build/esm/component/envelope/Envelope.js.map +1 -1
- package/build/esm/component/envelope/FrequencyEnvelope.js +2 -7
- package/build/esm/component/envelope/FrequencyEnvelope.js.map +1 -1
- package/build/esm/component/filter/BiquadFilter.js +2 -5
- package/build/esm/component/filter/BiquadFilter.js.map +1 -1
- package/build/esm/component/filter/Convolver.js +2 -5
- package/build/esm/component/filter/Convolver.js.map +1 -1
- package/build/esm/component/filter/EQ3.js +3 -7
- package/build/esm/component/filter/EQ3.js.map +1 -1
- package/build/esm/component/filter/FeedbackCombFilter.js +2 -5
- package/build/esm/component/filter/FeedbackCombFilter.js.map +1 -1
- package/build/esm/component/filter/Filter.js +3 -7
- package/build/esm/component/filter/Filter.js.map +1 -1
- package/build/esm/component/filter/LowpassCombFilter.js +2 -6
- package/build/esm/component/filter/LowpassCombFilter.js.map +1 -1
- package/build/esm/component/filter/OnePoleFilter.js +2 -5
- package/build/esm/component/filter/OnePoleFilter.js.map +1 -1
- package/build/esm/core/clock/Clock.js +3 -6
- package/build/esm/core/clock/Clock.js.map +1 -1
- package/build/esm/core/clock/TickParam.js +2 -2
- package/build/esm/core/clock/TickParam.js.map +1 -1
- package/build/esm/core/clock/TickSignal.js +2 -2
- package/build/esm/core/clock/TickSignal.js.map +1 -1
- package/build/esm/core/clock/TickSource.js +2 -4
- package/build/esm/core/clock/TickSource.js.map +1 -1
- package/build/esm/core/clock/Transport.js +2 -2
- package/build/esm/core/clock/Transport.js.map +1 -1
- package/build/esm/core/context/AudioContext.d.ts +2 -0
- package/build/esm/core/context/AudioContext.js +4 -3
- package/build/esm/core/context/AudioContext.js.map +1 -1
- package/build/esm/core/context/Delay.js +2 -5
- package/build/esm/core/context/Delay.js.map +1 -1
- package/build/esm/core/context/Destination.js +2 -2
- package/build/esm/core/context/Destination.js.map +1 -1
- package/build/esm/core/context/Gain.js +3 -6
- package/build/esm/core/context/Gain.js.map +1 -1
- package/build/esm/core/context/Param.js +3 -7
- package/build/esm/core/context/Param.js.map +1 -1
- package/build/esm/effect/AutoFilter.js +2 -6
- package/build/esm/effect/AutoFilter.js.map +1 -1
- package/build/esm/effect/AutoPanner.js +2 -4
- package/build/esm/effect/AutoPanner.js.map +1 -1
- package/build/esm/effect/AutoWah.js +2 -6
- package/build/esm/effect/AutoWah.js.map +1 -1
- package/build/esm/effect/BitCrusher.js +4 -4
- package/build/esm/effect/BitCrusher.js.map +1 -1
- package/build/esm/effect/Chebyshev.js +2 -2
- package/build/esm/effect/Chebyshev.js.map +1 -1
- package/build/esm/effect/Chorus.js +2 -6
- package/build/esm/effect/Chorus.js.map +1 -1
- package/build/esm/effect/Distortion.js +2 -4
- package/build/esm/effect/Distortion.js.map +1 -1
- package/build/esm/effect/FeedbackDelay.js +2 -5
- package/build/esm/effect/FeedbackDelay.js.map +1 -1
- package/build/esm/effect/Freeverb.js +2 -5
- package/build/esm/effect/Freeverb.js.map +1 -1
- package/build/esm/effect/FrequencyShifter.js +2 -4
- package/build/esm/effect/FrequencyShifter.js.map +1 -1
- package/build/esm/effect/JCReverb.js +2 -4
- package/build/esm/effect/JCReverb.js.map +1 -1
- package/build/esm/effect/Phaser.js +2 -6
- package/build/esm/effect/Phaser.js.map +1 -1
- package/build/esm/effect/PingPongDelay.js +2 -5
- package/build/esm/effect/PingPongDelay.js.map +1 -1
- package/build/esm/effect/PitchShift.js +2 -2
- package/build/esm/effect/PitchShift.js.map +1 -1
- package/build/esm/effect/Reverb.js +4 -4
- package/build/esm/effect/Reverb.js.map +1 -1
- package/build/esm/effect/StereoWidener.js +2 -4
- package/build/esm/effect/StereoWidener.js.map +1 -1
- package/build/esm/effect/Tremolo.js +2 -5
- package/build/esm/effect/Tremolo.js.map +1 -1
- package/build/esm/effect/Vibrato.js +2 -5
- package/build/esm/effect/Vibrato.js.map +1 -1
- package/build/esm/event/Loop.js +2 -5
- package/build/esm/event/Loop.js.map +1 -1
- package/build/esm/event/Part.js +3 -6
- package/build/esm/event/Part.js.map +1 -1
- package/build/esm/event/Pattern.js +2 -6
- package/build/esm/event/Pattern.js.map +1 -1
- package/build/esm/event/Sequence.js +2 -6
- package/build/esm/event/Sequence.js.map +1 -1
- package/build/esm/event/ToneEvent.js +2 -5
- package/build/esm/event/ToneEvent.js.map +1 -1
- package/build/esm/instrument/DuoSynth.js +2 -2
- package/build/esm/instrument/DuoSynth.js.map +1 -1
- package/build/esm/instrument/FMSynth.js +2 -2
- package/build/esm/instrument/FMSynth.js.map +1 -1
- package/build/esm/instrument/Instrument.js +2 -2
- package/build/esm/instrument/Instrument.js.map +1 -1
- package/build/esm/instrument/MembraneSynth.js +2 -2
- package/build/esm/instrument/MembraneSynth.js.map +1 -1
- package/build/esm/instrument/MetalSynth.js +2 -2
- package/build/esm/instrument/MetalSynth.js.map +1 -1
- package/build/esm/instrument/ModulationSynth.js +2 -2
- package/build/esm/instrument/ModulationSynth.js.map +1 -1
- package/build/esm/instrument/MonoSynth.js +2 -2
- package/build/esm/instrument/MonoSynth.js.map +1 -1
- package/build/esm/instrument/Monophonic.js +1 -1
- package/build/esm/instrument/Monophonic.js.map +1 -1
- package/build/esm/instrument/NoiseSynth.js +2 -2
- package/build/esm/instrument/NoiseSynth.js.map +1 -1
- package/build/esm/instrument/PluckSynth.js +2 -2
- package/build/esm/instrument/PluckSynth.js.map +1 -1
- package/build/esm/instrument/PolySynth.js +2 -5
- package/build/esm/instrument/PolySynth.js.map +1 -1
- package/build/esm/instrument/Sampler.js +2 -2
- package/build/esm/instrument/Sampler.js.map +1 -1
- package/build/esm/instrument/Synth.js +2 -2
- package/build/esm/instrument/Synth.js.map +1 -1
- package/build/esm/signal/Add.js +1 -1
- package/build/esm/signal/Add.js.map +1 -1
- package/build/esm/signal/GreaterThan.js +2 -4
- package/build/esm/signal/GreaterThan.js.map +1 -1
- package/build/esm/signal/GreaterThanZero.js +1 -1
- package/build/esm/signal/GreaterThanZero.js.map +1 -1
- package/build/esm/signal/Multiply.js +2 -4
- package/build/esm/signal/Multiply.js.map +1 -1
- package/build/esm/signal/Pow.js +2 -2
- package/build/esm/signal/Pow.js.map +1 -1
- package/build/esm/signal/Scale.js +2 -5
- package/build/esm/signal/Scale.js.map +1 -1
- package/build/esm/signal/ScaleExp.js +2 -6
- package/build/esm/signal/ScaleExp.js.map +1 -1
- package/build/esm/signal/Signal.js +3 -6
- package/build/esm/signal/Signal.js.map +1 -1
- package/build/esm/signal/SignalOperator.js +2 -2
- package/build/esm/signal/SignalOperator.js.map +1 -1
- package/build/esm/signal/Subtract.js +1 -3
- package/build/esm/signal/Subtract.js.map +1 -1
- package/build/esm/signal/SyncedSignal.js +3 -6
- package/build/esm/signal/SyncedSignal.js.map +1 -1
- package/build/esm/signal/ToneConstantSource.js +2 -4
- package/build/esm/signal/ToneConstantSource.js.map +1 -1
- package/build/esm/signal/WaveShaper.js +2 -5
- package/build/esm/signal/WaveShaper.js.map +1 -1
- package/build/esm/signal/Zero.js +1 -1
- package/build/esm/signal/Zero.js.map +1 -1
- package/build/esm/source/Noise.js +4 -4
- package/build/esm/source/Noise.js.map +1 -1
- package/build/esm/source/UserMedia.js +2 -2
- package/build/esm/source/UserMedia.js.map +1 -1
- package/build/esm/source/buffer/GrainPlayer.js +2 -5
- package/build/esm/source/buffer/GrainPlayer.js.map +1 -1
- package/build/esm/source/buffer/Player.js +3 -6
- package/build/esm/source/buffer/Player.js.map +1 -1
- package/build/esm/source/buffer/Players.js +2 -2
- package/build/esm/source/buffer/Players.js.map +1 -1
- package/build/esm/source/buffer/ToneBufferSource.js +2 -5
- package/build/esm/source/buffer/ToneBufferSource.js.map +1 -1
- package/build/esm/source/oscillator/AMOscillator.js +2 -6
- package/build/esm/source/oscillator/AMOscillator.js.map +1 -1
- package/build/esm/source/oscillator/FMOscillator.js +2 -6
- package/build/esm/source/oscillator/FMOscillator.js.map +1 -1
- package/build/esm/source/oscillator/FatOscillator.js +2 -6
- package/build/esm/source/oscillator/FatOscillator.js.map +1 -1
- package/build/esm/source/oscillator/LFO.js +3 -7
- package/build/esm/source/oscillator/LFO.js.map +1 -1
- package/build/esm/source/oscillator/OmniOscillator.js +2 -5
- package/build/esm/source/oscillator/OmniOscillator.js.map +1 -1
- package/build/esm/source/oscillator/Oscillator.js +2 -5
- package/build/esm/source/oscillator/Oscillator.js.map +1 -1
- package/build/esm/source/oscillator/PWMOscillator.js +2 -5
- package/build/esm/source/oscillator/PWMOscillator.js.map +1 -1
- package/build/esm/source/oscillator/PulseOscillator.js +2 -5
- package/build/esm/source/oscillator/PulseOscillator.js.map +1 -1
- package/build/esm/source/oscillator/ToneOscillatorNode.js +2 -5
- package/build/esm/source/oscillator/ToneOscillatorNode.js.map +1 -1
- package/build/esm/version.js +1 -1
- package/package.json +1 -1
|
@@ -137,17 +137,12 @@ export class PolySynth<
|
|
|
137
137
|
);
|
|
138
138
|
constructor(options?: Partial<PolySynthOptions<Voice>>);
|
|
139
139
|
constructor() {
|
|
140
|
-
super(
|
|
141
|
-
optionsFromArguments(PolySynth.getDefaults(), arguments, [
|
|
142
|
-
"voice",
|
|
143
|
-
"options",
|
|
144
|
-
])
|
|
145
|
-
);
|
|
146
140
|
const options = optionsFromArguments(
|
|
147
141
|
PolySynth.getDefaults(),
|
|
148
142
|
arguments,
|
|
149
143
|
["voice", "options"]
|
|
150
144
|
);
|
|
145
|
+
super(options);
|
|
151
146
|
|
|
152
147
|
// check against the old API (pre 14.3.0)
|
|
153
148
|
assert(
|
|
@@ -110,20 +110,13 @@ export class Sampler extends Instrument<SamplerOptions> {
|
|
|
110
110
|
);
|
|
111
111
|
constructor(options?: Partial<SamplerOptions>);
|
|
112
112
|
constructor() {
|
|
113
|
-
super(
|
|
114
|
-
optionsFromArguments(
|
|
115
|
-
Sampler.getDefaults(),
|
|
116
|
-
arguments,
|
|
117
|
-
["urls", "onload", "baseUrl"],
|
|
118
|
-
"urls"
|
|
119
|
-
)
|
|
120
|
-
);
|
|
121
113
|
const options = optionsFromArguments(
|
|
122
114
|
Sampler.getDefaults(),
|
|
123
115
|
arguments,
|
|
124
116
|
["urls", "onload", "baseUrl"],
|
|
125
117
|
"urls"
|
|
126
118
|
);
|
|
119
|
+
super(options);
|
|
127
120
|
|
|
128
121
|
const urlMap = {};
|
|
129
122
|
Object.keys(options.urls).forEach((note) => {
|
package/Tone/instrument/Synth.ts
CHANGED
|
@@ -64,8 +64,8 @@ export class Synth<
|
|
|
64
64
|
*/
|
|
65
65
|
constructor(options?: RecursivePartial<SynthOptions>);
|
|
66
66
|
constructor() {
|
|
67
|
-
super(optionsFromArguments(Synth.getDefaults(), arguments));
|
|
68
67
|
const options = optionsFromArguments(Synth.getDefaults(), arguments);
|
|
68
|
+
super(options);
|
|
69
69
|
|
|
70
70
|
this.oscillator = new OmniOscillator(
|
|
71
71
|
Object.assign(
|
package/Tone/signal/Add.ts
CHANGED
|
@@ -43,11 +43,7 @@ export class Add extends Signal {
|
|
|
43
43
|
constructor(value?: number);
|
|
44
44
|
constructor(options?: Partial<SignalOptions<"number">>);
|
|
45
45
|
constructor() {
|
|
46
|
-
super(
|
|
47
|
-
Object.assign(
|
|
48
|
-
optionsFromArguments(Add.getDefaults(), arguments, ["value"])
|
|
49
|
-
)
|
|
50
|
-
);
|
|
46
|
+
super(optionsFromArguments(Add.getDefaults(), arguments, ["value"]));
|
|
51
47
|
|
|
52
48
|
connectSeries(this._constantSource, this._sum);
|
|
53
49
|
}
|
|
@@ -55,18 +55,12 @@ export class GreaterThan extends Signal<"number"> {
|
|
|
55
55
|
constructor(value?: number);
|
|
56
56
|
constructor(options?: Partial<GreaterThanOptions>);
|
|
57
57
|
constructor() {
|
|
58
|
-
super(
|
|
59
|
-
Object.assign(
|
|
60
|
-
optionsFromArguments(GreaterThan.getDefaults(), arguments, [
|
|
61
|
-
"value",
|
|
62
|
-
])
|
|
63
|
-
)
|
|
64
|
-
);
|
|
65
58
|
const options = optionsFromArguments(
|
|
66
59
|
GreaterThan.getDefaults(),
|
|
67
60
|
arguments,
|
|
68
61
|
["value"]
|
|
69
62
|
);
|
|
63
|
+
super(options);
|
|
70
64
|
|
|
71
65
|
this._subtract = this.input = new Subtract({
|
|
72
66
|
context: this.context,
|
|
@@ -35,11 +35,7 @@ export class GreaterThanZero extends SignalOperator<GreaterThanZeroOptions> {
|
|
|
35
35
|
|
|
36
36
|
constructor(options?: Partial<GreaterThanZeroOptions>);
|
|
37
37
|
constructor() {
|
|
38
|
-
super(
|
|
39
|
-
Object.assign(
|
|
40
|
-
optionsFromArguments(GreaterThanZero.getDefaults(), arguments)
|
|
41
|
-
)
|
|
42
|
-
);
|
|
38
|
+
super(optionsFromArguments(GreaterThanZero.getDefaults(), arguments));
|
|
43
39
|
|
|
44
40
|
this._thresh = this.output = new WaveShaper({
|
|
45
41
|
context: this.context,
|
package/Tone/signal/Multiply.ts
CHANGED
|
@@ -59,18 +59,12 @@ export class Multiply<
|
|
|
59
59
|
constructor(value?: number);
|
|
60
60
|
constructor(options?: Partial<SignalOptions<TypeName>>);
|
|
61
61
|
constructor() {
|
|
62
|
-
super(
|
|
63
|
-
Object.assign(
|
|
64
|
-
optionsFromArguments(Multiply.getDefaults(), arguments, [
|
|
65
|
-
"value",
|
|
66
|
-
])
|
|
67
|
-
)
|
|
68
|
-
);
|
|
69
62
|
const options = optionsFromArguments(
|
|
70
63
|
Multiply.getDefaults(),
|
|
71
64
|
arguments,
|
|
72
65
|
["value"]
|
|
73
66
|
);
|
|
67
|
+
super(options);
|
|
74
68
|
|
|
75
69
|
this._mult =
|
|
76
70
|
this.input =
|
package/Tone/signal/Pow.ts
CHANGED
|
@@ -33,14 +33,10 @@ export class Pow extends SignalOperator<PowOptions> {
|
|
|
33
33
|
constructor(value?: number);
|
|
34
34
|
constructor(options?: Partial<PowOptions>);
|
|
35
35
|
constructor() {
|
|
36
|
-
super(
|
|
37
|
-
Object.assign(
|
|
38
|
-
optionsFromArguments(Pow.getDefaults(), arguments, ["value"])
|
|
39
|
-
)
|
|
40
|
-
);
|
|
41
36
|
const options = optionsFromArguments(Pow.getDefaults(), arguments, [
|
|
42
37
|
"value",
|
|
43
38
|
]);
|
|
39
|
+
super(options);
|
|
44
40
|
|
|
45
41
|
this._exponentScaler =
|
|
46
42
|
this.input =
|
package/Tone/signal/Scale.ts
CHANGED
|
@@ -59,18 +59,11 @@ export class Scale<
|
|
|
59
59
|
constructor(min?: number, max?: number);
|
|
60
60
|
constructor(options?: Partial<ScaleOptions>);
|
|
61
61
|
constructor() {
|
|
62
|
-
super(
|
|
63
|
-
Object.assign(
|
|
64
|
-
optionsFromArguments(Scale.getDefaults(), arguments, [
|
|
65
|
-
"min",
|
|
66
|
-
"max",
|
|
67
|
-
])
|
|
68
|
-
)
|
|
69
|
-
);
|
|
70
62
|
const options = optionsFromArguments(Scale.getDefaults(), arguments, [
|
|
71
63
|
"min",
|
|
72
64
|
"max",
|
|
73
65
|
]);
|
|
66
|
+
super(options as Options);
|
|
74
67
|
|
|
75
68
|
this._mult = this.input = new Multiply({
|
|
76
69
|
context: this.context,
|
package/Tone/signal/ScaleExp.ts
CHANGED
|
@@ -32,20 +32,12 @@ export class ScaleExp extends Scale<ScaleExpOptions> {
|
|
|
32
32
|
constructor(min?: number, max?: number, exponent?: number);
|
|
33
33
|
constructor(options?: Partial<ScaleExpOptions>);
|
|
34
34
|
constructor() {
|
|
35
|
-
super(
|
|
36
|
-
Object.assign(
|
|
37
|
-
optionsFromArguments(ScaleExp.getDefaults(), arguments, [
|
|
38
|
-
"min",
|
|
39
|
-
"max",
|
|
40
|
-
"exponent",
|
|
41
|
-
])
|
|
42
|
-
)
|
|
43
|
-
);
|
|
44
35
|
const options = optionsFromArguments(
|
|
45
36
|
ScaleExp.getDefaults(),
|
|
46
37
|
arguments,
|
|
47
38
|
["min", "max", "exponent"]
|
|
48
39
|
);
|
|
40
|
+
super(options);
|
|
49
41
|
|
|
50
42
|
this.input = this._exp = new Pow({
|
|
51
43
|
context: this.context,
|
package/Tone/signal/Signal.ts
CHANGED
|
@@ -66,17 +66,11 @@ export class Signal<TypeName extends UnitName = "number">
|
|
|
66
66
|
constructor(value?: UnitMap[TypeName], units?: TypeName);
|
|
67
67
|
constructor(options?: Partial<SignalOptions<TypeName>>);
|
|
68
68
|
constructor() {
|
|
69
|
-
super(
|
|
70
|
-
optionsFromArguments(Signal.getDefaults(), arguments, [
|
|
71
|
-
"value",
|
|
72
|
-
"units",
|
|
73
|
-
])
|
|
74
|
-
);
|
|
75
|
-
|
|
76
69
|
const options = optionsFromArguments(Signal.getDefaults(), arguments, [
|
|
77
70
|
"value",
|
|
78
71
|
"units",
|
|
79
72
|
]) as SignalOptions<TypeName>;
|
|
73
|
+
super(options);
|
|
80
74
|
|
|
81
75
|
this.output = this._constantSource = new ToneConstantSource({
|
|
82
76
|
context: this.context,
|
|
@@ -17,11 +17,9 @@ export abstract class SignalOperator<
|
|
|
17
17
|
constructor(options?: Partial<Options>);
|
|
18
18
|
constructor() {
|
|
19
19
|
super(
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
])
|
|
24
|
-
)
|
|
20
|
+
optionsFromArguments(SignalOperator.getDefaults(), arguments, [
|
|
21
|
+
"context",
|
|
22
|
+
])
|
|
25
23
|
);
|
|
26
24
|
}
|
|
27
25
|
|
package/Tone/signal/Subtract.ts
CHANGED
|
@@ -54,11 +54,7 @@ export class Subtract extends Signal {
|
|
|
54
54
|
constructor(options?: Partial<SignalOptions<"number">>);
|
|
55
55
|
constructor() {
|
|
56
56
|
super(
|
|
57
|
-
|
|
58
|
-
optionsFromArguments(Subtract.getDefaults(), arguments, [
|
|
59
|
-
"value",
|
|
60
|
-
])
|
|
61
|
-
)
|
|
57
|
+
optionsFromArguments(Subtract.getDefaults(), arguments, ["value"])
|
|
62
58
|
);
|
|
63
59
|
|
|
64
60
|
connectSeries(this._constantSource, this._neg, this._sum);
|
|
@@ -51,16 +51,11 @@ export class SyncedSignal<
|
|
|
51
51
|
constructor(value?: UnitMap[TypeName], units?: TypeName);
|
|
52
52
|
constructor(options?: Partial<SignalOptions<TypeName>>);
|
|
53
53
|
constructor() {
|
|
54
|
-
super(
|
|
55
|
-
optionsFromArguments(Signal.getDefaults(), arguments, [
|
|
56
|
-
"value",
|
|
57
|
-
"units",
|
|
58
|
-
])
|
|
59
|
-
);
|
|
60
54
|
const options = optionsFromArguments(Signal.getDefaults(), arguments, [
|
|
61
55
|
"value",
|
|
62
56
|
"units",
|
|
63
57
|
]) as SignalOptions<TypeName>;
|
|
58
|
+
super(options);
|
|
64
59
|
|
|
65
60
|
this._lastVal = options.value;
|
|
66
61
|
this._synced = this.context.transport.scheduleRepeat(
|
|
@@ -42,16 +42,12 @@ export class ToneConstantSource<
|
|
|
42
42
|
constructor(offset: UnitMap[TypeName]);
|
|
43
43
|
constructor(options?: Partial<ToneConstantSourceOptions<TypeName>>);
|
|
44
44
|
constructor() {
|
|
45
|
-
super(
|
|
46
|
-
optionsFromArguments(ToneConstantSource.getDefaults(), arguments, [
|
|
47
|
-
"offset",
|
|
48
|
-
])
|
|
49
|
-
);
|
|
50
45
|
const options = optionsFromArguments(
|
|
51
46
|
ToneConstantSource.getDefaults(),
|
|
52
47
|
arguments,
|
|
53
48
|
["offset"]
|
|
54
49
|
);
|
|
50
|
+
super(options);
|
|
55
51
|
|
|
56
52
|
connect(this._source, this._gainNode);
|
|
57
53
|
|
|
@@ -59,19 +59,12 @@ export class WaveShaper extends SignalOperator<WaveShaperOptions> {
|
|
|
59
59
|
constructor(mapping?: WaveShaperMapping, length?: number);
|
|
60
60
|
constructor(options?: Partial<WaveShaperOptions>);
|
|
61
61
|
constructor() {
|
|
62
|
-
super(
|
|
63
|
-
Object.assign(
|
|
64
|
-
optionsFromArguments(WaveShaper.getDefaults(), arguments, [
|
|
65
|
-
"mapping",
|
|
66
|
-
"length",
|
|
67
|
-
])
|
|
68
|
-
)
|
|
69
|
-
);
|
|
70
62
|
const options = optionsFromArguments(
|
|
71
63
|
WaveShaper.getDefaults(),
|
|
72
64
|
arguments,
|
|
73
65
|
["mapping", "length"]
|
|
74
66
|
);
|
|
67
|
+
super(options);
|
|
75
68
|
|
|
76
69
|
if (
|
|
77
70
|
isArray(options.mapping) ||
|
package/Tone/signal/Zero.ts
CHANGED
|
@@ -33,9 +33,7 @@ export class Zero extends SignalOperator<ToneAudioNodeOptions> {
|
|
|
33
33
|
|
|
34
34
|
constructor(options?: Partial<ToneAudioNodeOptions>);
|
|
35
35
|
constructor() {
|
|
36
|
-
super(
|
|
37
|
-
Object.assign(optionsFromArguments(Zero.getDefaults(), arguments))
|
|
38
|
-
);
|
|
36
|
+
super(optionsFromArguments(Zero.getDefaults(), arguments));
|
|
39
37
|
connect(this.context.getConstant(0), this._gain);
|
|
40
38
|
}
|
|
41
39
|
|
package/Tone/source/Noise.ts
CHANGED
|
@@ -69,10 +69,10 @@ export class Noise extends Source<NoiseOptions> {
|
|
|
69
69
|
constructor(type?: NoiseType);
|
|
70
70
|
constructor(options?: Partial<NoiseOptions>);
|
|
71
71
|
constructor() {
|
|
72
|
-
super(optionsFromArguments(Noise.getDefaults(), arguments, ["type"]));
|
|
73
72
|
const options = optionsFromArguments(Noise.getDefaults(), arguments, [
|
|
74
73
|
"type",
|
|
75
74
|
]);
|
|
75
|
+
super(options);
|
|
76
76
|
|
|
77
77
|
this._playbackRate = options.playbackRate;
|
|
78
78
|
this.type = options.type;
|
package/Tone/source/UserMedia.ts
CHANGED
|
@@ -73,14 +73,12 @@ export class UserMedia extends ToneAudioNode<UserMediaOptions> {
|
|
|
73
73
|
constructor(volume?: Decibels);
|
|
74
74
|
constructor(options?: Partial<UserMediaOptions>);
|
|
75
75
|
constructor() {
|
|
76
|
-
super(
|
|
77
|
-
optionsFromArguments(UserMedia.getDefaults(), arguments, ["volume"])
|
|
78
|
-
);
|
|
79
76
|
const options = optionsFromArguments(
|
|
80
77
|
UserMedia.getDefaults(),
|
|
81
78
|
arguments,
|
|
82
79
|
["volume"]
|
|
83
80
|
);
|
|
81
|
+
super(options);
|
|
84
82
|
|
|
85
83
|
this._volume = this.output = new Volume({
|
|
86
84
|
context: this.context,
|
|
@@ -92,17 +92,12 @@ export class GrainPlayer extends Source<GrainPlayerOptions> {
|
|
|
92
92
|
);
|
|
93
93
|
constructor(options?: Partial<GrainPlayerOptions>);
|
|
94
94
|
constructor() {
|
|
95
|
-
super(
|
|
96
|
-
optionsFromArguments(GrainPlayer.getDefaults(), arguments, [
|
|
97
|
-
"url",
|
|
98
|
-
"onload",
|
|
99
|
-
])
|
|
100
|
-
);
|
|
101
95
|
const options = optionsFromArguments(
|
|
102
96
|
GrainPlayer.getDefaults(),
|
|
103
97
|
arguments,
|
|
104
98
|
["url", "onload"]
|
|
105
99
|
);
|
|
100
|
+
super(options);
|
|
106
101
|
|
|
107
102
|
this.buffer = new ToneAudioBuffer({
|
|
108
103
|
onload: options.onload,
|
|
@@ -91,16 +91,11 @@ export class Player extends Source<PlayerOptions> {
|
|
|
91
91
|
);
|
|
92
92
|
constructor(options?: Partial<PlayerOptions>);
|
|
93
93
|
constructor() {
|
|
94
|
-
super(
|
|
95
|
-
optionsFromArguments(Player.getDefaults(), arguments, [
|
|
96
|
-
"url",
|
|
97
|
-
"onload",
|
|
98
|
-
])
|
|
99
|
-
);
|
|
100
94
|
const options = optionsFromArguments(Player.getDefaults(), arguments, [
|
|
101
95
|
"url",
|
|
102
96
|
"onload",
|
|
103
97
|
]);
|
|
98
|
+
super(options);
|
|
104
99
|
|
|
105
100
|
this._buffer = new ToneAudioBuffer({
|
|
106
101
|
onload: this._onload.bind(this, options.onload),
|
|
@@ -87,20 +87,13 @@ export class Players extends ToneAudioNode<PlayersOptions> {
|
|
|
87
87
|
);
|
|
88
88
|
constructor(options?: Partial<PlayersOptions>);
|
|
89
89
|
constructor() {
|
|
90
|
-
super(
|
|
91
|
-
optionsFromArguments(
|
|
92
|
-
Players.getDefaults(),
|
|
93
|
-
arguments,
|
|
94
|
-
["urls", "onload"],
|
|
95
|
-
"urls"
|
|
96
|
-
)
|
|
97
|
-
);
|
|
98
90
|
const options = optionsFromArguments(
|
|
99
91
|
Players.getDefaults(),
|
|
100
92
|
arguments,
|
|
101
93
|
["urls", "onload"],
|
|
102
94
|
"urls"
|
|
103
95
|
);
|
|
96
|
+
super(options);
|
|
104
97
|
|
|
105
98
|
/**
|
|
106
99
|
* The output volume node
|
|
@@ -67,17 +67,12 @@ export class ToneBufferSource extends OneShotSource<ToneBufferSourceOptions> {
|
|
|
67
67
|
);
|
|
68
68
|
constructor(options?: Partial<ToneBufferSourceOptions>);
|
|
69
69
|
constructor() {
|
|
70
|
-
super(
|
|
71
|
-
optionsFromArguments(ToneBufferSource.getDefaults(), arguments, [
|
|
72
|
-
"url",
|
|
73
|
-
"onload",
|
|
74
|
-
])
|
|
75
|
-
);
|
|
76
70
|
const options = optionsFromArguments(
|
|
77
71
|
ToneBufferSource.getDefaults(),
|
|
78
72
|
arguments,
|
|
79
73
|
["url", "onload"]
|
|
80
74
|
);
|
|
75
|
+
super(options);
|
|
81
76
|
|
|
82
77
|
connect(this._source, this._gainNode);
|
|
83
78
|
this._source.onended = () => this._stopSource();
|
|
@@ -97,18 +97,12 @@ export class AMOscillator
|
|
|
97
97
|
);
|
|
98
98
|
constructor(options?: Partial<AMConstructorOptions>);
|
|
99
99
|
constructor() {
|
|
100
|
-
super(
|
|
101
|
-
optionsFromArguments(AMOscillator.getDefaults(), arguments, [
|
|
102
|
-
"frequency",
|
|
103
|
-
"type",
|
|
104
|
-
"modulationType",
|
|
105
|
-
])
|
|
106
|
-
);
|
|
107
100
|
const options = optionsFromArguments(
|
|
108
101
|
AMOscillator.getDefaults(),
|
|
109
102
|
arguments,
|
|
110
103
|
["frequency", "type", "modulationType"]
|
|
111
104
|
);
|
|
105
|
+
super(options);
|
|
112
106
|
|
|
113
107
|
this._carrier = new Oscillator({
|
|
114
108
|
context: this.context,
|
|
@@ -99,18 +99,12 @@ export class FMOscillator
|
|
|
99
99
|
);
|
|
100
100
|
constructor(options?: Partial<FMConstructorOptions>);
|
|
101
101
|
constructor() {
|
|
102
|
-
super(
|
|
103
|
-
optionsFromArguments(FMOscillator.getDefaults(), arguments, [
|
|
104
|
-
"frequency",
|
|
105
|
-
"type",
|
|
106
|
-
"modulationType",
|
|
107
|
-
])
|
|
108
|
-
);
|
|
109
102
|
const options = optionsFromArguments(
|
|
110
103
|
FMOscillator.getDefaults(),
|
|
111
104
|
arguments,
|
|
112
105
|
["frequency", "type", "modulationType"]
|
|
113
106
|
);
|
|
107
|
+
super(options);
|
|
114
108
|
|
|
115
109
|
this._carrier = new Oscillator({
|
|
116
110
|
context: this.context,
|
|
@@ -79,18 +79,12 @@ export class FatOscillator
|
|
|
79
79
|
);
|
|
80
80
|
constructor(options?: Partial<FatConstructorOptions>);
|
|
81
81
|
constructor() {
|
|
82
|
-
super(
|
|
83
|
-
optionsFromArguments(FatOscillator.getDefaults(), arguments, [
|
|
84
|
-
"frequency",
|
|
85
|
-
"type",
|
|
86
|
-
"spread",
|
|
87
|
-
])
|
|
88
|
-
);
|
|
89
82
|
const options = optionsFromArguments(
|
|
90
83
|
FatOscillator.getDefaults(),
|
|
91
84
|
arguments,
|
|
92
85
|
["frequency", "type", "spread"]
|
|
93
86
|
);
|
|
87
|
+
super(options);
|
|
94
88
|
|
|
95
89
|
this.frequency = new Signal({
|
|
96
90
|
context: this.context,
|
|
@@ -124,18 +124,12 @@ export class LFO extends ToneAudioNode<LFOOptions> {
|
|
|
124
124
|
constructor(frequency?: Frequency, min?: number, max?: number);
|
|
125
125
|
constructor(options?: Partial<LFOOptions>);
|
|
126
126
|
constructor() {
|
|
127
|
-
super(
|
|
128
|
-
optionsFromArguments(LFO.getDefaults(), arguments, [
|
|
129
|
-
"frequency",
|
|
130
|
-
"min",
|
|
131
|
-
"max",
|
|
132
|
-
])
|
|
133
|
-
);
|
|
134
127
|
const options = optionsFromArguments(LFO.getDefaults(), arguments, [
|
|
135
128
|
"frequency",
|
|
136
129
|
"min",
|
|
137
130
|
"max",
|
|
138
131
|
]);
|
|
132
|
+
super(options);
|
|
139
133
|
|
|
140
134
|
this._oscillator = new Oscillator(
|
|
141
135
|
options as ToneOscillatorConstructorOptions
|
|
@@ -114,17 +114,12 @@ export class OmniOscillator<OscType extends AnyOscillator>
|
|
|
114
114
|
constructor(frequency?: Frequency, type?: OmniOscillatorType);
|
|
115
115
|
constructor(options?: Partial<OmniOscillatorOptions>);
|
|
116
116
|
constructor() {
|
|
117
|
-
super(
|
|
118
|
-
optionsFromArguments(OmniOscillator.getDefaults(), arguments, [
|
|
119
|
-
"frequency",
|
|
120
|
-
"type",
|
|
121
|
-
])
|
|
122
|
-
);
|
|
123
117
|
const options = optionsFromArguments(
|
|
124
118
|
OmniOscillator.getDefaults(),
|
|
125
119
|
arguments,
|
|
126
120
|
["frequency", "type"]
|
|
127
121
|
);
|
|
122
|
+
super(options);
|
|
128
123
|
|
|
129
124
|
this.frequency = new Signal({
|
|
130
125
|
context: this.context,
|
|
@@ -87,17 +87,12 @@ export class Oscillator
|
|
|
87
87
|
constructor(frequency?: Frequency, type?: ToneOscillatorType);
|
|
88
88
|
constructor(options?: Partial<ToneOscillatorConstructorOptions>);
|
|
89
89
|
constructor() {
|
|
90
|
-
super(
|
|
91
|
-
optionsFromArguments(Oscillator.getDefaults(), arguments, [
|
|
92
|
-
"frequency",
|
|
93
|
-
"type",
|
|
94
|
-
])
|
|
95
|
-
);
|
|
96
90
|
const options = optionsFromArguments(
|
|
97
91
|
Oscillator.getDefaults(),
|
|
98
92
|
arguments,
|
|
99
93
|
["frequency", "type"]
|
|
100
94
|
);
|
|
95
|
+
super(options);
|
|
101
96
|
|
|
102
97
|
this.frequency = new Signal<"frequency">({
|
|
103
98
|
context: this.context,
|
|
@@ -77,17 +77,12 @@ export class PWMOscillator
|
|
|
77
77
|
constructor(frequency?: Frequency, modulationFrequency?: Frequency);
|
|
78
78
|
constructor(options?: Partial<PWMOscillatorOptions>);
|
|
79
79
|
constructor() {
|
|
80
|
-
super(
|
|
81
|
-
optionsFromArguments(PWMOscillator.getDefaults(), arguments, [
|
|
82
|
-
"frequency",
|
|
83
|
-
"modulationFrequency",
|
|
84
|
-
])
|
|
85
|
-
);
|
|
86
80
|
const options = optionsFromArguments(
|
|
87
81
|
PWMOscillator.getDefaults(),
|
|
88
82
|
arguments,
|
|
89
83
|
["frequency", "modulationFrequency"]
|
|
90
84
|
);
|
|
85
|
+
super(options);
|
|
91
86
|
|
|
92
87
|
this._pulse = new PulseOscillator({
|
|
93
88
|
context: this.context,
|
|
@@ -108,17 +108,12 @@ export class PulseOscillator
|
|
|
108
108
|
constructor(frequency?: Frequency, width?: AudioRange);
|
|
109
109
|
constructor(options?: Partial<PulseOscillatorOptions>);
|
|
110
110
|
constructor() {
|
|
111
|
-
super(
|
|
112
|
-
optionsFromArguments(PulseOscillator.getDefaults(), arguments, [
|
|
113
|
-
"frequency",
|
|
114
|
-
"width",
|
|
115
|
-
])
|
|
116
|
-
);
|
|
117
111
|
const options = optionsFromArguments(
|
|
118
112
|
PulseOscillator.getDefaults(),
|
|
119
113
|
arguments,
|
|
120
114
|
["frequency", "width"]
|
|
121
115
|
);
|
|
116
|
+
super(options);
|
|
122
117
|
|
|
123
118
|
this.width = new Signal({
|
|
124
119
|
context: this.context,
|
|
@@ -43,17 +43,12 @@ export class ToneOscillatorNode extends OneShotSource<ToneOscillatorNodeOptions>
|
|
|
43
43
|
constructor(frequency: Frequency, type: OscillatorType);
|
|
44
44
|
constructor(options?: Partial<ToneOscillatorNodeOptions>);
|
|
45
45
|
constructor() {
|
|
46
|
-
super(
|
|
47
|
-
optionsFromArguments(ToneOscillatorNode.getDefaults(), arguments, [
|
|
48
|
-
"frequency",
|
|
49
|
-
"type",
|
|
50
|
-
])
|
|
51
|
-
);
|
|
52
46
|
const options = optionsFromArguments(
|
|
53
47
|
ToneOscillatorNode.getDefaults(),
|
|
54
48
|
arguments,
|
|
55
49
|
["frequency", "type"]
|
|
56
50
|
);
|
|
51
|
+
super(options);
|
|
57
52
|
|
|
58
53
|
connect(this._oscillator, this._gainNode);
|
|
59
54
|
|
package/Tone/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const version: string = "15.0.
|
|
1
|
+
export const version: string = "15.0.2";
|