@signalsandsorcery/plugin-sdk 2.35.2 → 2.35.4
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/index.d.mts +149 -5
- package/dist/index.d.ts +149 -5
- package/dist/index.js +959 -658
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +957 -658
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -120,6 +120,38 @@ interface PanelBusState {
|
|
|
120
120
|
/** User FX chain, top-to-bottom (master section excluded). */
|
|
121
121
|
fx: PanelBusFxEntry[];
|
|
122
122
|
}
|
|
123
|
+
/**
|
|
124
|
+
* One third-party (VST3/AU) FX insert on a TRACK's plugin chain, as shown to
|
|
125
|
+
* the panel UI. The track's instrument, the built-in FX-toggle plugins
|
|
126
|
+
* (reverb/delay/eq/…) and the Volume & Pan master section are filtered OUT —
|
|
127
|
+
* this list is only the user's external inserts. Same shape as
|
|
128
|
+
* `PanelBusFxEntry` by design: the drawer and the bus strip share UI idioms.
|
|
129
|
+
* @since SDK 2.39.0
|
|
130
|
+
*/
|
|
131
|
+
interface TrackExternalFxEntry {
|
|
132
|
+
/**
|
|
133
|
+
* ENGINE chain index — pass this back to remove/bypass/editor calls.
|
|
134
|
+
* Not contiguous from 0: the instrument and built-in FX share the chain.
|
|
135
|
+
*/
|
|
136
|
+
index: number;
|
|
137
|
+
/** Scanned plugin id (the picker's `InstrumentDescriptor.pluginId`). */
|
|
138
|
+
pluginId: string;
|
|
139
|
+
/** Display name. */
|
|
140
|
+
name: string;
|
|
141
|
+
/** False when bypassed. */
|
|
142
|
+
enabled: boolean;
|
|
143
|
+
}
|
|
144
|
+
/**
|
|
145
|
+
* Stereo peak levels of a panel bus's OUTPUT (post-FX, post-fader). dBFS,
|
|
146
|
+
* floored at -120 ("no signal"). Drives the strip's stereo meter.
|
|
147
|
+
* @since SDK 2.38.0
|
|
148
|
+
*/
|
|
149
|
+
interface PanelBusLevels {
|
|
150
|
+
leftDb: number;
|
|
151
|
+
rightDb: number;
|
|
152
|
+
/** Latched overload since the last read. */
|
|
153
|
+
clipped: boolean;
|
|
154
|
+
}
|
|
123
155
|
/** Every generator plugin must implement this interface. */
|
|
124
156
|
interface GeneratorPlugin {
|
|
125
157
|
/** Unique ID, npm-style scope: '@sas/synth-generator', '@user/my-plugin' */
|
|
@@ -605,6 +637,16 @@ interface PluginHost {
|
|
|
605
637
|
* picker components consume one type.
|
|
606
638
|
*/
|
|
607
639
|
getAvailableFx?(): Promise<InstrumentDescriptor[]>;
|
|
640
|
+
/**
|
|
641
|
+
* Force a plugin re-scan and return the refreshed FX list. Unlike
|
|
642
|
+
* `getAvailableFx` (served from a cache), this re-walks the plugin
|
|
643
|
+
* directories AND clears the engine's failed-probe blacklist, so a plugin
|
|
644
|
+
* installed mid-session, or one that crashed a previous scan and was
|
|
645
|
+
* blacklisted, reappears without an app restart. Backs the FX picker's
|
|
646
|
+
* "Rescan" button. Slow (20-60s). Absent on pre-2.40 hosts — callers should
|
|
647
|
+
* fall back to `getAvailableFx`. @since SDK 2.40.0
|
|
648
|
+
*/
|
|
649
|
+
rescanAvailableFx?(): Promise<InstrumentDescriptor[]>;
|
|
608
650
|
/**
|
|
609
651
|
* The panel's bus state for a scene. `{ engaged: false, … }` when the
|
|
610
652
|
* panel has no bus there — reading NEVER creates one. When engaged, this
|
|
@@ -614,6 +656,12 @@ interface PluginHost {
|
|
|
614
656
|
* is the panel's whole reload story.
|
|
615
657
|
*/
|
|
616
658
|
getPanelBusState?(sceneId: string): Promise<PanelBusState>;
|
|
659
|
+
/**
|
|
660
|
+
* Stereo output levels for the strip's bus meter (~30 Hz poll). Null when
|
|
661
|
+
* the bus is disengaged/unrealized or the engine is unavailable — render
|
|
662
|
+
* the meter floored. Never engages a bus. @since SDK 2.38.0
|
|
663
|
+
*/
|
|
664
|
+
getPanelBusLevels?(sceneId: string): Promise<PanelBusLevels | null>;
|
|
617
665
|
/** Master fader in dB (engages the bus on first use). */
|
|
618
666
|
setPanelBusVolume?(sceneId: string, volumeDb: number): Promise<void>;
|
|
619
667
|
/** Bus mute — silences the whole panel (multiplies with per-track mutes). */
|
|
@@ -636,6 +684,24 @@ interface PluginHost {
|
|
|
636
684
|
* scene, persisted state deleted. The panel returns to flat routing.
|
|
637
685
|
*/
|
|
638
686
|
disengagePanelBus?(sceneId: string): Promise<void>;
|
|
687
|
+
/**
|
|
688
|
+
* The track's external FX inserts (instrument + built-ins filtered out).
|
|
689
|
+
* Reading also converges persisted state: on the first read of a session
|
|
690
|
+
* the host re-applies saved raw plugin states, and after a `.sasproj`
|
|
691
|
+
* import it rebuilds missing inserts from the persisted blob.
|
|
692
|
+
*/
|
|
693
|
+
getTrackExternalFx?(trackId: string): Promise<TrackExternalFxEntry[]>;
|
|
694
|
+
/**
|
|
695
|
+
* Add an FX plugin (by scanned pluginId, from `getAvailableFx`) to the
|
|
696
|
+
* track's chain, inserted before Volume & Pan. Instruments are rejected.
|
|
697
|
+
*/
|
|
698
|
+
loadTrackExternalFx?(trackId: string, pluginId: string): Promise<TrackExternalFxEntry>;
|
|
699
|
+
/** Remove an external FX by its `TrackExternalFxEntry.index`. */
|
|
700
|
+
removeTrackExternalFx?(trackId: string, fxIndex: number): Promise<void>;
|
|
701
|
+
/** Bypass toggle for an external FX by its `TrackExternalFxEntry.index`. */
|
|
702
|
+
setTrackExternalFxEnabled?(trackId: string, fxIndex: number, enabled: boolean): Promise<void>;
|
|
703
|
+
/** Open the native editor window for an external FX. */
|
|
704
|
+
showTrackExternalFxEditor?(trackId: string, fxIndex: number): Promise<void>;
|
|
639
705
|
/** Subscribe to transport state changes. Returns unsubscribe function. */
|
|
640
706
|
onTransportEvent(listener: TransportEventListener): UnsubscribeFn;
|
|
641
707
|
/** Subscribe to deck boundary events. Returns unsubscribe function. */
|
|
@@ -2354,6 +2420,14 @@ interface TrackDrawerProps {
|
|
|
2354
2420
|
onFxDryWetChange?: (category: FxCategory, value: number) => void;
|
|
2355
2421
|
/** Disable FX controls (e.g. while the track is generating). */
|
|
2356
2422
|
fxDisabled?: boolean;
|
|
2423
|
+
/**
|
|
2424
|
+
* Third-party FX section under the toggle bar (@since SDK 2.39.0): pass the
|
|
2425
|
+
* panel's host and the section manages its own state
|
|
2426
|
+
* (TrackExternalFxSection). Renders nothing on hosts without the surface,
|
|
2427
|
+
* so panels can pass this unconditionally. Omit to keep a built-ins-only
|
|
2428
|
+
* FX tab.
|
|
2429
|
+
*/
|
|
2430
|
+
externalFxHost?: PluginHost;
|
|
2357
2431
|
/** Available instrument plugins from engine scan. */
|
|
2358
2432
|
instruments?: InstrumentDescriptor[];
|
|
2359
2433
|
/** Currently loaded instrument plugin ID (null = default Surge XT). */
|
|
@@ -2395,7 +2469,7 @@ interface TrackDrawerProps {
|
|
|
2395
2469
|
/** Optional single-note preview when the user adds a note. */
|
|
2396
2470
|
onAuditionNote?: (pitch: number, velocity: number, durationMs: number) => void;
|
|
2397
2471
|
}
|
|
2398
|
-
declare function TrackDrawer({ activeTab, onTabChange, trackId, fxState, onFxToggle, onFxPresetChange, onFxDryWetChange, fxDisabled, instruments, currentPluginId, isLoading, onSelect, onRefresh, editorStage, onShowEditor, onBackToInstruments, selectedInstrumentName, soundHistory, soundHistoryCursor, onRestoreSound, onToggleFavorite, onImportSound, importSoundLabel, editNotes, onNotesChange, editBars, editBpm, editSnap, onAuditionNote, }: TrackDrawerProps): React$1.ReactElement;
|
|
2472
|
+
declare function TrackDrawer({ activeTab, onTabChange, trackId, fxState, onFxToggle, onFxPresetChange, onFxDryWetChange, fxDisabled, externalFxHost, instruments, currentPluginId, isLoading, onSelect, onRefresh, editorStage, onShowEditor, onBackToInstruments, selectedInstrumentName, soundHistory, soundHistoryCursor, onRestoreSound, onToggleFavorite, onImportSound, importSoundLabel, editNotes, onNotesChange, editBars, editBpm, editSnap, onAuditionNote, }: TrackDrawerProps): React$1.ReactElement;
|
|
2399
2473
|
|
|
2400
2474
|
/**
|
|
2401
2475
|
* useTrackLevels — drives the cosmetic per-track strip meters.
|
|
@@ -2611,6 +2685,10 @@ interface SDKTrackRowProps {
|
|
|
2611
2685
|
onFxPresetChange?: (cat: FxCategory, idx: number) => void;
|
|
2612
2686
|
/** FX dry/wet */
|
|
2613
2687
|
onFxDryWetChange?: (cat: FxCategory, val: number) => void;
|
|
2688
|
+
/** Third-party FX section in the drawer's FX tab — pass the panel's host
|
|
2689
|
+
* (self-contained; renders nothing on hosts without the surface).
|
|
2690
|
+
* @since SDK 2.39.0 */
|
|
2691
|
+
externalFxHost?: PluginHost;
|
|
2614
2692
|
/** Open/close FX (optional — omit to hide FX button) */
|
|
2615
2693
|
onToggleFxDrawer?: () => void;
|
|
2616
2694
|
/** Progress persistence callback */
|
|
@@ -2670,7 +2748,7 @@ interface SDKTrackRowProps {
|
|
|
2670
2748
|
* a thin peak meter welds to the bottom of the row. Omit to hide it. */
|
|
2671
2749
|
levels?: TrackLevelsHandle;
|
|
2672
2750
|
}
|
|
2673
|
-
declare function TrackRow({ track, prompt, runtimeState, soloedOut, fxDetailState, drawerOpen, drawerTab, onTabChange, isGenerating, isAuthenticated, error, hasMidi, generationProgress, estimatedGenerationMs, onPromptChange, onGenerate, onShuffle, onCopy, onDelete, contentSlot, onMuteToggle, onSoloToggle, onVolumeChange, onPanChange, onFxToggle, onFxPresetChange, onFxDryWetChange, onToggleFxDrawer, onProgressChange, accentColor, instrumentName, instrumentMissing, onToggleDrawer, availableInstruments, currentInstrumentPluginId, onInstrumentSelect, instrumentsLoading, onRefreshInstruments, editorStage, onShowEditor, onBackToInstruments, soundHistory, soundHistoryCursor, onRestoreSound, onToggleFavorite, onImportSound, importSoundLabel, editNotes, onNotesChange, editBars, editBpm, editSnap, onAuditionNote, drag, levels, }: SDKTrackRowProps): React$1.ReactElement;
|
|
2751
|
+
declare function TrackRow({ track, prompt, runtimeState, soloedOut, fxDetailState, drawerOpen, drawerTab, onTabChange, isGenerating, isAuthenticated, error, hasMidi, generationProgress, estimatedGenerationMs, onPromptChange, onGenerate, onShuffle, onCopy, onDelete, contentSlot, onMuteToggle, onSoloToggle, onVolumeChange, onPanChange, onFxToggle, onFxPresetChange, onFxDryWetChange, externalFxHost, onToggleFxDrawer, onProgressChange, accentColor, instrumentName, instrumentMissing, onToggleDrawer, availableInstruments, currentInstrumentPluginId, onInstrumentSelect, instrumentsLoading, onRefreshInstruments, editorStage, onShowEditor, onBackToInstruments, soundHistory, soundHistoryCursor, onRestoreSound, onToggleFavorite, onImportSound, importSoundLabel, editNotes, onNotesChange, editBars, editBpm, editSnap, onAuditionNote, drag, levels, }: SDKTrackRowProps): React$1.ReactElement;
|
|
2674
2752
|
|
|
2675
2753
|
/**
|
|
2676
2754
|
* Crossfade-pair metadata — family-agnostic types + parsing shared by every
|
|
@@ -3616,6 +3694,11 @@ declare const VolumeSlider: React$1.FC<VolumeSliderProps>;
|
|
|
3616
3694
|
interface PanelMasterStripProps {
|
|
3617
3695
|
/** Bus state from `host.getPanelBusState(sceneId)`. */
|
|
3618
3696
|
bus: PanelBusState;
|
|
3697
|
+
/**
|
|
3698
|
+
* Stereo output levels from `host.getPanelBusLevels` (polled by
|
|
3699
|
+
* usePanelBus). Null floors the meter (disengaged / engine quiet).
|
|
3700
|
+
*/
|
|
3701
|
+
levels?: PanelBusLevels | null;
|
|
3619
3702
|
/** FX descriptors from `host.getAvailableFx()` (lazy-load on picker open). */
|
|
3620
3703
|
availableFx?: InstrumentDescriptor[];
|
|
3621
3704
|
/** True while `availableFx` is loading. */
|
|
@@ -3642,7 +3725,7 @@ interface PanelMasterStripProps {
|
|
|
3642
3725
|
/** Optional: open the FX plugin's native editor window. */
|
|
3643
3726
|
onShowFxEditor?: (fxIndex: number) => void;
|
|
3644
3727
|
}
|
|
3645
|
-
declare function PanelMasterStrip({ bus, availableFx, fxLoading, soloedOut, disabled, fxPickerOpen, onToggleFxPicker, onRefreshFx, onVolumeChange, onMuteToggle, onSoloToggle, onAddFx, onRemoveFx, onToggleFxEnabled, onShowFxEditor, }: PanelMasterStripProps): React$1.ReactElement;
|
|
3728
|
+
declare function PanelMasterStrip({ bus, levels, availableFx, fxLoading, soloedOut, disabled, fxPickerOpen, onToggleFxPicker, onRefreshFx, onVolumeChange, onMuteToggle, onSoloToggle, onAddFx, onRemoveFx, onToggleFxEnabled, onShowFxEditor, }: PanelMasterStripProps): React$1.ReactElement;
|
|
3646
3729
|
|
|
3647
3730
|
/**
|
|
3648
3731
|
* usePanelBus — panel-side state + handlers for the PanelMasterStrip
|
|
@@ -3664,6 +3747,8 @@ interface UsePanelBusResult {
|
|
|
3664
3747
|
supported: boolean;
|
|
3665
3748
|
/** Null until the first load completes for the current scene. */
|
|
3666
3749
|
bus: PanelBusState | null;
|
|
3750
|
+
/** Stereo output levels (null = disengaged / floored). Polled at ~15 Hz. */
|
|
3751
|
+
levels: PanelBusLevels | null;
|
|
3667
3752
|
availableFx: InstrumentDescriptor[];
|
|
3668
3753
|
fxLoading: boolean;
|
|
3669
3754
|
fxPickerOpen: boolean;
|
|
@@ -3680,6 +3765,65 @@ interface UsePanelBusResult {
|
|
|
3680
3765
|
}
|
|
3681
3766
|
declare function usePanelBus(host: PluginHost, activeSceneId: string | null): UsePanelBusResult;
|
|
3682
3767
|
|
|
3768
|
+
/**
|
|
3769
|
+
* TrackExternalFxSection — the TrackDrawer FX-tab block for one track's
|
|
3770
|
+
* third-party (VST3/AU) FX inserts, below the built-in FX toggle bar.
|
|
3771
|
+
*
|
|
3772
|
+
* SELF-CONTAINED by design: give it the host and a track id and it manages
|
|
3773
|
+
* its own fetch/mutation state via useTrackExternalFx. That keeps per-panel
|
|
3774
|
+
* wiring to a single prop (six panels consume this) instead of ten
|
|
3775
|
+
* callbacks. Renders nothing on hosts without the surface (pre-2.39), so
|
|
3776
|
+
* panels can pass the prop unconditionally.
|
|
3777
|
+
*
|
|
3778
|
+
* Visual idiom mirrors PanelMasterStrip's FX chips + picker grid: chip =
|
|
3779
|
+
* bypass dot + name (opens the native editor) + remove ✕; the picker is the
|
|
3780
|
+
* TrackDrawer Pick-tab grid over FX descriptors with a search box.
|
|
3781
|
+
*/
|
|
3782
|
+
|
|
3783
|
+
interface TrackExternalFxSectionProps {
|
|
3784
|
+
/** The panel's host — used directly; the section manages its own state. */
|
|
3785
|
+
host: PluginHost;
|
|
3786
|
+
/** ENGINE track id (the same id the panel passes to getTrackFxState). */
|
|
3787
|
+
trackId: string;
|
|
3788
|
+
/** Disable all controls (e.g. while the track is generating). */
|
|
3789
|
+
disabled?: boolean;
|
|
3790
|
+
}
|
|
3791
|
+
declare function TrackExternalFxSection({ host, trackId, disabled, }: TrackExternalFxSectionProps): React$1.ReactElement | null;
|
|
3792
|
+
|
|
3793
|
+
/**
|
|
3794
|
+
* useTrackExternalFx — panel-side state + handlers for one track's
|
|
3795
|
+
* third-party FX inserts (the TrackDrawer FX-tab section; the per-track
|
|
3796
|
+
* sibling of usePanelBus).
|
|
3797
|
+
*
|
|
3798
|
+
* Feature-gated: `supported` is false on hosts without the track-external-FX
|
|
3799
|
+
* surface (pre-2.39 app builds) and consumers must render nothing then.
|
|
3800
|
+
* Reading converges persisted state host-side (raw-state replay on the
|
|
3801
|
+
* session's first read; rebuild after a `.sasproj` import), so the mount
|
|
3802
|
+
* read is the whole reload story.
|
|
3803
|
+
*
|
|
3804
|
+
* Mutations follow the strip's pattern: host call → list reload. Errors
|
|
3805
|
+
* surface via the host's platform toast; the section re-reads whatever
|
|
3806
|
+
* state is true afterwards.
|
|
3807
|
+
*/
|
|
3808
|
+
|
|
3809
|
+
interface UseTrackExternalFxResult {
|
|
3810
|
+
/** False on pre-2.39 hosts — render no section. */
|
|
3811
|
+
supported: boolean;
|
|
3812
|
+
/** Null until the first load completes for the current track. */
|
|
3813
|
+
fx: TrackExternalFxEntry[] | null;
|
|
3814
|
+
availableFx: InstrumentDescriptor[];
|
|
3815
|
+
fxLoading: boolean;
|
|
3816
|
+
pickerOpen: boolean;
|
|
3817
|
+
setPickerOpen: (open: boolean) => void;
|
|
3818
|
+
refreshFx: () => void;
|
|
3819
|
+
reload: () => Promise<void>;
|
|
3820
|
+
onAddFx: (pluginId: string) => void;
|
|
3821
|
+
onRemoveFx: (fxIndex: number) => void;
|
|
3822
|
+
onToggleFxEnabled: (fxIndex: number, enabled: boolean) => void;
|
|
3823
|
+
onShowFxEditor: (fxIndex: number) => void;
|
|
3824
|
+
}
|
|
3825
|
+
declare function useTrackExternalFx(host: PluginHost, trackId: string): UseTrackExternalFxResult;
|
|
3826
|
+
|
|
3683
3827
|
/**
|
|
3684
3828
|
* PanSlider Component
|
|
3685
3829
|
*
|
|
@@ -4810,7 +4954,7 @@ declare function useAnySolo(host: Pick<PluginHost, 'isAnySoloActive' | 'onTrackS
|
|
|
4810
4954
|
* Registry checks semver.gte(PLUGIN_SDK_VERSION, manifest.minHostVersion)
|
|
4811
4955
|
* during activation and marks incompatible plugins accordingly.
|
|
4812
4956
|
*/
|
|
4813
|
-
declare const PLUGIN_SDK_VERSION = "2.
|
|
4957
|
+
declare const PLUGIN_SDK_VERSION = "2.40.0";
|
|
4814
4958
|
|
|
4815
4959
|
/**
|
|
4816
4960
|
* FX Preset Definitions
|
|
@@ -4958,4 +5102,4 @@ interface PickTopKOptions {
|
|
|
4958
5102
|
*/
|
|
4959
5103
|
declare function pickTopKWeighted<T>(scored: ReadonlyArray<ScoredCandidate<T>>, options?: PickTopKOptions): T | null;
|
|
4960
5104
|
|
|
4961
|
-
export { AUDIO_EFFECTS, AUDIO_EFFECT_LABEL, type AudioEffect, type AudioInputDevice, type BulkAddPlaceholderTrack, type ComposeProgressEvent, type ComposeProgressListener, type ComposeSceneOptions, type ComposeSceneResult, ConfirmDialog, type ConfirmDialogProps, type CoreTrackHandlers, type CreateTrackOptions, type CrossfadeInpaintInput, type CrossfadeLayer, type CrossfadeMeta, CrossfadeModal, type CrossfadeModalProps, type CrossfadePairMeta, type CrossfadeSelection, type CrossfadeSlot, CrossfadeTrackRow, type CrossfadeTrackRowProps, type CrossfadeVolumeCurves, DB_MAX, DB_MIN, DEFAULT_FX_CATEGORY_DETAIL, DEFAULT_FX_DRY_WET, DRAG_DEAD_ZONE, type DeckBoundaryEvent, type DeckBoundaryListener, type DesignerRowSlots, DownloadPackButton, type DownloadPackButtonProps, type DownloadPackButtonVariant, type DrawerTab, type DrumKit, EMPTY_FX_DETAIL_STATE, EMPTY_FX_STATE, EQUAL_POWER_GAIN, type ExportMidiBundleOptions, type ExportMidiBundleResult, type ExportedPluginData, FX_CATEGORIES, FX_CHAIN_ORDER, FX_DISPLAY_LABELS, FX_ENGINE_PLUGIN_NAMES, FX_PRESET_CONFIGS, type FadeDirection, type FadeEntry, type FadeGesture, type FadeLayer, type FadeMeta, FadeModal, type FadeModalProps, type FadeSelection, FadeTrackRow, type FadeTrackRowProps, type FxCategory, type FxCategoryDetailState, type FxPreset, type FxPresetConfig, type FxPresetData, type FxPresetDataEntry, FxToggleBar, type FxToggleBarProps, GUTTER_W, type GenerationServices, type GeneratorPanelAdapter, type GeneratorPanelCore, GeneratorPanelShell, type GeneratorPanelShellProps, type GeneratorPanelSlots, type GeneratorPlugin, type GeneratorTrackState, type GeneratorType, type GroupParseSpec, type GroupRenderContext, type ImportCandidateScene, type ImportCandidateTrack, ImportTrackModal, type ImportTrackModalProps, type InstrumentDescriptor, TrackDrawer as InstrumentDrawer, type TrackDrawerProps as InstrumentDrawerProps, type InstrumentSampler, type InstrumentZone, type LLMCandidate, type LLMContent, type LLMFunctionDeclaration, type LLMGenerationConfig, type LLMGenerationRequest, type LLMGenerationResult, type LLMNoteResponse, type LLMPart, type LLMSystemInstruction, type LLMTool, type LLMToolUseRequest, type LLMToolUseResponse, type LLMUsageMetadata, LevelMeter, type LevelMeterProps, type ListAudioFilesOptions, type ListImportableTracksOptions, type MidiClipData, type MidiWriteResult, type MixInterpolation, Modal, type ModalProps, type MusicalContext, OffsetScrubber, type OffsetScrubberProps, PLUGIN_SDK_VERSION, PX_PER_BEAT, PanSlider, type PanelBusFxEntry, type PanelBusState, type PanelFeatureFlags, type PanelGenerationStrategy, type PanelGroupExtension, type PanelIdentity, PanelMasterStrip, type PanelMasterStripProps, type PanelShuffleAdapter, type PanelSoundAdapter, type PeakAnalysis, PianoRollEditor, type PianoRollEditorProps, type PickTopKOptions, type PluginAppTool, type PluginAppToolInputSchema, type PluginAppToolResult, type PluginAudioTextureRequest, type PluginAudioTextureResult, type PluginCapabilities, type PluginChordSegment, type PluginChordTiming, type PluginConcurrentTrackInfo, type PluginCuePoints, type PluginDownloadOptions, PluginError, type PluginErrorCode, type PluginFileDialogOptions, type PluginFxCategoryDetailState, type PluginGenerationContext, type PluginHost, type PluginHttpRequestOptions, type PluginHttpResponse, type PluginManifest, type PluginMidiNote, type PluginPresetData, type PluginPresetInfo, type PluginRegistration, type PluginSampleFilter, type PluginSampleImportResult, type PluginSampleInfo, type PluginSampleTrackInfo, type PluginSceneContext, type PluginSceneInfo, type PluginSettingsSchema, type PluginSettingsStore, type PluginSkill, type PluginSkillInputSchema, type PluginStatus, type PluginStemSplitResult, type PluginStemTrackInfo, type PluginSynthInfo, type PluginTrackFxDetailState, type PluginTrackHandle, type PluginTrackInfo, type PluginTrackLevel, type PluginTrackRuntimeState, type PluginTransportState, type PluginTrimWindow, type PluginUIProps, type PostProcessOptions, RESIZE_HANDLE_PX, ROW_HEIGHT, type ReadMidiClip, type ReadMidiResult, type RecordingChunkFinalizedEvent, type RecordingTargetInfo, type ResolveGroupsOptions, type ResolvedCrossfadePair, type ResolvedFade, type ResolvedGroupsResult, type ResolvedTrackGroup, type SDKTrackRowProps, SLIDER_UNITY, SamplePackCTACard, type SamplePackCTACardProps, type SamplePackCTACardStatus, type SamplePackCardInfo, type SavePluginPresetOptions, type SceneChangeListener, type SceneFamilyTrack, type ScoredCandidate, ScrollingWaveform, type ScrollingWaveformProps, type SettingDefinition, type ShufflePresetResult, SorceryProgressBar, type SoundHistoryEntry, type StemType, type SurgeSoundAdapterOverrides, type SynthesizeCuePointsOptions, TEXTURAL_ROLES, TRANSITION_DESIGNER_DRAFT_KEY, TrackDrawer, type TrackDrawerProps, type TrackFxDetailState, type TrackFxState, type TrackGroupMember, type TrackGroupMeta, type TrackLevelsHandle, TrackMeterStrip, type TrackMeterStripProps, type TrackMeterView, TrackRow, type TrackRowDragProps, type TrackSoundHistory, type TrackSoundSnapshot, type TrackStateChangeListener, TransitionDesigner, type TransitionDesignerDraft, type TransitionDesignerProps, type TransitionOps, type TransitionRowType, type TransportEvent, type TransportEventListener, type UnsubscribeFn, type UseGeneratorPanelCoreOptions, type UsePanelBusResult, type UseSoundHistoryOptions, type UseSoundHistoryResult, type UseTrackReorderOptions, type UseTrackReorderResult, type UseTransitionOpsInputs, type VolumeAutomationPoint, VolumeSlider, type WaveformPeaks, WaveformView, type WaveformViewProps, analyzeWavPeak, asAudioEffect, asCrossfadeMeta, asFadeMeta, asTransitionDesignerDraft, buildCrossfadeInpaintPrompt, buildCrossfadeVolumeCurves, buildFadeVolumeCurve, buildRowSlots, calculateTimeBasedTarget, cellToPx, centerScrollTop, computePeaks, createSurgeSoundAdapter, dbIdsFromKeys, dbToSlider, defaultFadeGesture, drawWaveform, formatConcurrentTracks, hashString, moveItem, newTrackState, normalizeSlots, padPair, padSlots, parseCrossfadePairs, parseFades, parseLLMNoteResponse, parseTrackGroups, pickTopKWeighted, pitchToName, pluginFxToToggleFx, pxToCell, reconcileSlots, resizeNoteDuration, resolveTrackGroups, rowKey, rowType, scorePromptMatch, sliderToDb, slotsEqual, soundIdentity, synthesizeCuePoints, tokenizePrompt, trackDataKey, transposeNotes, useAnySolo, useGeneratorPanelCore, usePanelBus, useSceneState, useSoundHistory, useTrackLevel, useTrackLevels, useTrackMeter, useTrackReorder, useTransitionOps, useTransportPlaying };
|
|
5105
|
+
export { AUDIO_EFFECTS, AUDIO_EFFECT_LABEL, type AudioEffect, type AudioInputDevice, type BulkAddPlaceholderTrack, type ComposeProgressEvent, type ComposeProgressListener, type ComposeSceneOptions, type ComposeSceneResult, ConfirmDialog, type ConfirmDialogProps, type CoreTrackHandlers, type CreateTrackOptions, type CrossfadeInpaintInput, type CrossfadeLayer, type CrossfadeMeta, CrossfadeModal, type CrossfadeModalProps, type CrossfadePairMeta, type CrossfadeSelection, type CrossfadeSlot, CrossfadeTrackRow, type CrossfadeTrackRowProps, type CrossfadeVolumeCurves, DB_MAX, DB_MIN, DEFAULT_FX_CATEGORY_DETAIL, DEFAULT_FX_DRY_WET, DRAG_DEAD_ZONE, type DeckBoundaryEvent, type DeckBoundaryListener, type DesignerRowSlots, DownloadPackButton, type DownloadPackButtonProps, type DownloadPackButtonVariant, type DrawerTab, type DrumKit, EMPTY_FX_DETAIL_STATE, EMPTY_FX_STATE, EQUAL_POWER_GAIN, type ExportMidiBundleOptions, type ExportMidiBundleResult, type ExportedPluginData, FX_CATEGORIES, FX_CHAIN_ORDER, FX_DISPLAY_LABELS, FX_ENGINE_PLUGIN_NAMES, FX_PRESET_CONFIGS, type FadeDirection, type FadeEntry, type FadeGesture, type FadeLayer, type FadeMeta, FadeModal, type FadeModalProps, type FadeSelection, FadeTrackRow, type FadeTrackRowProps, type FxCategory, type FxCategoryDetailState, type FxPreset, type FxPresetConfig, type FxPresetData, type FxPresetDataEntry, FxToggleBar, type FxToggleBarProps, GUTTER_W, type GenerationServices, type GeneratorPanelAdapter, type GeneratorPanelCore, GeneratorPanelShell, type GeneratorPanelShellProps, type GeneratorPanelSlots, type GeneratorPlugin, type GeneratorTrackState, type GeneratorType, type GroupParseSpec, type GroupRenderContext, type ImportCandidateScene, type ImportCandidateTrack, ImportTrackModal, type ImportTrackModalProps, type InstrumentDescriptor, TrackDrawer as InstrumentDrawer, type TrackDrawerProps as InstrumentDrawerProps, type InstrumentSampler, type InstrumentZone, type LLMCandidate, type LLMContent, type LLMFunctionDeclaration, type LLMGenerationConfig, type LLMGenerationRequest, type LLMGenerationResult, type LLMNoteResponse, type LLMPart, type LLMSystemInstruction, type LLMTool, type LLMToolUseRequest, type LLMToolUseResponse, type LLMUsageMetadata, LevelMeter, type LevelMeterProps, type ListAudioFilesOptions, type ListImportableTracksOptions, type MidiClipData, type MidiWriteResult, type MixInterpolation, Modal, type ModalProps, type MusicalContext, OffsetScrubber, type OffsetScrubberProps, PLUGIN_SDK_VERSION, PX_PER_BEAT, PanSlider, type PanelBusFxEntry, type PanelBusLevels, type PanelBusState, type PanelFeatureFlags, type PanelGenerationStrategy, type PanelGroupExtension, type PanelIdentity, PanelMasterStrip, type PanelMasterStripProps, type PanelShuffleAdapter, type PanelSoundAdapter, type PeakAnalysis, PianoRollEditor, type PianoRollEditorProps, type PickTopKOptions, type PluginAppTool, type PluginAppToolInputSchema, type PluginAppToolResult, type PluginAudioTextureRequest, type PluginAudioTextureResult, type PluginCapabilities, type PluginChordSegment, type PluginChordTiming, type PluginConcurrentTrackInfo, type PluginCuePoints, type PluginDownloadOptions, PluginError, type PluginErrorCode, type PluginFileDialogOptions, type PluginFxCategoryDetailState, type PluginGenerationContext, type PluginHost, type PluginHttpRequestOptions, type PluginHttpResponse, type PluginManifest, type PluginMidiNote, type PluginPresetData, type PluginPresetInfo, type PluginRegistration, type PluginSampleFilter, type PluginSampleImportResult, type PluginSampleInfo, type PluginSampleTrackInfo, type PluginSceneContext, type PluginSceneInfo, type PluginSettingsSchema, type PluginSettingsStore, type PluginSkill, type PluginSkillInputSchema, type PluginStatus, type PluginStemSplitResult, type PluginStemTrackInfo, type PluginSynthInfo, type PluginTrackFxDetailState, type PluginTrackHandle, type PluginTrackInfo, type PluginTrackLevel, type PluginTrackRuntimeState, type PluginTransportState, type PluginTrimWindow, type PluginUIProps, type PostProcessOptions, RESIZE_HANDLE_PX, ROW_HEIGHT, type ReadMidiClip, type ReadMidiResult, type RecordingChunkFinalizedEvent, type RecordingTargetInfo, type ResolveGroupsOptions, type ResolvedCrossfadePair, type ResolvedFade, type ResolvedGroupsResult, type ResolvedTrackGroup, type SDKTrackRowProps, SLIDER_UNITY, SamplePackCTACard, type SamplePackCTACardProps, type SamplePackCTACardStatus, type SamplePackCardInfo, type SavePluginPresetOptions, type SceneChangeListener, type SceneFamilyTrack, type ScoredCandidate, ScrollingWaveform, type ScrollingWaveformProps, type SettingDefinition, type ShufflePresetResult, SorceryProgressBar, type SoundHistoryEntry, type StemType, type SurgeSoundAdapterOverrides, type SynthesizeCuePointsOptions, TEXTURAL_ROLES, TRANSITION_DESIGNER_DRAFT_KEY, TrackDrawer, type TrackDrawerProps, type TrackExternalFxEntry, TrackExternalFxSection, type TrackExternalFxSectionProps, type TrackFxDetailState, type TrackFxState, type TrackGroupMember, type TrackGroupMeta, type TrackLevelsHandle, TrackMeterStrip, type TrackMeterStripProps, type TrackMeterView, TrackRow, type TrackRowDragProps, type TrackSoundHistory, type TrackSoundSnapshot, type TrackStateChangeListener, TransitionDesigner, type TransitionDesignerDraft, type TransitionDesignerProps, type TransitionOps, type TransitionRowType, type TransportEvent, type TransportEventListener, type UnsubscribeFn, type UseGeneratorPanelCoreOptions, type UsePanelBusResult, type UseSoundHistoryOptions, type UseSoundHistoryResult, type UseTrackExternalFxResult, type UseTrackReorderOptions, type UseTrackReorderResult, type UseTransitionOpsInputs, type VolumeAutomationPoint, VolumeSlider, type WaveformPeaks, WaveformView, type WaveformViewProps, analyzeWavPeak, asAudioEffect, asCrossfadeMeta, asFadeMeta, asTransitionDesignerDraft, buildCrossfadeInpaintPrompt, buildCrossfadeVolumeCurves, buildFadeVolumeCurve, buildRowSlots, calculateTimeBasedTarget, cellToPx, centerScrollTop, computePeaks, createSurgeSoundAdapter, dbIdsFromKeys, dbToSlider, defaultFadeGesture, drawWaveform, formatConcurrentTracks, hashString, moveItem, newTrackState, normalizeSlots, padPair, padSlots, parseCrossfadePairs, parseFades, parseLLMNoteResponse, parseTrackGroups, pickTopKWeighted, pitchToName, pluginFxToToggleFx, pxToCell, reconcileSlots, resizeNoteDuration, resolveTrackGroups, rowKey, rowType, scorePromptMatch, sliderToDb, slotsEqual, soundIdentity, synthesizeCuePoints, tokenizePrompt, trackDataKey, transposeNotes, useAnySolo, useGeneratorPanelCore, usePanelBus, useSceneState, useSoundHistory, useTrackExternalFx, useTrackLevel, useTrackLevels, useTrackMeter, useTrackReorder, useTransitionOps, useTransportPlaying };
|
package/dist/index.d.ts
CHANGED
|
@@ -120,6 +120,38 @@ interface PanelBusState {
|
|
|
120
120
|
/** User FX chain, top-to-bottom (master section excluded). */
|
|
121
121
|
fx: PanelBusFxEntry[];
|
|
122
122
|
}
|
|
123
|
+
/**
|
|
124
|
+
* One third-party (VST3/AU) FX insert on a TRACK's plugin chain, as shown to
|
|
125
|
+
* the panel UI. The track's instrument, the built-in FX-toggle plugins
|
|
126
|
+
* (reverb/delay/eq/…) and the Volume & Pan master section are filtered OUT —
|
|
127
|
+
* this list is only the user's external inserts. Same shape as
|
|
128
|
+
* `PanelBusFxEntry` by design: the drawer and the bus strip share UI idioms.
|
|
129
|
+
* @since SDK 2.39.0
|
|
130
|
+
*/
|
|
131
|
+
interface TrackExternalFxEntry {
|
|
132
|
+
/**
|
|
133
|
+
* ENGINE chain index — pass this back to remove/bypass/editor calls.
|
|
134
|
+
* Not contiguous from 0: the instrument and built-in FX share the chain.
|
|
135
|
+
*/
|
|
136
|
+
index: number;
|
|
137
|
+
/** Scanned plugin id (the picker's `InstrumentDescriptor.pluginId`). */
|
|
138
|
+
pluginId: string;
|
|
139
|
+
/** Display name. */
|
|
140
|
+
name: string;
|
|
141
|
+
/** False when bypassed. */
|
|
142
|
+
enabled: boolean;
|
|
143
|
+
}
|
|
144
|
+
/**
|
|
145
|
+
* Stereo peak levels of a panel bus's OUTPUT (post-FX, post-fader). dBFS,
|
|
146
|
+
* floored at -120 ("no signal"). Drives the strip's stereo meter.
|
|
147
|
+
* @since SDK 2.38.0
|
|
148
|
+
*/
|
|
149
|
+
interface PanelBusLevels {
|
|
150
|
+
leftDb: number;
|
|
151
|
+
rightDb: number;
|
|
152
|
+
/** Latched overload since the last read. */
|
|
153
|
+
clipped: boolean;
|
|
154
|
+
}
|
|
123
155
|
/** Every generator plugin must implement this interface. */
|
|
124
156
|
interface GeneratorPlugin {
|
|
125
157
|
/** Unique ID, npm-style scope: '@sas/synth-generator', '@user/my-plugin' */
|
|
@@ -605,6 +637,16 @@ interface PluginHost {
|
|
|
605
637
|
* picker components consume one type.
|
|
606
638
|
*/
|
|
607
639
|
getAvailableFx?(): Promise<InstrumentDescriptor[]>;
|
|
640
|
+
/**
|
|
641
|
+
* Force a plugin re-scan and return the refreshed FX list. Unlike
|
|
642
|
+
* `getAvailableFx` (served from a cache), this re-walks the plugin
|
|
643
|
+
* directories AND clears the engine's failed-probe blacklist, so a plugin
|
|
644
|
+
* installed mid-session, or one that crashed a previous scan and was
|
|
645
|
+
* blacklisted, reappears without an app restart. Backs the FX picker's
|
|
646
|
+
* "Rescan" button. Slow (20-60s). Absent on pre-2.40 hosts — callers should
|
|
647
|
+
* fall back to `getAvailableFx`. @since SDK 2.40.0
|
|
648
|
+
*/
|
|
649
|
+
rescanAvailableFx?(): Promise<InstrumentDescriptor[]>;
|
|
608
650
|
/**
|
|
609
651
|
* The panel's bus state for a scene. `{ engaged: false, … }` when the
|
|
610
652
|
* panel has no bus there — reading NEVER creates one. When engaged, this
|
|
@@ -614,6 +656,12 @@ interface PluginHost {
|
|
|
614
656
|
* is the panel's whole reload story.
|
|
615
657
|
*/
|
|
616
658
|
getPanelBusState?(sceneId: string): Promise<PanelBusState>;
|
|
659
|
+
/**
|
|
660
|
+
* Stereo output levels for the strip's bus meter (~30 Hz poll). Null when
|
|
661
|
+
* the bus is disengaged/unrealized or the engine is unavailable — render
|
|
662
|
+
* the meter floored. Never engages a bus. @since SDK 2.38.0
|
|
663
|
+
*/
|
|
664
|
+
getPanelBusLevels?(sceneId: string): Promise<PanelBusLevels | null>;
|
|
617
665
|
/** Master fader in dB (engages the bus on first use). */
|
|
618
666
|
setPanelBusVolume?(sceneId: string, volumeDb: number): Promise<void>;
|
|
619
667
|
/** Bus mute — silences the whole panel (multiplies with per-track mutes). */
|
|
@@ -636,6 +684,24 @@ interface PluginHost {
|
|
|
636
684
|
* scene, persisted state deleted. The panel returns to flat routing.
|
|
637
685
|
*/
|
|
638
686
|
disengagePanelBus?(sceneId: string): Promise<void>;
|
|
687
|
+
/**
|
|
688
|
+
* The track's external FX inserts (instrument + built-ins filtered out).
|
|
689
|
+
* Reading also converges persisted state: on the first read of a session
|
|
690
|
+
* the host re-applies saved raw plugin states, and after a `.sasproj`
|
|
691
|
+
* import it rebuilds missing inserts from the persisted blob.
|
|
692
|
+
*/
|
|
693
|
+
getTrackExternalFx?(trackId: string): Promise<TrackExternalFxEntry[]>;
|
|
694
|
+
/**
|
|
695
|
+
* Add an FX plugin (by scanned pluginId, from `getAvailableFx`) to the
|
|
696
|
+
* track's chain, inserted before Volume & Pan. Instruments are rejected.
|
|
697
|
+
*/
|
|
698
|
+
loadTrackExternalFx?(trackId: string, pluginId: string): Promise<TrackExternalFxEntry>;
|
|
699
|
+
/** Remove an external FX by its `TrackExternalFxEntry.index`. */
|
|
700
|
+
removeTrackExternalFx?(trackId: string, fxIndex: number): Promise<void>;
|
|
701
|
+
/** Bypass toggle for an external FX by its `TrackExternalFxEntry.index`. */
|
|
702
|
+
setTrackExternalFxEnabled?(trackId: string, fxIndex: number, enabled: boolean): Promise<void>;
|
|
703
|
+
/** Open the native editor window for an external FX. */
|
|
704
|
+
showTrackExternalFxEditor?(trackId: string, fxIndex: number): Promise<void>;
|
|
639
705
|
/** Subscribe to transport state changes. Returns unsubscribe function. */
|
|
640
706
|
onTransportEvent(listener: TransportEventListener): UnsubscribeFn;
|
|
641
707
|
/** Subscribe to deck boundary events. Returns unsubscribe function. */
|
|
@@ -2354,6 +2420,14 @@ interface TrackDrawerProps {
|
|
|
2354
2420
|
onFxDryWetChange?: (category: FxCategory, value: number) => void;
|
|
2355
2421
|
/** Disable FX controls (e.g. while the track is generating). */
|
|
2356
2422
|
fxDisabled?: boolean;
|
|
2423
|
+
/**
|
|
2424
|
+
* Third-party FX section under the toggle bar (@since SDK 2.39.0): pass the
|
|
2425
|
+
* panel's host and the section manages its own state
|
|
2426
|
+
* (TrackExternalFxSection). Renders nothing on hosts without the surface,
|
|
2427
|
+
* so panels can pass this unconditionally. Omit to keep a built-ins-only
|
|
2428
|
+
* FX tab.
|
|
2429
|
+
*/
|
|
2430
|
+
externalFxHost?: PluginHost;
|
|
2357
2431
|
/** Available instrument plugins from engine scan. */
|
|
2358
2432
|
instruments?: InstrumentDescriptor[];
|
|
2359
2433
|
/** Currently loaded instrument plugin ID (null = default Surge XT). */
|
|
@@ -2395,7 +2469,7 @@ interface TrackDrawerProps {
|
|
|
2395
2469
|
/** Optional single-note preview when the user adds a note. */
|
|
2396
2470
|
onAuditionNote?: (pitch: number, velocity: number, durationMs: number) => void;
|
|
2397
2471
|
}
|
|
2398
|
-
declare function TrackDrawer({ activeTab, onTabChange, trackId, fxState, onFxToggle, onFxPresetChange, onFxDryWetChange, fxDisabled, instruments, currentPluginId, isLoading, onSelect, onRefresh, editorStage, onShowEditor, onBackToInstruments, selectedInstrumentName, soundHistory, soundHistoryCursor, onRestoreSound, onToggleFavorite, onImportSound, importSoundLabel, editNotes, onNotesChange, editBars, editBpm, editSnap, onAuditionNote, }: TrackDrawerProps): React$1.ReactElement;
|
|
2472
|
+
declare function TrackDrawer({ activeTab, onTabChange, trackId, fxState, onFxToggle, onFxPresetChange, onFxDryWetChange, fxDisabled, externalFxHost, instruments, currentPluginId, isLoading, onSelect, onRefresh, editorStage, onShowEditor, onBackToInstruments, selectedInstrumentName, soundHistory, soundHistoryCursor, onRestoreSound, onToggleFavorite, onImportSound, importSoundLabel, editNotes, onNotesChange, editBars, editBpm, editSnap, onAuditionNote, }: TrackDrawerProps): React$1.ReactElement;
|
|
2399
2473
|
|
|
2400
2474
|
/**
|
|
2401
2475
|
* useTrackLevels — drives the cosmetic per-track strip meters.
|
|
@@ -2611,6 +2685,10 @@ interface SDKTrackRowProps {
|
|
|
2611
2685
|
onFxPresetChange?: (cat: FxCategory, idx: number) => void;
|
|
2612
2686
|
/** FX dry/wet */
|
|
2613
2687
|
onFxDryWetChange?: (cat: FxCategory, val: number) => void;
|
|
2688
|
+
/** Third-party FX section in the drawer's FX tab — pass the panel's host
|
|
2689
|
+
* (self-contained; renders nothing on hosts without the surface).
|
|
2690
|
+
* @since SDK 2.39.0 */
|
|
2691
|
+
externalFxHost?: PluginHost;
|
|
2614
2692
|
/** Open/close FX (optional — omit to hide FX button) */
|
|
2615
2693
|
onToggleFxDrawer?: () => void;
|
|
2616
2694
|
/** Progress persistence callback */
|
|
@@ -2670,7 +2748,7 @@ interface SDKTrackRowProps {
|
|
|
2670
2748
|
* a thin peak meter welds to the bottom of the row. Omit to hide it. */
|
|
2671
2749
|
levels?: TrackLevelsHandle;
|
|
2672
2750
|
}
|
|
2673
|
-
declare function TrackRow({ track, prompt, runtimeState, soloedOut, fxDetailState, drawerOpen, drawerTab, onTabChange, isGenerating, isAuthenticated, error, hasMidi, generationProgress, estimatedGenerationMs, onPromptChange, onGenerate, onShuffle, onCopy, onDelete, contentSlot, onMuteToggle, onSoloToggle, onVolumeChange, onPanChange, onFxToggle, onFxPresetChange, onFxDryWetChange, onToggleFxDrawer, onProgressChange, accentColor, instrumentName, instrumentMissing, onToggleDrawer, availableInstruments, currentInstrumentPluginId, onInstrumentSelect, instrumentsLoading, onRefreshInstruments, editorStage, onShowEditor, onBackToInstruments, soundHistory, soundHistoryCursor, onRestoreSound, onToggleFavorite, onImportSound, importSoundLabel, editNotes, onNotesChange, editBars, editBpm, editSnap, onAuditionNote, drag, levels, }: SDKTrackRowProps): React$1.ReactElement;
|
|
2751
|
+
declare function TrackRow({ track, prompt, runtimeState, soloedOut, fxDetailState, drawerOpen, drawerTab, onTabChange, isGenerating, isAuthenticated, error, hasMidi, generationProgress, estimatedGenerationMs, onPromptChange, onGenerate, onShuffle, onCopy, onDelete, contentSlot, onMuteToggle, onSoloToggle, onVolumeChange, onPanChange, onFxToggle, onFxPresetChange, onFxDryWetChange, externalFxHost, onToggleFxDrawer, onProgressChange, accentColor, instrumentName, instrumentMissing, onToggleDrawer, availableInstruments, currentInstrumentPluginId, onInstrumentSelect, instrumentsLoading, onRefreshInstruments, editorStage, onShowEditor, onBackToInstruments, soundHistory, soundHistoryCursor, onRestoreSound, onToggleFavorite, onImportSound, importSoundLabel, editNotes, onNotesChange, editBars, editBpm, editSnap, onAuditionNote, drag, levels, }: SDKTrackRowProps): React$1.ReactElement;
|
|
2674
2752
|
|
|
2675
2753
|
/**
|
|
2676
2754
|
* Crossfade-pair metadata — family-agnostic types + parsing shared by every
|
|
@@ -3616,6 +3694,11 @@ declare const VolumeSlider: React$1.FC<VolumeSliderProps>;
|
|
|
3616
3694
|
interface PanelMasterStripProps {
|
|
3617
3695
|
/** Bus state from `host.getPanelBusState(sceneId)`. */
|
|
3618
3696
|
bus: PanelBusState;
|
|
3697
|
+
/**
|
|
3698
|
+
* Stereo output levels from `host.getPanelBusLevels` (polled by
|
|
3699
|
+
* usePanelBus). Null floors the meter (disengaged / engine quiet).
|
|
3700
|
+
*/
|
|
3701
|
+
levels?: PanelBusLevels | null;
|
|
3619
3702
|
/** FX descriptors from `host.getAvailableFx()` (lazy-load on picker open). */
|
|
3620
3703
|
availableFx?: InstrumentDescriptor[];
|
|
3621
3704
|
/** True while `availableFx` is loading. */
|
|
@@ -3642,7 +3725,7 @@ interface PanelMasterStripProps {
|
|
|
3642
3725
|
/** Optional: open the FX plugin's native editor window. */
|
|
3643
3726
|
onShowFxEditor?: (fxIndex: number) => void;
|
|
3644
3727
|
}
|
|
3645
|
-
declare function PanelMasterStrip({ bus, availableFx, fxLoading, soloedOut, disabled, fxPickerOpen, onToggleFxPicker, onRefreshFx, onVolumeChange, onMuteToggle, onSoloToggle, onAddFx, onRemoveFx, onToggleFxEnabled, onShowFxEditor, }: PanelMasterStripProps): React$1.ReactElement;
|
|
3728
|
+
declare function PanelMasterStrip({ bus, levels, availableFx, fxLoading, soloedOut, disabled, fxPickerOpen, onToggleFxPicker, onRefreshFx, onVolumeChange, onMuteToggle, onSoloToggle, onAddFx, onRemoveFx, onToggleFxEnabled, onShowFxEditor, }: PanelMasterStripProps): React$1.ReactElement;
|
|
3646
3729
|
|
|
3647
3730
|
/**
|
|
3648
3731
|
* usePanelBus — panel-side state + handlers for the PanelMasterStrip
|
|
@@ -3664,6 +3747,8 @@ interface UsePanelBusResult {
|
|
|
3664
3747
|
supported: boolean;
|
|
3665
3748
|
/** Null until the first load completes for the current scene. */
|
|
3666
3749
|
bus: PanelBusState | null;
|
|
3750
|
+
/** Stereo output levels (null = disengaged / floored). Polled at ~15 Hz. */
|
|
3751
|
+
levels: PanelBusLevels | null;
|
|
3667
3752
|
availableFx: InstrumentDescriptor[];
|
|
3668
3753
|
fxLoading: boolean;
|
|
3669
3754
|
fxPickerOpen: boolean;
|
|
@@ -3680,6 +3765,65 @@ interface UsePanelBusResult {
|
|
|
3680
3765
|
}
|
|
3681
3766
|
declare function usePanelBus(host: PluginHost, activeSceneId: string | null): UsePanelBusResult;
|
|
3682
3767
|
|
|
3768
|
+
/**
|
|
3769
|
+
* TrackExternalFxSection — the TrackDrawer FX-tab block for one track's
|
|
3770
|
+
* third-party (VST3/AU) FX inserts, below the built-in FX toggle bar.
|
|
3771
|
+
*
|
|
3772
|
+
* SELF-CONTAINED by design: give it the host and a track id and it manages
|
|
3773
|
+
* its own fetch/mutation state via useTrackExternalFx. That keeps per-panel
|
|
3774
|
+
* wiring to a single prop (six panels consume this) instead of ten
|
|
3775
|
+
* callbacks. Renders nothing on hosts without the surface (pre-2.39), so
|
|
3776
|
+
* panels can pass the prop unconditionally.
|
|
3777
|
+
*
|
|
3778
|
+
* Visual idiom mirrors PanelMasterStrip's FX chips + picker grid: chip =
|
|
3779
|
+
* bypass dot + name (opens the native editor) + remove ✕; the picker is the
|
|
3780
|
+
* TrackDrawer Pick-tab grid over FX descriptors with a search box.
|
|
3781
|
+
*/
|
|
3782
|
+
|
|
3783
|
+
interface TrackExternalFxSectionProps {
|
|
3784
|
+
/** The panel's host — used directly; the section manages its own state. */
|
|
3785
|
+
host: PluginHost;
|
|
3786
|
+
/** ENGINE track id (the same id the panel passes to getTrackFxState). */
|
|
3787
|
+
trackId: string;
|
|
3788
|
+
/** Disable all controls (e.g. while the track is generating). */
|
|
3789
|
+
disabled?: boolean;
|
|
3790
|
+
}
|
|
3791
|
+
declare function TrackExternalFxSection({ host, trackId, disabled, }: TrackExternalFxSectionProps): React$1.ReactElement | null;
|
|
3792
|
+
|
|
3793
|
+
/**
|
|
3794
|
+
* useTrackExternalFx — panel-side state + handlers for one track's
|
|
3795
|
+
* third-party FX inserts (the TrackDrawer FX-tab section; the per-track
|
|
3796
|
+
* sibling of usePanelBus).
|
|
3797
|
+
*
|
|
3798
|
+
* Feature-gated: `supported` is false on hosts without the track-external-FX
|
|
3799
|
+
* surface (pre-2.39 app builds) and consumers must render nothing then.
|
|
3800
|
+
* Reading converges persisted state host-side (raw-state replay on the
|
|
3801
|
+
* session's first read; rebuild after a `.sasproj` import), so the mount
|
|
3802
|
+
* read is the whole reload story.
|
|
3803
|
+
*
|
|
3804
|
+
* Mutations follow the strip's pattern: host call → list reload. Errors
|
|
3805
|
+
* surface via the host's platform toast; the section re-reads whatever
|
|
3806
|
+
* state is true afterwards.
|
|
3807
|
+
*/
|
|
3808
|
+
|
|
3809
|
+
interface UseTrackExternalFxResult {
|
|
3810
|
+
/** False on pre-2.39 hosts — render no section. */
|
|
3811
|
+
supported: boolean;
|
|
3812
|
+
/** Null until the first load completes for the current track. */
|
|
3813
|
+
fx: TrackExternalFxEntry[] | null;
|
|
3814
|
+
availableFx: InstrumentDescriptor[];
|
|
3815
|
+
fxLoading: boolean;
|
|
3816
|
+
pickerOpen: boolean;
|
|
3817
|
+
setPickerOpen: (open: boolean) => void;
|
|
3818
|
+
refreshFx: () => void;
|
|
3819
|
+
reload: () => Promise<void>;
|
|
3820
|
+
onAddFx: (pluginId: string) => void;
|
|
3821
|
+
onRemoveFx: (fxIndex: number) => void;
|
|
3822
|
+
onToggleFxEnabled: (fxIndex: number, enabled: boolean) => void;
|
|
3823
|
+
onShowFxEditor: (fxIndex: number) => void;
|
|
3824
|
+
}
|
|
3825
|
+
declare function useTrackExternalFx(host: PluginHost, trackId: string): UseTrackExternalFxResult;
|
|
3826
|
+
|
|
3683
3827
|
/**
|
|
3684
3828
|
* PanSlider Component
|
|
3685
3829
|
*
|
|
@@ -4810,7 +4954,7 @@ declare function useAnySolo(host: Pick<PluginHost, 'isAnySoloActive' | 'onTrackS
|
|
|
4810
4954
|
* Registry checks semver.gte(PLUGIN_SDK_VERSION, manifest.minHostVersion)
|
|
4811
4955
|
* during activation and marks incompatible plugins accordingly.
|
|
4812
4956
|
*/
|
|
4813
|
-
declare const PLUGIN_SDK_VERSION = "2.
|
|
4957
|
+
declare const PLUGIN_SDK_VERSION = "2.40.0";
|
|
4814
4958
|
|
|
4815
4959
|
/**
|
|
4816
4960
|
* FX Preset Definitions
|
|
@@ -4958,4 +5102,4 @@ interface PickTopKOptions {
|
|
|
4958
5102
|
*/
|
|
4959
5103
|
declare function pickTopKWeighted<T>(scored: ReadonlyArray<ScoredCandidate<T>>, options?: PickTopKOptions): T | null;
|
|
4960
5104
|
|
|
4961
|
-
export { AUDIO_EFFECTS, AUDIO_EFFECT_LABEL, type AudioEffect, type AudioInputDevice, type BulkAddPlaceholderTrack, type ComposeProgressEvent, type ComposeProgressListener, type ComposeSceneOptions, type ComposeSceneResult, ConfirmDialog, type ConfirmDialogProps, type CoreTrackHandlers, type CreateTrackOptions, type CrossfadeInpaintInput, type CrossfadeLayer, type CrossfadeMeta, CrossfadeModal, type CrossfadeModalProps, type CrossfadePairMeta, type CrossfadeSelection, type CrossfadeSlot, CrossfadeTrackRow, type CrossfadeTrackRowProps, type CrossfadeVolumeCurves, DB_MAX, DB_MIN, DEFAULT_FX_CATEGORY_DETAIL, DEFAULT_FX_DRY_WET, DRAG_DEAD_ZONE, type DeckBoundaryEvent, type DeckBoundaryListener, type DesignerRowSlots, DownloadPackButton, type DownloadPackButtonProps, type DownloadPackButtonVariant, type DrawerTab, type DrumKit, EMPTY_FX_DETAIL_STATE, EMPTY_FX_STATE, EQUAL_POWER_GAIN, type ExportMidiBundleOptions, type ExportMidiBundleResult, type ExportedPluginData, FX_CATEGORIES, FX_CHAIN_ORDER, FX_DISPLAY_LABELS, FX_ENGINE_PLUGIN_NAMES, FX_PRESET_CONFIGS, type FadeDirection, type FadeEntry, type FadeGesture, type FadeLayer, type FadeMeta, FadeModal, type FadeModalProps, type FadeSelection, FadeTrackRow, type FadeTrackRowProps, type FxCategory, type FxCategoryDetailState, type FxPreset, type FxPresetConfig, type FxPresetData, type FxPresetDataEntry, FxToggleBar, type FxToggleBarProps, GUTTER_W, type GenerationServices, type GeneratorPanelAdapter, type GeneratorPanelCore, GeneratorPanelShell, type GeneratorPanelShellProps, type GeneratorPanelSlots, type GeneratorPlugin, type GeneratorTrackState, type GeneratorType, type GroupParseSpec, type GroupRenderContext, type ImportCandidateScene, type ImportCandidateTrack, ImportTrackModal, type ImportTrackModalProps, type InstrumentDescriptor, TrackDrawer as InstrumentDrawer, type TrackDrawerProps as InstrumentDrawerProps, type InstrumentSampler, type InstrumentZone, type LLMCandidate, type LLMContent, type LLMFunctionDeclaration, type LLMGenerationConfig, type LLMGenerationRequest, type LLMGenerationResult, type LLMNoteResponse, type LLMPart, type LLMSystemInstruction, type LLMTool, type LLMToolUseRequest, type LLMToolUseResponse, type LLMUsageMetadata, LevelMeter, type LevelMeterProps, type ListAudioFilesOptions, type ListImportableTracksOptions, type MidiClipData, type MidiWriteResult, type MixInterpolation, Modal, type ModalProps, type MusicalContext, OffsetScrubber, type OffsetScrubberProps, PLUGIN_SDK_VERSION, PX_PER_BEAT, PanSlider, type PanelBusFxEntry, type PanelBusState, type PanelFeatureFlags, type PanelGenerationStrategy, type PanelGroupExtension, type PanelIdentity, PanelMasterStrip, type PanelMasterStripProps, type PanelShuffleAdapter, type PanelSoundAdapter, type PeakAnalysis, PianoRollEditor, type PianoRollEditorProps, type PickTopKOptions, type PluginAppTool, type PluginAppToolInputSchema, type PluginAppToolResult, type PluginAudioTextureRequest, type PluginAudioTextureResult, type PluginCapabilities, type PluginChordSegment, type PluginChordTiming, type PluginConcurrentTrackInfo, type PluginCuePoints, type PluginDownloadOptions, PluginError, type PluginErrorCode, type PluginFileDialogOptions, type PluginFxCategoryDetailState, type PluginGenerationContext, type PluginHost, type PluginHttpRequestOptions, type PluginHttpResponse, type PluginManifest, type PluginMidiNote, type PluginPresetData, type PluginPresetInfo, type PluginRegistration, type PluginSampleFilter, type PluginSampleImportResult, type PluginSampleInfo, type PluginSampleTrackInfo, type PluginSceneContext, type PluginSceneInfo, type PluginSettingsSchema, type PluginSettingsStore, type PluginSkill, type PluginSkillInputSchema, type PluginStatus, type PluginStemSplitResult, type PluginStemTrackInfo, type PluginSynthInfo, type PluginTrackFxDetailState, type PluginTrackHandle, type PluginTrackInfo, type PluginTrackLevel, type PluginTrackRuntimeState, type PluginTransportState, type PluginTrimWindow, type PluginUIProps, type PostProcessOptions, RESIZE_HANDLE_PX, ROW_HEIGHT, type ReadMidiClip, type ReadMidiResult, type RecordingChunkFinalizedEvent, type RecordingTargetInfo, type ResolveGroupsOptions, type ResolvedCrossfadePair, type ResolvedFade, type ResolvedGroupsResult, type ResolvedTrackGroup, type SDKTrackRowProps, SLIDER_UNITY, SamplePackCTACard, type SamplePackCTACardProps, type SamplePackCTACardStatus, type SamplePackCardInfo, type SavePluginPresetOptions, type SceneChangeListener, type SceneFamilyTrack, type ScoredCandidate, ScrollingWaveform, type ScrollingWaveformProps, type SettingDefinition, type ShufflePresetResult, SorceryProgressBar, type SoundHistoryEntry, type StemType, type SurgeSoundAdapterOverrides, type SynthesizeCuePointsOptions, TEXTURAL_ROLES, TRANSITION_DESIGNER_DRAFT_KEY, TrackDrawer, type TrackDrawerProps, type TrackFxDetailState, type TrackFxState, type TrackGroupMember, type TrackGroupMeta, type TrackLevelsHandle, TrackMeterStrip, type TrackMeterStripProps, type TrackMeterView, TrackRow, type TrackRowDragProps, type TrackSoundHistory, type TrackSoundSnapshot, type TrackStateChangeListener, TransitionDesigner, type TransitionDesignerDraft, type TransitionDesignerProps, type TransitionOps, type TransitionRowType, type TransportEvent, type TransportEventListener, type UnsubscribeFn, type UseGeneratorPanelCoreOptions, type UsePanelBusResult, type UseSoundHistoryOptions, type UseSoundHistoryResult, type UseTrackReorderOptions, type UseTrackReorderResult, type UseTransitionOpsInputs, type VolumeAutomationPoint, VolumeSlider, type WaveformPeaks, WaveformView, type WaveformViewProps, analyzeWavPeak, asAudioEffect, asCrossfadeMeta, asFadeMeta, asTransitionDesignerDraft, buildCrossfadeInpaintPrompt, buildCrossfadeVolumeCurves, buildFadeVolumeCurve, buildRowSlots, calculateTimeBasedTarget, cellToPx, centerScrollTop, computePeaks, createSurgeSoundAdapter, dbIdsFromKeys, dbToSlider, defaultFadeGesture, drawWaveform, formatConcurrentTracks, hashString, moveItem, newTrackState, normalizeSlots, padPair, padSlots, parseCrossfadePairs, parseFades, parseLLMNoteResponse, parseTrackGroups, pickTopKWeighted, pitchToName, pluginFxToToggleFx, pxToCell, reconcileSlots, resizeNoteDuration, resolveTrackGroups, rowKey, rowType, scorePromptMatch, sliderToDb, slotsEqual, soundIdentity, synthesizeCuePoints, tokenizePrompt, trackDataKey, transposeNotes, useAnySolo, useGeneratorPanelCore, usePanelBus, useSceneState, useSoundHistory, useTrackLevel, useTrackLevels, useTrackMeter, useTrackReorder, useTransitionOps, useTransportPlaying };
|
|
5105
|
+
export { AUDIO_EFFECTS, AUDIO_EFFECT_LABEL, type AudioEffect, type AudioInputDevice, type BulkAddPlaceholderTrack, type ComposeProgressEvent, type ComposeProgressListener, type ComposeSceneOptions, type ComposeSceneResult, ConfirmDialog, type ConfirmDialogProps, type CoreTrackHandlers, type CreateTrackOptions, type CrossfadeInpaintInput, type CrossfadeLayer, type CrossfadeMeta, CrossfadeModal, type CrossfadeModalProps, type CrossfadePairMeta, type CrossfadeSelection, type CrossfadeSlot, CrossfadeTrackRow, type CrossfadeTrackRowProps, type CrossfadeVolumeCurves, DB_MAX, DB_MIN, DEFAULT_FX_CATEGORY_DETAIL, DEFAULT_FX_DRY_WET, DRAG_DEAD_ZONE, type DeckBoundaryEvent, type DeckBoundaryListener, type DesignerRowSlots, DownloadPackButton, type DownloadPackButtonProps, type DownloadPackButtonVariant, type DrawerTab, type DrumKit, EMPTY_FX_DETAIL_STATE, EMPTY_FX_STATE, EQUAL_POWER_GAIN, type ExportMidiBundleOptions, type ExportMidiBundleResult, type ExportedPluginData, FX_CATEGORIES, FX_CHAIN_ORDER, FX_DISPLAY_LABELS, FX_ENGINE_PLUGIN_NAMES, FX_PRESET_CONFIGS, type FadeDirection, type FadeEntry, type FadeGesture, type FadeLayer, type FadeMeta, FadeModal, type FadeModalProps, type FadeSelection, FadeTrackRow, type FadeTrackRowProps, type FxCategory, type FxCategoryDetailState, type FxPreset, type FxPresetConfig, type FxPresetData, type FxPresetDataEntry, FxToggleBar, type FxToggleBarProps, GUTTER_W, type GenerationServices, type GeneratorPanelAdapter, type GeneratorPanelCore, GeneratorPanelShell, type GeneratorPanelShellProps, type GeneratorPanelSlots, type GeneratorPlugin, type GeneratorTrackState, type GeneratorType, type GroupParseSpec, type GroupRenderContext, type ImportCandidateScene, type ImportCandidateTrack, ImportTrackModal, type ImportTrackModalProps, type InstrumentDescriptor, TrackDrawer as InstrumentDrawer, type TrackDrawerProps as InstrumentDrawerProps, type InstrumentSampler, type InstrumentZone, type LLMCandidate, type LLMContent, type LLMFunctionDeclaration, type LLMGenerationConfig, type LLMGenerationRequest, type LLMGenerationResult, type LLMNoteResponse, type LLMPart, type LLMSystemInstruction, type LLMTool, type LLMToolUseRequest, type LLMToolUseResponse, type LLMUsageMetadata, LevelMeter, type LevelMeterProps, type ListAudioFilesOptions, type ListImportableTracksOptions, type MidiClipData, type MidiWriteResult, type MixInterpolation, Modal, type ModalProps, type MusicalContext, OffsetScrubber, type OffsetScrubberProps, PLUGIN_SDK_VERSION, PX_PER_BEAT, PanSlider, type PanelBusFxEntry, type PanelBusLevels, type PanelBusState, type PanelFeatureFlags, type PanelGenerationStrategy, type PanelGroupExtension, type PanelIdentity, PanelMasterStrip, type PanelMasterStripProps, type PanelShuffleAdapter, type PanelSoundAdapter, type PeakAnalysis, PianoRollEditor, type PianoRollEditorProps, type PickTopKOptions, type PluginAppTool, type PluginAppToolInputSchema, type PluginAppToolResult, type PluginAudioTextureRequest, type PluginAudioTextureResult, type PluginCapabilities, type PluginChordSegment, type PluginChordTiming, type PluginConcurrentTrackInfo, type PluginCuePoints, type PluginDownloadOptions, PluginError, type PluginErrorCode, type PluginFileDialogOptions, type PluginFxCategoryDetailState, type PluginGenerationContext, type PluginHost, type PluginHttpRequestOptions, type PluginHttpResponse, type PluginManifest, type PluginMidiNote, type PluginPresetData, type PluginPresetInfo, type PluginRegistration, type PluginSampleFilter, type PluginSampleImportResult, type PluginSampleInfo, type PluginSampleTrackInfo, type PluginSceneContext, type PluginSceneInfo, type PluginSettingsSchema, type PluginSettingsStore, type PluginSkill, type PluginSkillInputSchema, type PluginStatus, type PluginStemSplitResult, type PluginStemTrackInfo, type PluginSynthInfo, type PluginTrackFxDetailState, type PluginTrackHandle, type PluginTrackInfo, type PluginTrackLevel, type PluginTrackRuntimeState, type PluginTransportState, type PluginTrimWindow, type PluginUIProps, type PostProcessOptions, RESIZE_HANDLE_PX, ROW_HEIGHT, type ReadMidiClip, type ReadMidiResult, type RecordingChunkFinalizedEvent, type RecordingTargetInfo, type ResolveGroupsOptions, type ResolvedCrossfadePair, type ResolvedFade, type ResolvedGroupsResult, type ResolvedTrackGroup, type SDKTrackRowProps, SLIDER_UNITY, SamplePackCTACard, type SamplePackCTACardProps, type SamplePackCTACardStatus, type SamplePackCardInfo, type SavePluginPresetOptions, type SceneChangeListener, type SceneFamilyTrack, type ScoredCandidate, ScrollingWaveform, type ScrollingWaveformProps, type SettingDefinition, type ShufflePresetResult, SorceryProgressBar, type SoundHistoryEntry, type StemType, type SurgeSoundAdapterOverrides, type SynthesizeCuePointsOptions, TEXTURAL_ROLES, TRANSITION_DESIGNER_DRAFT_KEY, TrackDrawer, type TrackDrawerProps, type TrackExternalFxEntry, TrackExternalFxSection, type TrackExternalFxSectionProps, type TrackFxDetailState, type TrackFxState, type TrackGroupMember, type TrackGroupMeta, type TrackLevelsHandle, TrackMeterStrip, type TrackMeterStripProps, type TrackMeterView, TrackRow, type TrackRowDragProps, type TrackSoundHistory, type TrackSoundSnapshot, type TrackStateChangeListener, TransitionDesigner, type TransitionDesignerDraft, type TransitionDesignerProps, type TransitionOps, type TransitionRowType, type TransportEvent, type TransportEventListener, type UnsubscribeFn, type UseGeneratorPanelCoreOptions, type UsePanelBusResult, type UseSoundHistoryOptions, type UseSoundHistoryResult, type UseTrackExternalFxResult, type UseTrackReorderOptions, type UseTrackReorderResult, type UseTransitionOpsInputs, type VolumeAutomationPoint, VolumeSlider, type WaveformPeaks, WaveformView, type WaveformViewProps, analyzeWavPeak, asAudioEffect, asCrossfadeMeta, asFadeMeta, asTransitionDesignerDraft, buildCrossfadeInpaintPrompt, buildCrossfadeVolumeCurves, buildFadeVolumeCurve, buildRowSlots, calculateTimeBasedTarget, cellToPx, centerScrollTop, computePeaks, createSurgeSoundAdapter, dbIdsFromKeys, dbToSlider, defaultFadeGesture, drawWaveform, formatConcurrentTracks, hashString, moveItem, newTrackState, normalizeSlots, padPair, padSlots, parseCrossfadePairs, parseFades, parseLLMNoteResponse, parseTrackGroups, pickTopKWeighted, pitchToName, pluginFxToToggleFx, pxToCell, reconcileSlots, resizeNoteDuration, resolveTrackGroups, rowKey, rowType, scorePromptMatch, sliderToDb, slotsEqual, soundIdentity, synthesizeCuePoints, tokenizePrompt, trackDataKey, transposeNotes, useAnySolo, useGeneratorPanelCore, usePanelBus, useSceneState, useSoundHistory, useTrackExternalFx, useTrackLevel, useTrackLevels, useTrackMeter, useTrackReorder, useTransitionOps, useTransportPlaying };
|