InstrumentCompositeLayer
interface InstrumentCompositeLayer extends MIDIEffectHost, AudioEffectHost {
midiEffects: readonly AnyMIDIEffect[]
audioEffects: readonly AnyAudioEffect[]
uuid: string
composite: InstrumentComposite
index: number
instrument: Vaporisateur | Playfield | Nano | Soundfont | Neon | Tubular | Cubed | Apparat | InstrumentComposite
gain: number
pan: number
mute: boolean
solo: boolean
minimized: boolean
addMIDIEffect<K extends keyof MIDIEffects>(key: K, props?: DeepPartial<MIDIEffects[K]>, index?: number): MIDIEffects[K]
addAudioEffect<K extends keyof AudioEffects>(key: K, props?: DeepPartial<AudioEffects[K]>, index?: number): AudioEffects[K]
setInstrument<K extends 'Vaporisateur' | 'Playfield' | 'Nano' | 'Soundfont' | 'Neon' | 'Tubular' | 'Cubed' | 'Apparat' | 'InstrumentComposite'>(key: K, props?: DeepPartial<LayerInstruments[K]>): LayerInstruments[K]
remove(): void
}One layer of an InstrumentComposite: an instrument with its own MIDI and audio effect chains and its own strip
Hierarchy
Properties
midiEffects: readonly AnyMIDIEffect[]
Inherited from midiEffects
MIDI effects ordered by index
audioEffects: readonly AnyAudioEffect[]
Inherited from audioEffects
Audio effects ordered by index
uuid: string
Unique id
composite: InstrumentComposite
The composite this layer belongs to
- See:
index: number
Position in the composite
instrument: Vaporisateur | Playfield | Nano | Soundfont | Neon | Tubular | Cubed | Apparat | InstrumentComposite
The instrument this layer plays
gain: number
Layer gain in dB (default 0)
pan: number
Pan (-1.0 to 1.0, default 0.0)
mute: boolean
Mute the layer (it keeps running, unmuting is instant)
solo: boolean
Solo the layer
minimized: boolean
Collapse the layer editor
Methods
addMIDIEffect<
K extends keyof MIDIEffects,
>(
key: K,
props?: DeepPartial<MIDIEffects[K]>,
index?: number,
): MIDIEffects[K]
Inherited from addMIDIEffect
Add a MIDI effect
Type Parameters
Kextendskeyof MIDIEffects
Parameters
key(K) — Effect typeprops(DeepPartial<MIDIEffects[K]>, optional) — Initial parameter valuesindex(number, optional) — Insert position (default: end of chain)
Returns
Example
synth.addMIDIEffect("Arpeggio", {rate: 9, octaves: 2})addAudioEffect<
K extends keyof AudioEffects,
>(
key: K,
props?: DeepPartial<AudioEffects[K]>,
index?: number,
): AudioEffects[K]
Inherited from addAudioEffect
Add an audio effect
Type Parameters
Kextendskeyof AudioEffects
Parameters
key(K) — Effect typeprops(DeepPartial<AudioEffects[K]>, optional) — Initial parameter valuesindex(number, optional) — Insert position (default: end of chain)
Returns
Example
synth.addAudioEffect("Delay", {delay: 13, feedback: 0.4, wet: -9})
const composite = synth.addAudioEffect("Composite")
composite.addEntry({label: "Crushed"}).addAudioEffect("Crusher", {bits: 8})setInstrument<
K extends 'Vaporisateur' | 'Playfield' | 'Nano' | 'Soundfont' | 'Neon' | 'Tubular' | 'Cubed' | 'Apparat' | 'InstrumentComposite',
>(
key: K,
props?: DeepPartial<LayerInstruments[K]>,
): LayerInstruments[K]
Replace the layer's instrument. The layer keeps its strip and its effect chains
Type Parameters
Kextends"Vaporisateur" | "Playfield" | "Nano" | "Soundfont" | "Neon" | "Tubular" | "Cubed" | "Apparat" | "InstrumentComposite"
Parameters
key(K) — Instrument typeprops(DeepPartial<LayerInstruments[K]>, optional) — Instrument settings
Returns
- See:
remove(): void
Remove the layer with its instrument and effects
Returns
void