@opendaw/studio-core 0.0.10 → 0.0.12
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/EffectFactories.d.ts +38 -0
- package/dist/EffectFactories.d.ts.map +1 -0
- package/dist/EffectFactories.js +163 -0
- package/dist/EffectFactory.d.ts +13 -0
- package/dist/EffectFactory.d.ts.map +1 -0
- package/dist/EffectFactory.js +1 -0
- package/dist/InstrumentBox.d.ts +3 -0
- package/dist/InstrumentBox.d.ts.map +1 -0
- package/dist/InstrumentBox.js +1 -0
- package/dist/InstrumentFactories.d.ts +15 -0
- package/dist/InstrumentFactories.d.ts.map +1 -0
- package/dist/{Instruments.js → InstrumentFactories.js} +31 -69
- package/dist/InstrumentFactory.d.ts +11 -0
- package/dist/InstrumentFactory.d.ts.map +1 -0
- package/dist/InstrumentFactory.js +1 -0
- package/dist/InstrumentOptions.d.ts +8 -0
- package/dist/InstrumentOptions.d.ts.map +1 -0
- package/dist/InstrumentOptions.js +1 -0
- package/dist/InstrumentProduct.d.ts +8 -0
- package/dist/InstrumentProduct.d.ts.map +1 -0
- package/dist/InstrumentProduct.js +1 -0
- package/dist/Project.d.ts +3 -1
- package/dist/Project.d.ts.map +1 -1
- package/dist/Project.js +7 -59
- package/dist/ProjectApi.d.ts +44 -0
- package/dist/ProjectApi.d.ts.map +1 -0
- package/dist/ProjectApi.js +217 -0
- package/dist/ProjectMigration.d.ts +5 -0
- package/dist/ProjectMigration.d.ts.map +1 -0
- package/dist/ProjectMigration.js +60 -0
- package/dist/index.d.ts +8 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -3
- package/dist/processors.js +2 -2
- package/dist/processors.js.map +3 -3
- package/dist/workers.js +2 -2
- package/dist/workers.js.map +4 -4
- package/package.json +16 -16
- package/dist/Effects.d.ts +0 -154
- package/dist/Effects.d.ts.map +0 -1
- package/dist/Effects.js +0 -166
- package/dist/Instruments.d.ts +0 -35
- package/dist/Instruments.d.ts.map +0 -1
- package/dist/Modifier.d.ts +0 -21
- package/dist/Modifier.d.ts.map +0 -1
- package/dist/Modifier.js +0 -168
@@ -0,0 +1,38 @@
|
|
1
|
+
import { EffectFactory } from "./EffectFactory";
|
2
|
+
export declare namespace Effects {
|
3
|
+
const Arpeggio: EffectFactory;
|
4
|
+
const Pitch: EffectFactory;
|
5
|
+
const Zeitgeist: EffectFactory;
|
6
|
+
const StereoTool: EffectFactory;
|
7
|
+
const Delay: EffectFactory;
|
8
|
+
const Reverb: EffectFactory;
|
9
|
+
const Revamp: EffectFactory;
|
10
|
+
const Modular: EffectFactory;
|
11
|
+
const MidiNamed: {
|
12
|
+
Arpeggio: EffectFactory;
|
13
|
+
Pitch: EffectFactory;
|
14
|
+
Zeitgeist: EffectFactory;
|
15
|
+
};
|
16
|
+
const AudioNamed: {
|
17
|
+
StereoTool: EffectFactory;
|
18
|
+
Delay: EffectFactory;
|
19
|
+
Reverb: EffectFactory;
|
20
|
+
Revamp: EffectFactory;
|
21
|
+
Modular: EffectFactory;
|
22
|
+
};
|
23
|
+
const MidiList: ReadonlyArray<Readonly<EffectFactory>>;
|
24
|
+
const AudioList: ReadonlyArray<Readonly<EffectFactory>>;
|
25
|
+
const MergedNamed: {
|
26
|
+
StereoTool: EffectFactory;
|
27
|
+
Delay: EffectFactory;
|
28
|
+
Reverb: EffectFactory;
|
29
|
+
Revamp: EffectFactory;
|
30
|
+
Modular: EffectFactory;
|
31
|
+
Arpeggio: EffectFactory;
|
32
|
+
Pitch: EffectFactory;
|
33
|
+
Zeitgeist: EffectFactory;
|
34
|
+
};
|
35
|
+
type MidiEffectKeys = keyof typeof MidiNamed;
|
36
|
+
type AudioEffectKeys = keyof typeof AudioNamed;
|
37
|
+
}
|
38
|
+
//# sourceMappingURL=EffectFactories.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"EffectFactories.d.ts","sourceRoot":"","sources":["../src/EffectFactories.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAC,aAAa,EAAC,MAAM,iBAAiB,CAAA;AAE7C,yBAAiB,OAAO,CAAC;IACd,MAAM,QAAQ,EAAE,aAWtB,CAAA;IAEM,MAAM,KAAK,EAAE,aAWnB,CAAA;IAEM,MAAM,SAAS,EAAE,aAqBvB,CAAA;IAEM,MAAM,UAAU,EAAE,aAWxB,CAAA;IAEM,MAAM,KAAK,EAAE,aAWnB,CAAA;IAEM,MAAM,MAAM,EAAE,aAYpB,CAAA;IAEM,MAAM,MAAM,EAAE,aA+BpB,CAAA;IAEM,MAAM,OAAO,EAAE,aAoCrB,CAAA;IAEM,MAAM,SAAS;;;;KAA+B,CAAA;IAC9C,MAAM,UAAU;;;;;;KAA+C,CAAA;IAE/D,MAAM,QAAQ,EAAE,aAAa,CAAC,QAAQ,CAAC,aAAa,CAAC,CAA4B,CAAA;IACjF,MAAM,SAAS,EAAE,aAAa,CAAC,QAAQ,CAAC,aAAa,CAAC,CAA6B,CAAA;IACnF,MAAM,WAAW;;;;;;;;;KAAgC,CAAA;IAExD,KAAY,cAAc,GAAG,MAAM,OAAO,SAAS,CAAA;IACnD,KAAY,eAAe,GAAG,MAAM,OAAO,UAAU,CAAA;CACxD"}
|
@@ -0,0 +1,163 @@
|
|
1
|
+
import { INVERSE_SQRT_2, UUID } from "@opendaw/lib-std";
|
2
|
+
import { ArpeggioDeviceBox, DelayDeviceBox, GrooveShuffleBox, ModularAudioInputBox, ModularAudioOutputBox, ModularBox, ModularDeviceBox, ModuleConnectionBox, PitchDeviceBox, RevampDeviceBox, ReverbDeviceBox, StereoToolDeviceBox, ZeitgeistDeviceBox } from "@opendaw/studio-boxes";
|
3
|
+
import { IconSymbol } from "@opendaw/studio-adapters";
|
4
|
+
export var Effects;
|
5
|
+
(function (Effects) {
|
6
|
+
Effects.Arpeggio = {
|
7
|
+
defaultName: "Arpeggio",
|
8
|
+
defaultIcon: IconSymbol.Stack,
|
9
|
+
description: "Generates rhythmic note sequences from chords",
|
10
|
+
separatorBefore: false,
|
11
|
+
type: "midi",
|
12
|
+
create: ({ boxGraph }, unit, index) => ArpeggioDeviceBox.create(boxGraph, UUID.generate(), box => {
|
13
|
+
box.label.setValue("Arpeggio");
|
14
|
+
box.index.setValue(index);
|
15
|
+
box.host.refer(unit);
|
16
|
+
})
|
17
|
+
};
|
18
|
+
Effects.Pitch = {
|
19
|
+
defaultName: "Pitch",
|
20
|
+
defaultIcon: IconSymbol.Note,
|
21
|
+
description: "Shifts the pitch of incoming notes",
|
22
|
+
separatorBefore: false,
|
23
|
+
type: "midi",
|
24
|
+
create: ({ boxGraph }, unit, index) => PitchDeviceBox.create(boxGraph, UUID.generate(), box => {
|
25
|
+
box.label.setValue("Pitch");
|
26
|
+
box.index.setValue(index);
|
27
|
+
box.host.refer(unit);
|
28
|
+
})
|
29
|
+
};
|
30
|
+
Effects.Zeitgeist = {
|
31
|
+
defaultName: "Zeitgeist",
|
32
|
+
defaultIcon: IconSymbol.Zeitgeist,
|
33
|
+
description: "Distorts space and time",
|
34
|
+
separatorBefore: false,
|
35
|
+
type: "midi",
|
36
|
+
create: ({ boxGraph, rootBoxAdapter }, unit, index) => {
|
37
|
+
const useGlobal = false; // TODO First Zeitgeist should be true
|
38
|
+
const shuffleBox = useGlobal
|
39
|
+
? rootBoxAdapter.groove.box
|
40
|
+
: GrooveShuffleBox.create(boxGraph, UUID.generate(), box => {
|
41
|
+
box.label.setValue("Shuffle");
|
42
|
+
box.duration.setValue(480);
|
43
|
+
});
|
44
|
+
return ZeitgeistDeviceBox.create(boxGraph, UUID.generate(), box => {
|
45
|
+
box.label.setValue("Zeitgeist");
|
46
|
+
box.groove.refer(shuffleBox);
|
47
|
+
box.index.setValue(index);
|
48
|
+
box.host.refer(unit);
|
49
|
+
});
|
50
|
+
}
|
51
|
+
};
|
52
|
+
Effects.StereoTool = {
|
53
|
+
defaultName: "Stereo Tool",
|
54
|
+
defaultIcon: IconSymbol.Stereo,
|
55
|
+
description: "Computes a stereo transformation matrix with volume, panning, phase inversion and stereo width.",
|
56
|
+
separatorBefore: false,
|
57
|
+
type: "audio",
|
58
|
+
create: ({ boxGraph }, unit, index) => StereoToolDeviceBox.create(boxGraph, UUID.generate(), box => {
|
59
|
+
box.label.setValue("Stereo Tool");
|
60
|
+
box.index.setValue(index);
|
61
|
+
box.host.refer(unit);
|
62
|
+
})
|
63
|
+
};
|
64
|
+
Effects.Delay = {
|
65
|
+
defaultName: "Delay",
|
66
|
+
defaultIcon: IconSymbol.Time,
|
67
|
+
description: "Echoes the input signal with time-based repeats",
|
68
|
+
separatorBefore: false,
|
69
|
+
type: "audio",
|
70
|
+
create: ({ boxGraph }, unit, index) => DelayDeviceBox.create(boxGraph, UUID.generate(), box => {
|
71
|
+
box.label.setValue("Delay");
|
72
|
+
box.index.setValue(index);
|
73
|
+
box.host.refer(unit);
|
74
|
+
})
|
75
|
+
};
|
76
|
+
Effects.Reverb = {
|
77
|
+
defaultName: "Reverb",
|
78
|
+
defaultIcon: IconSymbol.Cube,
|
79
|
+
description: "Simulates space and depth with reflections",
|
80
|
+
separatorBefore: false,
|
81
|
+
type: "audio",
|
82
|
+
create: ({ boxGraph }, unit, index) => ReverbDeviceBox.create(boxGraph, UUID.generate(), box => {
|
83
|
+
box.label.setValue("Reverb");
|
84
|
+
box.preDelay.setInitValue(0.001);
|
85
|
+
box.index.setValue(index);
|
86
|
+
box.host.refer(unit);
|
87
|
+
})
|
88
|
+
};
|
89
|
+
Effects.Revamp = {
|
90
|
+
defaultName: "Revamp",
|
91
|
+
defaultIcon: IconSymbol.EQ,
|
92
|
+
description: "Shapes the frequency balance of the sound",
|
93
|
+
separatorBefore: false,
|
94
|
+
type: "audio",
|
95
|
+
create: ({ boxGraph }, unit, index) => RevampDeviceBox.create(boxGraph, UUID.generate(), box => {
|
96
|
+
box.label.setValue("Revamp");
|
97
|
+
box.highPass.frequency.setInitValue(40.0);
|
98
|
+
box.highPass.order.setInitValue(2);
|
99
|
+
box.highPass.q.setInitValue(INVERSE_SQRT_2);
|
100
|
+
box.highPass.enabled.setInitValue(true);
|
101
|
+
box.lowShelf.frequency.setInitValue(80.0);
|
102
|
+
box.lowShelf.gain.setInitValue(6);
|
103
|
+
box.lowBell.frequency.setInitValue(120.0);
|
104
|
+
box.lowBell.gain.setInitValue(6);
|
105
|
+
box.lowBell.q.setInitValue(INVERSE_SQRT_2);
|
106
|
+
box.midBell.frequency.setInitValue(640.0);
|
107
|
+
box.midBell.q.setInitValue(INVERSE_SQRT_2);
|
108
|
+
box.midBell.gain.setInitValue(6);
|
109
|
+
box.highBell.frequency.setInitValue(3600.0);
|
110
|
+
box.highBell.q.setInitValue(INVERSE_SQRT_2);
|
111
|
+
box.highBell.gain.setInitValue(6);
|
112
|
+
box.highShelf.frequency.setInitValue(10000.0);
|
113
|
+
box.highShelf.gain.setInitValue(6);
|
114
|
+
box.lowPass.frequency.setInitValue(15000.0);
|
115
|
+
box.lowPass.order.setInitValue(2);
|
116
|
+
box.lowPass.q.setInitValue(INVERSE_SQRT_2);
|
117
|
+
box.index.setValue(index);
|
118
|
+
box.host.refer(unit);
|
119
|
+
})
|
120
|
+
};
|
121
|
+
Effects.Modular = {
|
122
|
+
defaultName: "🔇 Create New Modular Audio Effect (inaudible yet)",
|
123
|
+
defaultIcon: IconSymbol.Box,
|
124
|
+
description: "",
|
125
|
+
separatorBefore: true,
|
126
|
+
type: "audio",
|
127
|
+
create: ({ boxGraph, rootBox, userEditingManager }, unit, index) => {
|
128
|
+
const moduleSetupBox = ModularBox.create(boxGraph, UUID.generate(), box => {
|
129
|
+
box.collection.refer(rootBox.modularSetups);
|
130
|
+
box.label.setValue("Modular");
|
131
|
+
});
|
132
|
+
const modularInput = ModularAudioInputBox.create(boxGraph, UUID.generate(), box => {
|
133
|
+
box.attributes.collection.refer(moduleSetupBox.modules);
|
134
|
+
box.attributes.label.setValue("Modular Input");
|
135
|
+
box.attributes.x.setValue(-256);
|
136
|
+
box.attributes.y.setValue(32);
|
137
|
+
});
|
138
|
+
const modularOutput = ModularAudioOutputBox.create(boxGraph, UUID.generate(), box => {
|
139
|
+
box.attributes.collection.refer(moduleSetupBox.modules);
|
140
|
+
box.attributes.label.setValue("Modular Output");
|
141
|
+
box.attributes.x.setValue(256);
|
142
|
+
box.attributes.y.setValue(32);
|
143
|
+
});
|
144
|
+
ModuleConnectionBox.create(boxGraph, UUID.generate(), box => {
|
145
|
+
box.collection.refer(moduleSetupBox.connections);
|
146
|
+
box.source.refer(modularInput.output);
|
147
|
+
box.target.refer(modularOutput.input);
|
148
|
+
});
|
149
|
+
userEditingManager.modularSystem.edit(moduleSetupBox.editing);
|
150
|
+
return ModularDeviceBox.create(boxGraph, UUID.generate(), box => {
|
151
|
+
box.label.setValue("Modular");
|
152
|
+
box.modularSetup.refer(moduleSetupBox.device);
|
153
|
+
box.index.setValue(index);
|
154
|
+
box.host.refer(unit);
|
155
|
+
});
|
156
|
+
}
|
157
|
+
};
|
158
|
+
Effects.MidiNamed = { Arpeggio: Effects.Arpeggio, Pitch: Effects.Pitch, Zeitgeist: Effects.Zeitgeist };
|
159
|
+
Effects.AudioNamed = { StereoTool: Effects.StereoTool, Delay: Effects.Delay, Reverb: Effects.Reverb, Revamp: Effects.Revamp, Modular: Effects.Modular };
|
160
|
+
Effects.MidiList = Object.values(Effects.MidiNamed);
|
161
|
+
Effects.AudioList = Object.values(Effects.AudioNamed);
|
162
|
+
Effects.MergedNamed = { ...Effects.MidiNamed, ...Effects.AudioNamed };
|
163
|
+
})(Effects || (Effects = {}));
|
@@ -0,0 +1,13 @@
|
|
1
|
+
import { EffectPointerType, IconSymbol } from "@opendaw/studio-adapters";
|
2
|
+
import { Box, Field } from "@opendaw/lib-box";
|
3
|
+
import { int } from "@opendaw/lib-std";
|
4
|
+
import { Project } from "./Project";
|
5
|
+
export interface EffectFactory {
|
6
|
+
get defaultName(): string;
|
7
|
+
get defaultIcon(): IconSymbol;
|
8
|
+
get description(): string;
|
9
|
+
get separatorBefore(): boolean;
|
10
|
+
get type(): "audio" | "midi";
|
11
|
+
create(project: Project, unit: Field<EffectPointerType>, index: int): Box;
|
12
|
+
}
|
13
|
+
//# sourceMappingURL=EffectFactory.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"EffectFactory.d.ts","sourceRoot":"","sources":["../src/EffectFactory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,iBAAiB,EAAE,UAAU,EAAC,MAAM,0BAA0B,CAAA;AACtE,OAAO,EAAC,GAAG,EAAE,KAAK,EAAC,MAAM,kBAAkB,CAAA;AAC3C,OAAO,EAAC,GAAG,EAAC,MAAM,kBAAkB,CAAA;AACpC,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAA;AAEjC,MAAM,WAAW,aAAa;IAC1B,IAAI,WAAW,IAAI,MAAM,CAAA;IACzB,IAAI,WAAW,IAAI,UAAU,CAAA;IAC7B,IAAI,WAAW,IAAI,MAAM,CAAA;IACzB,IAAI,eAAe,IAAI,OAAO,CAAA;IAC9B,IAAI,IAAI,IAAI,OAAO,GAAG,MAAM,CAAA;IAE5B,MAAM,CAAC,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,KAAK,CAAC,iBAAiB,CAAC,EAAE,KAAK,EAAE,GAAG,GAAG,GAAG,CAAA;CAC5E"}
|
@@ -0,0 +1 @@
|
|
1
|
+
export {};
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"InstrumentBox.d.ts","sourceRoot":"","sources":["../src/InstrumentBox.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,aAAa,EAAE,kBAAkB,EAAE,aAAa,EAAE,qBAAqB,EAAC,MAAM,uBAAuB,CAAA;AAE7G,MAAM,MAAM,aAAa,GAAG,aAAa,GAAG,qBAAqB,GAAG,aAAa,GAAG,kBAAkB,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
export {};
|
@@ -0,0 +1,15 @@
|
|
1
|
+
import { InstrumentFactory } from "./InstrumentFactory";
|
2
|
+
export declare namespace InstrumentFactories {
|
3
|
+
const Tape: InstrumentFactory;
|
4
|
+
const Nano: InstrumentFactory;
|
5
|
+
const Playfield: InstrumentFactory;
|
6
|
+
const Vaporisateur: InstrumentFactory;
|
7
|
+
const Named: {
|
8
|
+
Vaporisateur: InstrumentFactory;
|
9
|
+
Playfield: InstrumentFactory;
|
10
|
+
Nano: InstrumentFactory;
|
11
|
+
Tape: InstrumentFactory;
|
12
|
+
};
|
13
|
+
type Keys = keyof typeof Named;
|
14
|
+
}
|
15
|
+
//# sourceMappingURL=InstrumentFactories.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"InstrumentFactories.d.ts","sourceRoot":"","sources":["../src/InstrumentFactories.ts"],"names":[],"mappings":"AAaA,OAAO,EAAC,iBAAiB,EAAC,MAAM,qBAAqB,CAAA;AAErD,yBAAiB,mBAAmB,CAAC;IAC1B,MAAM,IAAI,EAAE,iBAelB,CAAA;IAEM,MAAM,IAAI,EAAE,iBAkBlB,CAAA;IAEM,MAAM,SAAS,EAAE,iBAiCvB,CAAA;IAEM,MAAM,YAAY,EAAE,iBAiB1B,CAAA;IAEM,MAAM,KAAK;;;;;KAAwC,CAAA;IAC1D,KAAY,IAAI,GAAG,MAAM,OAAO,KAAK,CAAA;CAMxC"}
|
@@ -1,20 +1,15 @@
|
|
1
|
-
import { AudioFileBox, NanoDeviceBox, PlayfieldDeviceBox, PlayfieldSampleBox, TapeDeviceBox,
|
2
|
-
import {
|
1
|
+
import { AudioFileBox, NanoDeviceBox, PlayfieldDeviceBox, PlayfieldSampleBox, TapeDeviceBox, VaporisateurDeviceBox } from "@opendaw/studio-boxes";
|
2
|
+
import { UUID } from "@opendaw/lib-std";
|
3
3
|
import { Waveform } from "@opendaw/lib-dsp";
|
4
|
-
import {
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
(function (Instruments) {
|
9
|
-
const useFile = (boxGraph, fileUUID, name) => boxGraph.findBox(fileUUID)
|
10
|
-
.unwrapOrElse(() => AudioFileBox.create(boxGraph, fileUUID, box => {
|
11
|
-
box.fileName.setValue(name);
|
12
|
-
}));
|
13
|
-
Instruments.Tape = {
|
4
|
+
import { IconSymbol, TrackType } from "@opendaw/studio-adapters";
|
5
|
+
export var InstrumentFactories;
|
6
|
+
(function (InstrumentFactories) {
|
7
|
+
InstrumentFactories.Tape = {
|
14
8
|
defaultName: "Tape",
|
15
|
-
|
9
|
+
defaultIcon: IconSymbol.Tape,
|
16
10
|
description: "Plays audio regions & clips",
|
17
|
-
|
11
|
+
trackType: TrackType.Audio,
|
12
|
+
create: (boxGraph, deviceHost, name, icon) => TapeDeviceBox.create(boxGraph, UUID.generate(), box => {
|
18
13
|
box.label.setValue(name);
|
19
14
|
box.icon.setValue(IconSymbol.toName(icon));
|
20
15
|
box.flutter.setValue(0.2);
|
@@ -22,19 +17,14 @@ export var Instruments;
|
|
22
17
|
box.noise.setValue(0.02);
|
23
18
|
box.saturation.setValue(0.5);
|
24
19
|
box.host.refer(deviceHost.inputField);
|
25
|
-
}),
|
26
|
-
createTrack: (boxGraph, deviceHost) => TrackBox.create(boxGraph, UUID.generate(), box => {
|
27
|
-
box.index.setValue(0);
|
28
|
-
box.type.setValue(TrackType.Audio);
|
29
|
-
box.tracks.refer(deviceHost.tracksField);
|
30
|
-
box.target.refer(deviceHost.audioUnitBoxAdapter().box);
|
31
20
|
})
|
32
21
|
};
|
33
|
-
|
22
|
+
InstrumentFactories.Nano = {
|
34
23
|
defaultName: "Nano",
|
35
|
-
|
36
|
-
description: "Simple
|
37
|
-
|
24
|
+
defaultIcon: IconSymbol.NanoWave,
|
25
|
+
description: "Simple sampler",
|
26
|
+
trackType: TrackType.Notes,
|
27
|
+
create: (boxGraph, deviceHost, name, icon) => {
|
38
28
|
const fileUUID = UUID.parse("c1678daa-4a47-4cba-b88f-4f4e384663c3");
|
39
29
|
const audioFileBox = boxGraph.findBox(fileUUID)
|
40
30
|
.unwrapOrElse(() => AudioFileBox.create(boxGraph, fileUUID, box => {
|
@@ -46,19 +36,14 @@ export var Instruments;
|
|
46
36
|
box.file.refer(audioFileBox);
|
47
37
|
box.host.refer(deviceHost.inputField);
|
48
38
|
});
|
49
|
-
}
|
50
|
-
createTrack: (boxGraph, deviceHost) => TrackBox.create(boxGraph, UUID.generate(), box => {
|
51
|
-
box.index.setValue(0);
|
52
|
-
box.type.setValue(TrackType.Notes);
|
53
|
-
box.tracks.refer(deviceHost.tracksField);
|
54
|
-
box.target.refer(deviceHost.audioUnitBoxAdapter().box);
|
55
|
-
})
|
39
|
+
}
|
56
40
|
};
|
57
|
-
|
41
|
+
InstrumentFactories.Playfield = {
|
58
42
|
defaultName: "Playfield",
|
59
|
-
|
60
|
-
description: "
|
61
|
-
|
43
|
+
defaultIcon: IconSymbol.Playfield,
|
44
|
+
description: "Drum computer",
|
45
|
+
trackType: TrackType.Notes,
|
46
|
+
create: (boxGraph, deviceHost, name, icon) => {
|
62
47
|
const deviceBox = PlayfieldDeviceBox.create(boxGraph, UUID.generate(), box => {
|
63
48
|
box.label.setValue(name);
|
64
49
|
box.icon.setValue(IconSymbol.toName(icon));
|
@@ -85,19 +70,14 @@ export var Instruments;
|
|
85
70
|
samples[7].exclude.setValue(true);
|
86
71
|
samples[8].exclude.setValue(true);
|
87
72
|
return deviceBox;
|
88
|
-
}
|
89
|
-
createTrack: (boxGraph, deviceHost) => TrackBox.create(boxGraph, UUID.generate(), box => {
|
90
|
-
box.index.setValue(0);
|
91
|
-
box.type.setValue(TrackType.Notes);
|
92
|
-
box.tracks.refer(deviceHost.tracksField);
|
93
|
-
box.target.refer(deviceHost.audioUnitBoxAdapter().box);
|
94
|
-
})
|
73
|
+
}
|
95
74
|
};
|
96
|
-
|
75
|
+
InstrumentFactories.Vaporisateur = {
|
97
76
|
defaultName: "Vaporisateur",
|
98
|
-
|
77
|
+
defaultIcon: IconSymbol.Piano,
|
99
78
|
description: "Classic subtractive synthesizer",
|
100
|
-
|
79
|
+
trackType: TrackType.Notes,
|
80
|
+
create: (boxGraph, deviceHost, name, icon) => VaporisateurDeviceBox.create(boxGraph, UUID.generate(), box => {
|
101
81
|
box.label.setValue(name);
|
102
82
|
box.icon.setValue(IconSymbol.toName(icon));
|
103
83
|
box.tune.setInitValue(0.0);
|
@@ -107,29 +87,11 @@ export var Instruments;
|
|
107
87
|
box.release.setInitValue(0.1);
|
108
88
|
box.waveform.setInitValue(Waveform.sine);
|
109
89
|
box.host.refer(deviceHost.inputField);
|
110
|
-
}),
|
111
|
-
createTrack: (boxGraph, deviceHost) => TrackBox.create(boxGraph, UUID.generate(), box => {
|
112
|
-
box.index.setValue(0);
|
113
|
-
box.type.setValue(TrackType.Notes);
|
114
|
-
box.tracks.refer(deviceHost.tracksField);
|
115
|
-
box.target.refer(deviceHost.audioUnitBoxAdapter().box);
|
116
90
|
})
|
117
91
|
};
|
118
|
-
|
119
|
-
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
}));
|
125
|
-
const audioUnitBox = Modifier.createAudioUnit(project, AudioUnitType.Instrument);
|
126
|
-
const audioUnitBoxAdapter = boxAdapters.adapterFor(audioUnitBox, AudioUnitBoxAdapter);
|
127
|
-
const uniqueName = Strings.getUniqueName(existingNames, name ?? factory.defaultName);
|
128
|
-
const iconSymbol = icon ?? factory.icon;
|
129
|
-
const device = factory.createDevice(boxGraph, audioUnitBoxAdapter, uniqueName, iconSymbol);
|
130
|
-
const track = factory.createTrack(boxGraph, audioUnitBoxAdapter);
|
131
|
-
userEditingManager.audioUnit.edit(audioUnitBox.editing);
|
132
|
-
return { device, track };
|
133
|
-
};
|
134
|
-
Instruments.Named = { Vaporisateur: Instruments.Vaporisateur, Playfield: Instruments.Playfield, Nano: Instruments.Nano, Tape: Instruments.Tape };
|
135
|
-
})(Instruments || (Instruments = {}));
|
92
|
+
InstrumentFactories.Named = { Vaporisateur: InstrumentFactories.Vaporisateur, Playfield: InstrumentFactories.Playfield, Nano: InstrumentFactories.Nano, Tape: InstrumentFactories.Tape };
|
93
|
+
const useFile = (boxGraph, fileUUID, name) => boxGraph.findBox(fileUUID)
|
94
|
+
.unwrapOrElse(() => AudioFileBox.create(boxGraph, fileUUID, box => {
|
95
|
+
box.fileName.setValue(name);
|
96
|
+
}));
|
97
|
+
})(InstrumentFactories || (InstrumentFactories = {}));
|
@@ -0,0 +1,11 @@
|
|
1
|
+
import { DeviceHost, IconSymbol, TrackType } from "@opendaw/studio-adapters";
|
2
|
+
import { BoxGraph } from "@opendaw/lib-box";
|
3
|
+
import { InstrumentBox } from "./InstrumentBox";
|
4
|
+
export interface InstrumentFactory {
|
5
|
+
defaultName: string;
|
6
|
+
defaultIcon: IconSymbol;
|
7
|
+
description: string;
|
8
|
+
trackType: TrackType;
|
9
|
+
create: (boxGraph: BoxGraph, deviceHost: DeviceHost, name: string, icon: IconSymbol) => InstrumentBox;
|
10
|
+
}
|
11
|
+
//# sourceMappingURL=InstrumentFactory.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"InstrumentFactory.d.ts","sourceRoot":"","sources":["../src/InstrumentFactory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,UAAU,EAAE,UAAU,EAAE,SAAS,EAAC,MAAM,0BAA0B,CAAA;AAC1E,OAAO,EAAC,QAAQ,EAAC,MAAM,kBAAkB,CAAA;AAEzC,OAAO,EAAC,aAAa,EAAC,MAAM,iBAAiB,CAAA;AAE7C,MAAM,WAAW,iBAAiB;IAC9B,WAAW,EAAE,MAAM,CAAA;IACnB,WAAW,EAAE,UAAU,CAAA;IACvB,WAAW,EAAE,MAAM,CAAA;IACnB,SAAS,EAAE,SAAS,CAAA;IACpB,MAAM,EAAE,CAAC,QAAQ,EAAE,QAAQ,EAAE,UAAU,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,UAAU,KAAK,aAAa,CAAA;CACxG"}
|
@@ -0,0 +1 @@
|
|
1
|
+
export {};
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"InstrumentOptions.d.ts","sourceRoot":"","sources":["../src/InstrumentOptions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,UAAU,EAAC,MAAM,0BAA0B,CAAA;AACnD,OAAO,EAAC,GAAG,EAAC,MAAM,kBAAkB,CAAA;AAEpC,MAAM,MAAM,iBAAiB,GAAG;IAAE,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,UAAU,CAAC;IAAC,KAAK,CAAC,EAAE,GAAG,CAAA;CAAE,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
export {};
|
@@ -0,0 +1,8 @@
|
|
1
|
+
import { AudioUnitBox, TrackBox } from "@opendaw/studio-boxes";
|
2
|
+
import { InstrumentBox } from "./InstrumentBox";
|
3
|
+
export type InstrumentProduct = {
|
4
|
+
audioUnitBox: AudioUnitBox;
|
5
|
+
instrumentBox: InstrumentBox;
|
6
|
+
trackBox: TrackBox;
|
7
|
+
};
|
8
|
+
//# sourceMappingURL=InstrumentProduct.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"InstrumentProduct.d.ts","sourceRoot":"","sources":["../src/InstrumentProduct.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,YAAY,EAAE,QAAQ,EAAC,MAAM,uBAAuB,CAAA;AAE5D,OAAO,EAAC,aAAa,EAAC,MAAM,iBAAiB,CAAA;AAE7C,MAAM,MAAM,iBAAiB,GAAG;IAC5B,YAAY,EAAE,YAAY,CAAA;IAC1B,aAAa,EAAE,aAAa,CAAA;IAC5B,QAAQ,EAAE,QAAQ,CAAA;CACrB,CAAA"}
|
@@ -0,0 +1 @@
|
|
1
|
+
export {};
|
package/dist/Project.d.ts
CHANGED
@@ -1,10 +1,11 @@
|
|
1
1
|
import { Terminable, TerminableOwner, Terminator } from "@opendaw/lib-std";
|
2
2
|
import { BoxGraph, Editing } from "@opendaw/lib-box";
|
3
3
|
import { AudioBusBox, AudioUnitBox, BoxIO, RootBox, TimelineBox, UserInterfaceBox } from "@opendaw/studio-boxes";
|
4
|
-
import {
|
4
|
+
import { BoxAdapters, BoxAdaptersContext, ClipSequencing, ParameterFieldAdapters, RootBoxAdapter, SampleManager, TimelineBoxAdapter, UserEditingManager, VertexSelection } from "@opendaw/studio-adapters";
|
5
5
|
import { LiveStreamBroadcaster, LiveStreamReceiver } from "@opendaw/lib-fusion";
|
6
6
|
import { ProjectEnv } from "./ProjectEnv";
|
7
7
|
import { Mixer } from "./Mixer";
|
8
|
+
import { ProjectApi } from "./ProjectApi";
|
8
9
|
export declare class Project implements BoxAdaptersContext, Terminable, TerminableOwner {
|
9
10
|
#private;
|
10
11
|
static new(env: ProjectEnv): Project;
|
@@ -15,6 +16,7 @@ export declare class Project implements BoxAdaptersContext, Terminable, Terminab
|
|
15
16
|
readonly masterBusBox: AudioBusBox;
|
16
17
|
readonly masterAudioUnit: AudioUnitBox;
|
17
18
|
readonly timelineBox: TimelineBox;
|
19
|
+
readonly api: ProjectApi;
|
18
20
|
readonly editing: Editing;
|
19
21
|
readonly selection: VertexSelection;
|
20
22
|
readonly boxAdapters: BoxAdapters;
|
package/dist/Project.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Project.d.ts","sourceRoot":"","sources":["../src/Project.ts"],"names":[],"mappings":"AAAA,OAAO,
|
1
|
+
{"version":3,"file":"Project.d.ts","sourceRoot":"","sources":["../src/Project.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiC,UAAU,EAAE,eAAe,EAAE,UAAU,EAAO,MAAM,kBAAkB,CAAA;AAC9G,OAAO,EAAC,QAAQ,EAAE,OAAO,EAAC,MAAM,kBAAkB,CAAA;AAClD,OAAO,EACH,WAAW,EACX,YAAY,EACZ,KAAK,EAEL,OAAO,EACP,WAAW,EACX,gBAAgB,EACnB,MAAM,uBAAuB,CAAA;AAC9B,OAAO,EACH,WAAW,EACX,kBAAkB,EAClB,cAAc,EAGd,sBAAsB,EAEtB,cAAc,EACd,aAAa,EACb,kBAAkB,EAClB,kBAAkB,EAClB,eAAe,EAClB,MAAM,0BAA0B,CAAA;AACjC,OAAO,EAAC,qBAAqB,EAAE,kBAAkB,EAAC,MAAM,qBAAqB,CAAA;AAE7E,OAAO,EAAC,UAAU,EAAC,MAAM,cAAc,CAAA;AACvC,OAAO,EAAC,KAAK,EAAC,MAAM,SAAS,CAAA;AAC7B,OAAO,EAAC,UAAU,EAAC,MAAM,cAAc,CAAA;AAKvC,qBAAa,OAAQ,YAAW,kBAAkB,EAAE,UAAU,EAAE,eAAe;;IAC3E,MAAM,CAAC,GAAG,CAAC,GAAG,EAAE,UAAU,GAAG,OAAO;IAuCpC,MAAM,CAAC,IAAI,CAAC,GAAG,EAAE,UAAU,EAAE,WAAW,EAAE,WAAW,GAAG,OAAO;IAS/D,QAAQ,CAAC,QAAQ,EAAE,QAAQ,CAAC,KAAK,CAAC,OAAO,CAAC,CAAA;IAE1C,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAA;IACzB,QAAQ,CAAC,gBAAgB,EAAE,gBAAgB,CAAA;IAC3C,QAAQ,CAAC,YAAY,EAAE,WAAW,CAAA;IAClC,QAAQ,CAAC,eAAe,EAAE,YAAY,CAAA;IACtC,QAAQ,CAAC,WAAW,EAAE,WAAW,CAAA;IAEjC,QAAQ,CAAC,GAAG,EAAE,UAAU,CAAA;IACxB,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAA;IACzB,QAAQ,CAAC,SAAS,EAAE,eAAe,CAAA;IACnC,QAAQ,CAAC,WAAW,EAAE,WAAW,CAAA;IACjC,QAAQ,CAAC,kBAAkB,EAAE,kBAAkB,CAAA;IAC/C,QAAQ,CAAC,sBAAsB,EAAE,sBAAsB,CAAA;IACvD,QAAQ,CAAC,kBAAkB,EAAE,kBAAkB,CAAA;IAC/C,QAAQ,CAAC,KAAK,EAAE,KAAK,CAAA;IAErB,OAAO;IA8BP,GAAG,CAAC,CAAC,SAAS,UAAU,EAAE,UAAU,EAAE,CAAC,GAAG,CAAC;IAC3C,MAAM,CAAC,CAAC,SAAS,UAAU,EAAE,GAAG,WAAW,EAAE,KAAK,CAAC,CAAC,CAAC,GAAG,IAAI;IAC5D,KAAK,IAAI,UAAU;IAEnB,IAAI,GAAG,IAAI,MAAM,CAAyC;IAC1D,IAAI,cAAc,IAAI,cAAc,CAAmE;IACvG,IAAI,kBAAkB,IAAI,kBAAkB,CAA2E;IACvH,IAAI,YAAY,IAAI,aAAa,CAAiC;IAClE,IAAI,cAAc,IAAI,cAAc,CAAkD;IACtF,IAAI,cAAc,IAAI,OAAO,CAAe;IAC5C,IAAI,YAAY,IAAI,OAAO,CAAc;IACzC,IAAI,qBAAqB,IAAI,qBAAqB,CAAkD;IAEpG,aAAa,IAAI,eAAe;IAiBhC,IAAI,IAAI,OAAO;IAEf,SAAS,IAAI,IAAI;CACpB"}
|
package/dist/Project.js
CHANGED
@@ -1,10 +1,12 @@
|
|
1
|
-
import {
|
1
|
+
import { ByteArrayOutput, Option, panic, Terminator, UUID } from "@opendaw/lib-std";
|
2
2
|
import { BoxGraph, Editing } from "@opendaw/lib-box";
|
3
|
-
import { AudioBusBox, AudioUnitBox, BoxIO, GrooveShuffleBox, RootBox, TimelineBox, UserInterfaceBox
|
3
|
+
import { AudioBusBox, AudioUnitBox, BoxIO, GrooveShuffleBox, RootBox, TimelineBox, UserInterfaceBox } from "@opendaw/studio-boxes";
|
4
4
|
import { BoxAdapters, IconSymbol, ParameterFieldAdapters, ProjectDecoder, RootBoxAdapter, TimelineBoxAdapter, UserEditingManager, VertexSelection } from "@opendaw/studio-adapters";
|
5
5
|
import { LiveStreamReceiver } from "@opendaw/lib-fusion";
|
6
6
|
import { AudioUnitType } from "@opendaw/studio-enums";
|
7
7
|
import { Mixer } from "./Mixer";
|
8
|
+
import { ProjectApi } from "./ProjectApi";
|
9
|
+
import { ProjectMigration } from "./ProjectMigration";
|
8
10
|
// Main Entry Point for a Project
|
9
11
|
//
|
10
12
|
export class Project {
|
@@ -48,65 +50,9 @@ export class Project {
|
|
48
50
|
}
|
49
51
|
static load(env, arrayBuffer) {
|
50
52
|
const skeleton = ProjectDecoder.decode(arrayBuffer);
|
51
|
-
|
53
|
+
ProjectMigration.migrate(skeleton);
|
52
54
|
return new Project(env, skeleton.boxGraph, skeleton.mandatoryBoxes);
|
53
55
|
}
|
54
|
-
static #migrate({ boxGraph, mandatoryBoxes }) {
|
55
|
-
const { rootBox } = mandatoryBoxes;
|
56
|
-
if (rootBox.groove.targetAddress.isEmpty()) {
|
57
|
-
console.debug("Migrate to global GrooveShuffleBox");
|
58
|
-
boxGraph.beginTransaction();
|
59
|
-
rootBox.groove.refer(GrooveShuffleBox.create(boxGraph, UUID.generate()));
|
60
|
-
boxGraph.endTransaction();
|
61
|
-
}
|
62
|
-
const globalShuffle = asInstanceOf(rootBox.groove.targetVertex.unwrap(), GrooveShuffleBox).label;
|
63
|
-
if (globalShuffle.getValue() !== "Groove Shuffle") {
|
64
|
-
boxGraph.beginTransaction();
|
65
|
-
globalShuffle.setValue("Groove Shuffle");
|
66
|
-
boxGraph.endTransaction();
|
67
|
-
}
|
68
|
-
// TODO We can remove this when we delete all not-migrated, local(!) project files from my machine
|
69
|
-
boxGraph.boxes().forEach(box => box.accept({
|
70
|
-
visitZeitgeistDeviceBox: (box) => {
|
71
|
-
if (box.groove.targetAddress.isEmpty()) {
|
72
|
-
console.debug("Migrate 'ZeitgeistDeviceBox' to GrooveShuffleBox");
|
73
|
-
boxGraph.beginTransaction();
|
74
|
-
box.groove.refer(rootBox.groove.targetVertex.unwrap());
|
75
|
-
boxGraph.endTransaction();
|
76
|
-
}
|
77
|
-
},
|
78
|
-
visitValueEventBox: (eventBox) => {
|
79
|
-
const slope = eventBox.slope.getValue();
|
80
|
-
if (isNaN(slope)) {
|
81
|
-
return;
|
82
|
-
} // already migrated, nothing to do
|
83
|
-
if (slope === 0.0) { // never set
|
84
|
-
console.debug("Migrate 'ValueEventBox'");
|
85
|
-
boxGraph.beginTransaction();
|
86
|
-
eventBox.slope.setValue(NaN);
|
87
|
-
boxGraph.endTransaction();
|
88
|
-
}
|
89
|
-
else if (eventBox.interpolation.getValue() === 1) { // linear
|
90
|
-
if (slope === 0.5) {
|
91
|
-
console.debug("Migrate 'ValueEventBox' to linear");
|
92
|
-
boxGraph.beginTransaction();
|
93
|
-
eventBox.slope.setValue(NaN);
|
94
|
-
boxGraph.endTransaction();
|
95
|
-
}
|
96
|
-
else {
|
97
|
-
console.debug("Migrate 'ValueEventBox' to new ValueEventCurveBox");
|
98
|
-
boxGraph.beginTransaction();
|
99
|
-
ValueEventCurveBox.create(boxGraph, UUID.generate(), box => {
|
100
|
-
box.event.refer(eventBox.interpolation);
|
101
|
-
box.slope.setValue(slope);
|
102
|
-
});
|
103
|
-
eventBox.slope.setValue(NaN);
|
104
|
-
boxGraph.endTransaction();
|
105
|
-
}
|
106
|
-
}
|
107
|
-
}
|
108
|
-
}));
|
109
|
-
}
|
110
56
|
#terminator = new Terminator();
|
111
57
|
#env;
|
112
58
|
boxGraph;
|
@@ -115,6 +61,7 @@ export class Project {
|
|
115
61
|
masterBusBox;
|
116
62
|
masterAudioUnit;
|
117
63
|
timelineBox;
|
64
|
+
api;
|
118
65
|
editing;
|
119
66
|
selection;
|
120
67
|
boxAdapters;
|
@@ -131,6 +78,7 @@ export class Project {
|
|
131
78
|
this.masterAudioUnit = masterAudioUnit;
|
132
79
|
this.timelineBox = timelineBox;
|
133
80
|
this.liveStreamReceiver = this.#terminator.own(new LiveStreamReceiver());
|
81
|
+
this.api = new ProjectApi(this);
|
134
82
|
this.editing = new Editing(this.boxGraph);
|
135
83
|
this.selection = new VertexSelection(this.editing, this.boxGraph);
|
136
84
|
this.parameterFieldAdapters = new ParameterFieldAdapters();
|
@@ -0,0 +1,44 @@
|
|
1
|
+
import { float, int, Option } from "@opendaw/lib-std";
|
2
|
+
import { AudioUnitType } from "@opendaw/studio-enums";
|
3
|
+
import { AudioBusBox, NoteClipBox, NoteRegionBox, TrackBox, ValueRegionBox } from "@opendaw/studio-boxes";
|
4
|
+
import { AnyClipBox, AudioUnitBoxAdapter, DeviceHost, IconSymbol, NoteEventBoxAdapter } from "@opendaw/studio-adapters";
|
5
|
+
import { Project } from "./Project";
|
6
|
+
import { InstrumentFactory } from "./InstrumentFactory";
|
7
|
+
import { InstrumentProduct } from "./InstrumentProduct";
|
8
|
+
import { InstrumentOptions } from "./InstrumentOptions";
|
9
|
+
import { EffectFactory } from "./EffectFactory";
|
10
|
+
import { ppqn } from "@opendaw/lib-dsp";
|
11
|
+
export type ClipRegionOptions = {
|
12
|
+
name?: string;
|
13
|
+
hue?: number;
|
14
|
+
};
|
15
|
+
export type NoteEventParams = {
|
16
|
+
owner: NoteRegionBox | NoteClipBox;
|
17
|
+
position: ppqn;
|
18
|
+
duration: ppqn;
|
19
|
+
pitch: int;
|
20
|
+
cent?: number;
|
21
|
+
velocity?: float;
|
22
|
+
chance?: int;
|
23
|
+
};
|
24
|
+
export declare class ProjectApi {
|
25
|
+
#private;
|
26
|
+
static readonly AudioUnitOrdering: {
|
27
|
+
readonly instrument: 0;
|
28
|
+
readonly aux: 1;
|
29
|
+
readonly bus: 2;
|
30
|
+
readonly output: 3;
|
31
|
+
};
|
32
|
+
constructor(project: Project);
|
33
|
+
createInstrument({ create, defaultIcon, defaultName, trackType }: InstrumentFactory, { name, icon, index }?: InstrumentOptions): InstrumentProduct;
|
34
|
+
createEffect(host: DeviceHost, factory: EffectFactory, newIndex: int): import("@opendaw/lib-box").Box<import("@opendaw/lib-box").PointerTypes, any>;
|
35
|
+
createAudioBus(name: string, icon: IconSymbol, type: AudioUnitType, color: string): AudioBusBox;
|
36
|
+
createNoteTrack(adapter: AudioUnitBoxAdapter, index?: int): TrackBox;
|
37
|
+
createAudioTrack(adapter: AudioUnitBoxAdapter, index?: int): TrackBox;
|
38
|
+
createAutomationTrack(adapter: AudioUnitBoxAdapter, index?: int): TrackBox;
|
39
|
+
createClip(trackBox: TrackBox, clipIndex: int, { name, hue }?: ClipRegionOptions): Option<AnyClipBox>;
|
40
|
+
createRegion(trackBox: TrackBox, position: ppqn, duration: ppqn, { name, hue }?: ClipRegionOptions): Option<NoteRegionBox> | Option<ValueRegionBox>;
|
41
|
+
createNoteEvent({ owner, position, duration, velocity, pitch, chance, cent }: NoteEventParams): NoteEventBoxAdapter;
|
42
|
+
deleteAudioUnit(adapter: AudioUnitBoxAdapter): void;
|
43
|
+
}
|
44
|
+
//# sourceMappingURL=ProjectApi.d.ts.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"ProjectApi.d.ts","sourceRoot":"","sources":["../src/ProjectApi.ts"],"names":[],"mappings":"AAAA,OAAO,EAAS,KAAK,EAAE,GAAG,EAAE,MAAM,EAAuB,MAAM,kBAAkB,CAAA;AAEjF,OAAO,EAAC,aAAa,EAAC,MAAM,uBAAuB,CAAA;AACnD,OAAO,EACH,WAAW,EAEX,WAAW,EAGX,aAAa,EACb,QAAQ,EAGR,cAAc,EACjB,MAAM,uBAAuB,CAAA;AAC9B,OAAO,EACH,UAAU,EACV,mBAAmB,EACnB,UAAU,EAGV,UAAU,EACV,mBAAmB,EAGtB,MAAM,0BAA0B,CAAA;AACjC,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAA;AACjC,OAAO,EAAC,iBAAiB,EAAC,MAAM,qBAAqB,CAAA;AACrD,OAAO,EAAC,iBAAiB,EAAC,MAAM,qBAAqB,CAAA;AACrD,OAAO,EAAC,iBAAiB,EAAC,MAAM,qBAAqB,CAAA;AACrD,OAAO,EAAC,aAAa,EAAC,MAAM,iBAAiB,CAAA;AAE7C,OAAO,EAAC,IAAI,EAAO,MAAM,kBAAkB,CAAA;AAE3C,MAAM,MAAM,iBAAiB,GAAG;IAC5B,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,GAAG,CAAC,EAAE,MAAM,CAAA;CACf,CAAA;AAED,MAAM,MAAM,eAAe,GAAG;IAC1B,KAAK,EAAE,aAAa,GAAG,WAAW,CAAA;IAClC,QAAQ,EAAE,IAAI,CAAA;IACd,QAAQ,EAAE,IAAI,CAAA;IACd,KAAK,EAAE,GAAG,CAAA;IACV,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE,KAAK,CAAA;IAChB,MAAM,CAAC,EAAE,GAAG,CAAA;CACf,CAAA;AAED,qBAAa,UAAU;;IACnB,MAAM,CAAC,QAAQ,CAAC,iBAAiB;;;;;MAKvB;gBAIE,OAAO,EAAE,OAAO;IAE5B,gBAAgB,CAAC,EAAC,MAAM,EAAE,WAAW,EAAE,WAAW,EAAE,SAAS,EAAC,EAAE,iBAAiB,EAChE,EAAC,IAAI,EAAE,IAAI,EAAE,KAAK,EAAC,GAAE,iBAAsB,GAAG,iBAAiB;IAsBhF,YAAY,CAAC,IAAI,EAAE,UAAU,EAAE,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,GAAG;IAmBpE,cAAc,CAAC,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,UAAU,EAChB,IAAI,EAAE,aAAa,EACnB,KAAK,EAAE,MAAM,GAAG,WAAW;IAsB1C,eAAe,CAAC,OAAO,EAAE,mBAAmB,EAAE,KAAK,GAAE,GAAO,GAAG,QAAQ;IAIvE,gBAAgB,CAAC,OAAO,EAAE,mBAAmB,EAAE,KAAK,GAAE,GAAO,GAAG,QAAQ;IAIxE,qBAAqB,CAAC,OAAO,EAAE,mBAAmB,EAAE,KAAK,GAAE,GAAO,GAAG,QAAQ;IAI7E,UAAU,CAAC,QAAQ,EAAE,QAAQ,EAAE,SAAS,EAAE,GAAG,EAAE,EAAC,IAAI,EAAE,GAAG,EAAC,GAAE,iBAAsB,GAAG,MAAM,CAAC,UAAU,CAAC;IAgCvG,YAAY,CAAC,QAAQ,EAAE,QAAQ,EAAE,QAAQ,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,EAAC,IAAI,EAAE,GAAG,EAAC,GAAE,iBAAsB;IAkCpG,eAAe,CAAC,EAAC,KAAK,EAAE,QAAQ,EAAE,QAAQ,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAC,EAAE,eAAe,GAAG,mBAAmB;IAejH,eAAe,CAAC,OAAO,EAAE,mBAAmB,GAAG,IAAI;CAmDtD"}
|