1 | import { Gain } from "../../core/context/Gain.js";
|
2 | import { Param } from "../../core/context/Param.js";
|
3 | import { ToneAudioNode, ToneAudioNodeOptions } from "../../core/context/ToneAudioNode.js";
|
4 | import { Decibels } from "../../core/type/Units.js";
|
5 | interface VolumeOptions extends ToneAudioNodeOptions {
|
6 | volume: Decibels;
|
7 | mute: boolean;
|
8 | }
|
9 |
|
10 |
|
11 |
|
12 |
|
13 |
|
14 |
|
15 |
|
16 |
|
17 | export declare class Volume extends ToneAudioNode<VolumeOptions> {
|
18 | readonly name: string;
|
19 | |
20 |
|
21 |
|
22 | output: Gain<"decibels">;
|
23 | |
24 |
|
25 |
|
26 | input: Gain<"decibels">;
|
27 | |
28 |
|
29 |
|
30 | private _unmutedVolume;
|
31 | |
32 |
|
33 |
|
34 |
|
35 |
|
36 |
|
37 |
|
38 | volume: Param<"decibels">;
|
39 | |
40 |
|
41 |
|
42 | constructor(volume?: Decibels);
|
43 | constructor(options?: Partial<VolumeOptions>);
|
44 | static getDefaults(): VolumeOptions;
|
45 | /**
|
46 | * Mute the output.
|
47 | * @example
|
48 | * const vol = new Tone.Volume(-12).toDestination();
|
49 | * const osc = new Tone.Oscillator().connect(vol).start();
|
50 | * // mute the output
|
51 | * vol.mute = true;
|
52 | */
|
53 | get mute(): boolean;
|
54 | set mute(mute: boolean);
|
55 | /**
|
56 | * clean up
|
57 | */
|
58 | dispose(): this;
|
59 | }
|
60 | export {};
|