reaper-osc 0.2.0 → 0.3.0

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/dist/Tracks.d.ts CHANGED
@@ -1,136 +1,136 @@
1
- /** Contains classes for controlling tracks in Reaper
2
- * @module
3
- */
4
- import { TrackFx } from './Fx';
5
- import { INotifyPropertyChanged } from './Notify';
6
- import { ISendOscMessage, OscMessage } from './Messages';
7
- /** A Reaper track */
8
- export declare class Track implements INotifyPropertyChanged {
9
- readonly trackNumber: number;
10
- private _isMuted;
11
- private _isRecordArmed;
12
- private _isSelected;
13
- private _isSoloed;
14
- private _name;
15
- private _pan;
16
- private _pan2;
17
- private _panMode;
18
- private _recordMonitoring;
19
- private _volumeDb;
20
- private _volumeFaderPosition;
21
- private _vu;
22
- private _vuLeft;
23
- private _vuRight;
24
- private readonly _fx;
25
- private readonly _handlers;
26
- private readonly _sendOscMessage;
27
- /**
28
- * @param trackNumber The track's number in the current bank
29
- * @param numberOfFx The number of FX per FX bank
30
- * @param sendOscMessage A callback used to send OSC messages to Reaper
31
- */
32
- constructor(trackNumber: number, numberOfFx: number, sendOscMessage: ISendOscMessage);
33
- /** Deselect the track */
34
- deselect(): void;
35
- /** The track's current FX back */
36
- get fx(): TrackFx[];
37
- /** Indicates whether the track is muted */
38
- get isMuted(): boolean;
39
- /** Indicates whether the track is armed for recording */
40
- get isRecordArmed(): boolean;
41
- /** Indicates whether the track is selected*/
42
- get isSelected(): boolean;
43
- /** Indicates whether the track is soloed */
44
- get isSoloed(): boolean;
45
- /** Mute the track */
46
- mute(): void;
47
- /** The track name */
48
- get name(): string;
49
- onPropertyChanged(property: string, callback: () => void): void;
50
- /** A floating-point value between -1 and 1 that indicates the pan position, with -1 being 100% left and 1 being 100% right */
51
- get pan(): number;
52
- /** A floating-point value between -1 and 1 that indicates the pan 2 position, with -1 being 100% left and 1 being 100% right */
53
- get pan2(): number;
54
- /** The current pan mode */
55
- get panMode(): string;
56
- /**
57
- * Receive and handle an OSC message
58
- * @param message The message to be handled
59
- */
60
- receive(message: OscMessage): boolean;
61
- /** Arm the track for recording */
62
- recordArm(): void;
63
- /** Indicates the record monitoring mode */
64
- get recordMonitoring(): RecordMonitoringMode;
65
- /** Disarm track recording */
66
- recordDisarm(): void;
67
- /**
68
- * Renames the track
69
- * @param name The new name of the track
70
- * @example
71
- * ```typescript
72
- * // Change the track name to 'Guitar'
73
- * track.rename('Guitar');
74
- * ```
75
- */
76
- rename(name: string): void;
77
- /** Select the track */
78
- select(): void;
79
- /**
80
- * Set the record monitoring mode
81
- * @param {RecordMonitorMode} value
82
- * */
83
- setMonitoringMode(value: RecordMonitoringMode): void;
84
- /**
85
- * Sets the pan
86
- * @param value A floating-point value between -1 and 1, where -1 is 100% left and 1 is 100% right
87
- */
88
- setPan(value: number): void;
89
- /**
90
- * Sets the pan 2
91
- * @param value A floating-point value between -1 and 1, where -1 is 100% left and 1 is 100% right
92
- */
93
- setPan2(value: number): void;
94
- /**
95
- * Sets the volume to a specific dB value.
96
- * @param value Value (in dB) to set the volume to. Valid range is -100 to 12.
97
- */
98
- setVolumeDb(value: number): void;
99
- /** Sets the volume by moving the fader to a specific position
100
- * @param position A value for the fader position between 0 and 1, where 0 is all the way down and 1 is all the way up
101
- */
102
- setVolumeFaderPosition(position: number): void;
103
- /** Solo the track */
104
- solo(): void;
105
- /** Toggle mute on/off */
106
- toggleMute(): void;
107
- /** Toggle record arm on/off */
108
- toggleRecordArm(): void;
109
- /** Toggle solo on/off */
110
- toggleSolo(): void;
111
- /** Unmute the track */
112
- unmute(): void;
113
- /** Unsolo the track */
114
- unsolo(): void;
115
- /** The track volume in dB */
116
- get volumeDb(): number;
117
- /** A floating-point value between 0 and 1 that indicates the fader position, with 0 being all the way down and 1 being all the way up */
118
- get volumeFaderPosition(): number;
119
- /** A floating-point value between 0 and 1 that indicates the VU level */
120
- get vu(): number;
121
- /** A floating-point value between 0 and 1 that indicates the Left VU level */
122
- get vuLeft(): number;
123
- /** A floating-point value between 0 and 1 that indicates the Right VU level */
124
- get vuRight(): number;
125
- private initHandlers;
126
- /** The OSC address of the track */
127
- private get oscAddress();
128
- }
129
- export declare enum RecordMonitoringMode {
130
- /** Record monitoring disabled */
131
- OFF = 0,
132
- /** Record monitoring enabled */
133
- ON = 1,
134
- /** Tape auto style */
135
- AUTO = 2
136
- }
1
+ /** Contains classes for controlling tracks in Reaper
2
+ * @module
3
+ */
4
+ import { TrackFx } from './Fx';
5
+ import { INotifyPropertyChanged } from './Notify';
6
+ import { ISendOscMessage, OscMessage } from './Messages';
7
+ /** A Reaper track */
8
+ export declare class Track implements INotifyPropertyChanged {
9
+ readonly trackNumber: number;
10
+ private _isMuted;
11
+ private _isRecordArmed;
12
+ private _isSelected;
13
+ private _isSoloed;
14
+ private _name;
15
+ private _pan;
16
+ private _pan2;
17
+ private _panMode;
18
+ private _recordMonitoring;
19
+ private _volumeDb;
20
+ private _volumeFaderPosition;
21
+ private _vu;
22
+ private _vuLeft;
23
+ private _vuRight;
24
+ private readonly _fx;
25
+ private readonly _handlers;
26
+ private readonly _sendOscMessage;
27
+ /**
28
+ * @param trackNumber The track's number in the current bank
29
+ * @param numberOfFx The number of FX per FX bank
30
+ * @param sendOscMessage A callback used to send OSC messages to Reaper
31
+ */
32
+ constructor(trackNumber: number, numberOfFx: number, sendOscMessage: ISendOscMessage);
33
+ /** Deselect the track */
34
+ deselect(): void;
35
+ /** The track's current FX back */
36
+ get fx(): TrackFx[];
37
+ /** Indicates whether the track is muted */
38
+ get isMuted(): boolean;
39
+ /** Indicates whether the track is armed for recording */
40
+ get isRecordArmed(): boolean;
41
+ /** Indicates whether the track is selected*/
42
+ get isSelected(): boolean;
43
+ /** Indicates whether the track is soloed */
44
+ get isSoloed(): boolean;
45
+ /** Mute the track */
46
+ mute(): void;
47
+ /** The track name */
48
+ get name(): string;
49
+ onPropertyChanged(property: string, callback: () => void): () => void;
50
+ /** A floating-point value between -1 and 1 that indicates the pan position, with -1 being 100% left and 1 being 100% right */
51
+ get pan(): number;
52
+ /** A floating-point value between -1 and 1 that indicates the pan 2 position, with -1 being 100% left and 1 being 100% right */
53
+ get pan2(): number;
54
+ /** The current pan mode */
55
+ get panMode(): string;
56
+ /**
57
+ * Receive and handle an OSC message
58
+ * @param message The message to be handled
59
+ */
60
+ receive(message: OscMessage): boolean;
61
+ /** Arm the track for recording */
62
+ recordArm(): void;
63
+ /** Indicates the record monitoring mode */
64
+ get recordMonitoring(): RecordMonitoringMode;
65
+ /** Disarm track recording */
66
+ recordDisarm(): void;
67
+ /**
68
+ * Renames the track
69
+ * @param name The new name of the track
70
+ * @example
71
+ * ```typescript
72
+ * // Change the track name to 'Guitar'
73
+ * track.rename('Guitar');
74
+ * ```
75
+ */
76
+ rename(name: string): void;
77
+ /** Select the track */
78
+ select(): void;
79
+ /**
80
+ * Set the record monitoring mode
81
+ * @param {RecordMonitorMode} value
82
+ * */
83
+ setMonitoringMode(value: RecordMonitoringMode): void;
84
+ /**
85
+ * Sets the pan
86
+ * @param value A floating-point value between -1 and 1, where -1 is 100% left and 1 is 100% right
87
+ */
88
+ setPan(value: number): void;
89
+ /**
90
+ * Sets the pan 2
91
+ * @param value A floating-point value between -1 and 1, where -1 is 100% left and 1 is 100% right
92
+ */
93
+ setPan2(value: number): void;
94
+ /**
95
+ * Sets the volume to a specific dB value.
96
+ * @param value Value (in dB) to set the volume to. Valid range is -100 to 12.
97
+ */
98
+ setVolumeDb(value: number): void;
99
+ /** Sets the volume by moving the fader to a specific position
100
+ * @param position A value for the fader position between 0 and 1, where 0 is all the way down and 1 is all the way up
101
+ */
102
+ setVolumeFaderPosition(position: number): void;
103
+ /** Solo the track */
104
+ solo(): void;
105
+ /** Toggle mute on/off */
106
+ toggleMute(): void;
107
+ /** Toggle record arm on/off */
108
+ toggleRecordArm(): void;
109
+ /** Toggle solo on/off */
110
+ toggleSolo(): void;
111
+ /** Unmute the track */
112
+ unmute(): void;
113
+ /** Unsolo the track */
114
+ unsolo(): void;
115
+ /** The track volume in dB */
116
+ get volumeDb(): number;
117
+ /** A floating-point value between 0 and 1 that indicates the fader position, with 0 being all the way down and 1 being all the way up */
118
+ get volumeFaderPosition(): number;
119
+ /** A floating-point value between 0 and 1 that indicates the VU level */
120
+ get vu(): number;
121
+ /** A floating-point value between 0 and 1 that indicates the Left VU level */
122
+ get vuLeft(): number;
123
+ /** A floating-point value between 0 and 1 that indicates the Right VU level */
124
+ get vuRight(): number;
125
+ private initHandlers;
126
+ /** The OSC address of the track */
127
+ private get oscAddress();
128
+ }
129
+ export declare enum RecordMonitoringMode {
130
+ /** Record monitoring disabled */
131
+ OFF = 0,
132
+ /** Record monitoring enabled */
133
+ ON = 1,
134
+ /** Tape auto style */
135
+ AUTO = 2
136
+ }