@avoid.quest/audio 0.0.0-stage → 0.1.1-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +98 -2
- package/dist/effects/index.d.ts +215 -0
- package/dist/effects/index.js +451 -0
- package/dist/effects/index.js.map +1 -0
- package/dist/errors-BT9HxDLn.js +74 -0
- package/dist/errors-BT9HxDLn.js.map +1 -0
- package/dist/errors-ChTQFwuZ.d.ts +53 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +3 -0
- package/dist/midi/index.d.ts +138 -0
- package/dist/midi/index.js +302 -0
- package/dist/midi/index.js.map +1 -0
- package/dist/native-Bern4_PB.js +172 -0
- package/dist/native-Bern4_PB.js.map +1 -0
- package/dist/pcm-buffer-DSzGHbon.js +436 -0
- package/dist/pcm-buffer-DSzGHbon.js.map +1 -0
- package/dist/playback/index.d.ts +295 -0
- package/dist/playback/index.js +1209 -0
- package/dist/playback/index.js.map +1 -0
- package/dist/queue/index.d.ts +133 -0
- package/dist/queue/index.js +563 -0
- package/dist/queue/index.js.map +1 -0
- package/dist/recognize/index.d.ts +124 -0
- package/dist/recognize/index.js +273 -0
- package/dist/recognize/index.js.map +1 -0
- package/dist/routing/index.d.ts +109 -0
- package/dist/routing/index.js +555 -0
- package/dist/routing/index.js.map +1 -0
- package/dist/shazam-gBrX1NEY.d.ts +27 -0
- package/dist/sync/index.d.ts +214 -0
- package/dist/sync/index.js +881 -0
- package/dist/sync/index.js.map +1 -0
- package/dist/worklet-loader-BabwPALw.d.ts +41 -0
- package/dist/worklet-loader-f741D1tk.js +160 -0
- package/dist/worklet-loader-f741D1tk.js.map +1 -0
- package/dist/worklets/couch-live.d.ts +1 -0
- package/dist/worklets/couch-live.js +283 -0
- package/dist/worklets/couch-live.js.map +1 -0
- package/dist/worklets/meter.d.ts +7 -0
- package/dist/worklets/meter.js +74 -0
- package/dist/worklets/meter.js.map +1 -0
- package/dist/worklets/pcm-capture.d.ts +6 -0
- package/dist/worklets/pcm-capture.js +52 -0
- package/dist/worklets/pcm-capture.js.map +1 -0
- package/package.json +114 -4
|
@@ -0,0 +1,295 @@
|
|
|
1
|
+
import { Context, Effect, Layer, Schedule, Scope } from "effect";
|
|
2
|
+
import { d as AudioWorkletError, n as AudioDecodeError, o as AudioPlaybackError, t as AudioCaptureError, u as AudioUnsupportedError } from "../errors-ChTQFwuZ.js";
|
|
3
|
+
import Hls, { HlsConfig } from "hls.js";
|
|
4
|
+
import { l as ShazamSignatureResult } from "../shazam-gBrX1NEY.js";
|
|
5
|
+
import { t as LoadAudioWorkletOptions } from "../worklet-loader-BabwPALw.js";
|
|
6
|
+
interface AudioContextOptionsInput {
|
|
7
|
+
readonly isMobile?: boolean;
|
|
8
|
+
readonly isFirefox?: boolean;
|
|
9
|
+
readonly sampleRate?: number;
|
|
10
|
+
}
|
|
11
|
+
interface AudioContextSnapshot {
|
|
12
|
+
readonly state: "suspended" | "running" | "closed";
|
|
13
|
+
readonly sampleRate: number;
|
|
14
|
+
readonly currentTime: number;
|
|
15
|
+
readonly baseLatency: number | undefined;
|
|
16
|
+
readonly outputLatency: number | undefined;
|
|
17
|
+
}
|
|
18
|
+
interface AudioContextHandle {
|
|
19
|
+
readonly context: AudioContext;
|
|
20
|
+
readonly ensureRunning: () => Effect.Effect<void, AudioPlaybackError>;
|
|
21
|
+
readonly getSnapshot: () => AudioContextSnapshot;
|
|
22
|
+
readonly close: () => Effect.Effect<void>;
|
|
23
|
+
}
|
|
24
|
+
interface AudioContextLayerOptions extends AudioContextOptionsInput {
|
|
25
|
+
readonly context?: AudioContext;
|
|
26
|
+
readonly createContext?: (options: AudioContextOptions) => AudioContext;
|
|
27
|
+
readonly closeOnRelease?: boolean;
|
|
28
|
+
readonly unlockOnGesture?: boolean;
|
|
29
|
+
readonly unlockTarget?: EventTarget;
|
|
30
|
+
}
|
|
31
|
+
declare const AudioContextService_base: Context.ServiceClass<AudioContextService, "@avoid.quest/audio/AudioContextService", AudioContextHandle>;
|
|
32
|
+
export declare class AudioContextService extends AudioContextService_base {}
|
|
33
|
+
export declare function createAudioContextOptions(options?: AudioContextOptionsInput): AudioContextOptions;
|
|
34
|
+
export declare function normalizeAudioContextState(state: AudioContextState | "interrupted"): "suspended" | "running" | "closed";
|
|
35
|
+
export declare function snapshotAudioContext(context: AudioContext): AudioContextSnapshot;
|
|
36
|
+
export declare function ensureAudioContextRunning(context: AudioContext): Effect.Effect<void, AudioPlaybackError>;
|
|
37
|
+
export declare function attachGestureUnlock(context: AudioContext, target?: EventTarget | undefined): () => void;
|
|
38
|
+
export declare function acquireAudioContext(options?: AudioContextLayerOptions): Effect.Effect<AudioContextHandle, AudioUnsupportedError, Scope.Scope>;
|
|
39
|
+
export declare function makeAudioContextLayer(options?: AudioContextLayerOptions): Layer.Layer<AudioContextService, AudioUnsupportedError>;
|
|
40
|
+
interface ChannelSelection {
|
|
41
|
+
readonly left: number;
|
|
42
|
+
readonly right: number;
|
|
43
|
+
}
|
|
44
|
+
interface DeviceCaptureOptions {
|
|
45
|
+
readonly deviceId?: string;
|
|
46
|
+
readonly stream?: MediaStream;
|
|
47
|
+
readonly channelCount?: number;
|
|
48
|
+
readonly channelSelection?: ChannelSelection;
|
|
49
|
+
readonly mediaDevices?: Pick<MediaDevices, "getUserMedia">;
|
|
50
|
+
readonly signal?: AbortSignal;
|
|
51
|
+
readonly onEnded?: () => void;
|
|
52
|
+
}
|
|
53
|
+
interface DisplayAudioOptions {
|
|
54
|
+
readonly mediaDevices?: Pick<MediaDevices, "getDisplayMedia">;
|
|
55
|
+
readonly requireBrowserTab?: boolean;
|
|
56
|
+
readonly signal?: AbortSignal;
|
|
57
|
+
}
|
|
58
|
+
interface LiveInputCapture {
|
|
59
|
+
readonly stream: MediaStream;
|
|
60
|
+
readonly sourceNode: MediaStreamAudioSourceNode;
|
|
61
|
+
readonly outputNode: GainNode;
|
|
62
|
+
readonly outputChannelCount: 1 | 2;
|
|
63
|
+
readonly stop: () => void;
|
|
64
|
+
}
|
|
65
|
+
export declare function requestDisplayAudio(options?: DisplayAudioOptions): Effect.Effect<MediaStream, AudioCaptureError>;
|
|
66
|
+
export declare function acquireInputCapture(context: AudioContext, options?: DeviceCaptureOptions): Effect.Effect<LiveInputCapture, AudioCaptureError, Scope.Scope>;
|
|
67
|
+
export declare const MIN_PLAYBACK_RATE = 0.5;
|
|
68
|
+
export declare const MAX_PLAYBACK_RATE = 2;
|
|
69
|
+
export declare const DEFAULT_MEDIA_READY_TIMEOUT_MS = 20000;
|
|
70
|
+
export declare const DEFAULT_STALL_WATCHDOG_MS = 6000;
|
|
71
|
+
export declare const DEFAULT_MAX_RECOVERY_DELAY_MS = 30000;
|
|
72
|
+
interface StallRecoveryConfig {
|
|
73
|
+
readonly baseDelayMs?: number;
|
|
74
|
+
readonly maxDelayMs?: number;
|
|
75
|
+
readonly maxAttempts?: number;
|
|
76
|
+
}
|
|
77
|
+
interface MediaEngineLoadOptions {
|
|
78
|
+
readonly startPositionSeconds?: number;
|
|
79
|
+
readonly allowNativeHls?: boolean;
|
|
80
|
+
readonly hlsConfig?: Partial<HlsConfig>;
|
|
81
|
+
readonly crossOrigin?: "" | "anonymous" | "use-credentials" | null;
|
|
82
|
+
readonly waitForReady?: boolean;
|
|
83
|
+
readonly readyTimeoutMs?: number;
|
|
84
|
+
}
|
|
85
|
+
interface MediaEngineOptions {
|
|
86
|
+
readonly element: HTMLAudioElement | HTMLVideoElement;
|
|
87
|
+
readonly allowNativeHls?: boolean;
|
|
88
|
+
readonly hlsConfig?: Partial<HlsConfig>;
|
|
89
|
+
readonly stallRecovery?: StallRecoveryConfig;
|
|
90
|
+
readonly mediaReadyTimeoutMs?: number;
|
|
91
|
+
readonly stallWatchdogMs?: number;
|
|
92
|
+
readonly userAgent?: string;
|
|
93
|
+
readonly loadHls?: () => Promise<{
|
|
94
|
+
readonly default: typeof Hls;
|
|
95
|
+
}>;
|
|
96
|
+
readonly onStall?: (currentTime: number) => void;
|
|
97
|
+
readonly onStreamError?: (currentTime: number, error: AudioPlaybackError) => void;
|
|
98
|
+
}
|
|
99
|
+
interface MediaEngineSnapshot {
|
|
100
|
+
readonly src: string | undefined;
|
|
101
|
+
readonly paused: boolean;
|
|
102
|
+
readonly currentTime: number;
|
|
103
|
+
readonly duration: number | undefined;
|
|
104
|
+
readonly playbackRate: number;
|
|
105
|
+
readonly preservesPitch: boolean;
|
|
106
|
+
readonly volume: number;
|
|
107
|
+
readonly muted: boolean;
|
|
108
|
+
readonly mode: "idle" | "native" | "native-hls" | "hls.js";
|
|
109
|
+
}
|
|
110
|
+
interface MediaEngine {
|
|
111
|
+
readonly element: HTMLAudioElement | HTMLVideoElement;
|
|
112
|
+
readonly load: (url: string, options?: MediaEngineLoadOptions) => Effect.Effect<void, AudioPlaybackError>;
|
|
113
|
+
readonly play: () => Effect.Effect<void, AudioPlaybackError>;
|
|
114
|
+
readonly pause: () => Effect.Effect<void>;
|
|
115
|
+
readonly seek: (seconds: number) => Effect.Effect<void>;
|
|
116
|
+
readonly setPlaybackRate: (rate: number) => Effect.Effect<number>;
|
|
117
|
+
readonly setPreservesPitch: (preserve: boolean) => Effect.Effect<boolean>;
|
|
118
|
+
readonly setVolume: (volume: number) => Effect.Effect<number>;
|
|
119
|
+
readonly setMuted: (muted: boolean) => Effect.Effect<boolean>;
|
|
120
|
+
readonly refreshUrl: (url: string, seekPositionSeconds?: number) => Effect.Effect<void, AudioPlaybackError>;
|
|
121
|
+
readonly runWithStallRecovery: <A, R>(effect: Effect.Effect<A, AudioPlaybackError, R>) => Effect.Effect<A, AudioPlaybackError, R>;
|
|
122
|
+
readonly getSnapshot: () => MediaEngineSnapshot;
|
|
123
|
+
readonly dispose: () => Effect.Effect<void>;
|
|
124
|
+
}
|
|
125
|
+
export declare const clampPlaybackRate: (rate: number) => number;
|
|
126
|
+
export declare function applyPreservesPitch(element: HTMLMediaElement, preserve: boolean): boolean;
|
|
127
|
+
export declare function isHlsUrl(url: string, depth?: number): boolean;
|
|
128
|
+
export declare const isWebKitBrowser: (ua?: string | undefined) => boolean;
|
|
129
|
+
export declare function shouldUseNativeHls(element: Pick<HTMLMediaElement, "canPlayType">, allowNativeHls?: boolean, userAgent?: string): boolean;
|
|
130
|
+
export declare const computeStallBackoffMs: (attempt: number, base?: number, max?: number) => number;
|
|
131
|
+
export declare function createStallRecoverySchedule(config?: StallRecoveryConfig): Schedule.Schedule<number>;
|
|
132
|
+
export declare function createMediaEngine(options: MediaEngineOptions): Effect.Effect<MediaEngine, never, Scope.Scope>;
|
|
133
|
+
interface MediaElementSourceOptions {
|
|
134
|
+
/**
|
|
135
|
+
* Route the source to `context.destination` (default `true`). A captured
|
|
136
|
+
* element is only audible through the Web Audio graph, so disable this only
|
|
137
|
+
* when you route the node yourself; `false` also removes an edge created by
|
|
138
|
+
* an earlier call.
|
|
139
|
+
*/
|
|
140
|
+
readonly connectToDestination?: boolean;
|
|
141
|
+
}
|
|
142
|
+
/** A raw media element or anything exposing one, such as a `MediaEngine`. */
|
|
143
|
+
type MediaElementSourceTarget = HTMLMediaElement | Pick<MediaEngine, "element">;
|
|
144
|
+
/**
|
|
145
|
+
* Returns the memoized `MediaElementAudioSourceNode` for a `MediaEngine` or
|
|
146
|
+
* media element (browsers allow only one per element), so live playback can
|
|
147
|
+
* feed `acquirePcmCapture`, meters, or effects. Requesting it for another
|
|
148
|
+
* `AudioContext` fails with `MEDIA_SOURCE_CONTEXT_MISMATCH`. Cross-origin
|
|
149
|
+
* media needs CORS + `crossOrigin: "anonymous"`, otherwise the graph is silent.
|
|
150
|
+
*/
|
|
151
|
+
export declare function getMediaElementSourceNode(context: AudioContext, target: MediaElementSourceTarget, options?: MediaElementSourceOptions): Effect.Effect<MediaElementAudioSourceNode, AudioPlaybackError>;
|
|
152
|
+
export declare const PCM_CAPTURE_PROCESSOR_NAME: "avoid-pcm-capture";
|
|
153
|
+
export declare const PCM_CAPTURE_DEFAULT_CHUNK_FRAMES = 2048;
|
|
154
|
+
type LoadPcmCaptureWorkletOptions = Omit<LoadAudioWorkletOptions, "processorName">;
|
|
155
|
+
interface PcmCaptureOptions {
|
|
156
|
+
/** Rolling window length in seconds (default 12 s, the Shazam maximum). */
|
|
157
|
+
readonly maxSeconds?: number;
|
|
158
|
+
/** Frames per worklet message (default 2048, clamped to `[128, 16384]`). */
|
|
159
|
+
readonly chunkFrames?: number;
|
|
160
|
+
readonly workletOptions?: LoadPcmCaptureWorkletOptions;
|
|
161
|
+
/** Raw mono chunk observer, called after the chunk is buffered. */
|
|
162
|
+
readonly onChunk?: (chunk: Float32Array) => void;
|
|
163
|
+
}
|
|
164
|
+
interface PcmCapture {
|
|
165
|
+
readonly node: AudioWorkletNode;
|
|
166
|
+
/** Sample rate of captured frames (`context.sampleRate`). */
|
|
167
|
+
readonly sampleRate: number;
|
|
168
|
+
readonly capacitySeconds: number;
|
|
169
|
+
readonly isActive: () => boolean;
|
|
170
|
+
readonly bufferedSeconds: () => number;
|
|
171
|
+
/** Copies the most recent `seconds` of mono PCM (default: whole window). */
|
|
172
|
+
readonly snapshot: (seconds?: number) => Float32Array;
|
|
173
|
+
/** Mono 16 kHz PCM16LE bytes ready for `generateShazamSignature`. */
|
|
174
|
+
readonly toShazamPcm: (seconds?: number) => Uint8Array;
|
|
175
|
+
/** Fingerprints the most recent `seconds` via `@avoid.quest/audio/recognize`. */
|
|
176
|
+
readonly fingerprint: (seconds?: number) => Effect.Effect<ShazamSignatureResult, AudioDecodeError>;
|
|
177
|
+
readonly clear: () => void;
|
|
178
|
+
}
|
|
179
|
+
/** Loads the standalone `@avoid.quest/audio/worklets/pcm-capture` module. */
|
|
180
|
+
export declare function loadPcmCaptureWorklet(context: BaseAudioContext, options?: LoadPcmCaptureWorkletOptions): Effect.Effect<void, AudioUnsupportedError | AudioWorkletError>;
|
|
181
|
+
/**
|
|
182
|
+
* Passively taps any `AudioNode` (e.g. from `getMediaElementSourceNode` or
|
|
183
|
+
* `acquireInputCapture`) into a rolling mono PCM window via the allocation-free
|
|
184
|
+
* `pcm-capture` AudioWorklet, so live audio can be fingerprinted with
|
|
185
|
+
* `capture.fingerprint()`. Fully torn down when the owning `Scope` closes.
|
|
186
|
+
*/
|
|
187
|
+
export declare function acquirePcmCapture(context: BaseAudioContext, source: AudioNode, options?: PcmCaptureOptions): Effect.Effect<PcmCapture, AudioCaptureError | AudioUnsupportedError | AudioWorkletError, Scope.Scope>;
|
|
188
|
+
export declare const SILENT_WAV_SAMPLE_RATE = 8000;
|
|
189
|
+
export declare const SILENT_WAV_DURATION_SECONDS = 10;
|
|
190
|
+
export declare const SILENT_WAV_HEADER_BYTES = 44;
|
|
191
|
+
export declare function sanitizeForBluetooth(input: string | null | undefined, fallback?: string): string;
|
|
192
|
+
export declare function createSilentWavBytes(durationSeconds?: number, sampleRate?: number): Uint8Array;
|
|
193
|
+
export declare function createSilentWavBlob(durationSeconds?: number, sampleRate?: number): Blob;
|
|
194
|
+
interface MediaSessionMetadataInput {
|
|
195
|
+
readonly title: string;
|
|
196
|
+
readonly artist?: string;
|
|
197
|
+
readonly album?: string;
|
|
198
|
+
readonly artwork?: readonly MediaImage[];
|
|
199
|
+
}
|
|
200
|
+
interface MediaSessionHandlers {
|
|
201
|
+
readonly play?: () => void;
|
|
202
|
+
readonly pause?: () => void;
|
|
203
|
+
readonly stop?: () => void;
|
|
204
|
+
readonly previoustrack?: () => void;
|
|
205
|
+
readonly nexttrack?: () => void;
|
|
206
|
+
readonly seekbackward?: (details: MediaSessionActionDetails) => void;
|
|
207
|
+
readonly seekforward?: (details: MediaSessionActionDetails) => void;
|
|
208
|
+
readonly seekto?: (details: MediaSessionActionDetails) => void;
|
|
209
|
+
}
|
|
210
|
+
interface MediaSessionControllerOptions {
|
|
211
|
+
readonly sanitizeAvrcp?: boolean;
|
|
212
|
+
readonly avrcpFallback?: string;
|
|
213
|
+
readonly enableKeepAlive?: boolean;
|
|
214
|
+
readonly mediaSession?: MediaSession;
|
|
215
|
+
readonly createKeepAliveElement?: () => HTMLAudioElement;
|
|
216
|
+
}
|
|
217
|
+
interface MediaSessionController {
|
|
218
|
+
readonly setMetadata: (metadata: MediaSessionMetadataInput) => void;
|
|
219
|
+
readonly setPlaybackState: (state: MediaSessionPlaybackState) => void;
|
|
220
|
+
readonly setPositionState: (state: {
|
|
221
|
+
readonly duration?: number;
|
|
222
|
+
readonly position?: number;
|
|
223
|
+
readonly playbackRate?: number;
|
|
224
|
+
readonly isLive?: boolean;
|
|
225
|
+
}) => void;
|
|
226
|
+
readonly setHandlers: (handlers: MediaSessionHandlers) => void;
|
|
227
|
+
readonly startKeepAlive: () => Effect.Effect<void>;
|
|
228
|
+
readonly stopKeepAlive: () => void;
|
|
229
|
+
readonly dispose: () => void;
|
|
230
|
+
}
|
|
231
|
+
export declare function createMediaSessionController(options?: MediaSessionControllerOptions): Effect.Effect<MediaSessionController, never, Scope.Scope>;
|
|
232
|
+
export declare const SAMPLE_MIME_TYPES: {
|
|
233
|
+
readonly mp3: "audio/mpeg";
|
|
234
|
+
readonly ogg: "audio/ogg";
|
|
235
|
+
readonly wav: "audio/wav";
|
|
236
|
+
};
|
|
237
|
+
export declare const SAMPLE_KEY_PATTERN: RegExp;
|
|
238
|
+
export declare const SAMPLER_MIN_SLICE_DURATION = 0.1;
|
|
239
|
+
export declare const SAMPLER_MAX_SLICE_DURATION = 2;
|
|
240
|
+
export declare const SAMPLER_RELEASE_SECONDS = 1;
|
|
241
|
+
export declare const SAMPLER_VOLUME_RAMP_SECONDS = 0.05;
|
|
242
|
+
export declare const SAMPLER_DEFAULT_BATCH_SIZE = 4;
|
|
243
|
+
interface SamplerOptions {
|
|
244
|
+
readonly destination?: AudioNode;
|
|
245
|
+
readonly initialVolume?: number;
|
|
246
|
+
readonly fetchImpl?: typeof fetch;
|
|
247
|
+
readonly random?: () => number;
|
|
248
|
+
}
|
|
249
|
+
interface SlicePlaybackOptions {
|
|
250
|
+
readonly offsetSeconds?: number;
|
|
251
|
+
readonly durationSeconds?: number;
|
|
252
|
+
readonly attackSeconds?: number;
|
|
253
|
+
readonly releaseSeconds?: number;
|
|
254
|
+
readonly gain?: number;
|
|
255
|
+
readonly playbackRate?: number;
|
|
256
|
+
}
|
|
257
|
+
interface RandomSliceOptions {
|
|
258
|
+
readonly minDurationSeconds?: number;
|
|
259
|
+
readonly maxDurationSeconds?: number;
|
|
260
|
+
readonly releaseSeconds?: number;
|
|
261
|
+
readonly gain?: number;
|
|
262
|
+
}
|
|
263
|
+
interface SampleLoadEntry {
|
|
264
|
+
readonly key: string;
|
|
265
|
+
readonly url: string;
|
|
266
|
+
}
|
|
267
|
+
interface SampleBatchLoadResult {
|
|
268
|
+
readonly loaded: readonly string[];
|
|
269
|
+
readonly failed: readonly {
|
|
270
|
+
readonly key: string;
|
|
271
|
+
readonly error: string;
|
|
272
|
+
}[];
|
|
273
|
+
}
|
|
274
|
+
interface ActiveSliceHandle {
|
|
275
|
+
readonly key: string;
|
|
276
|
+
readonly offsetSeconds: number;
|
|
277
|
+
readonly durationSeconds: number;
|
|
278
|
+
readonly stop: () => void;
|
|
279
|
+
}
|
|
280
|
+
interface BufferSampler {
|
|
281
|
+
readonly masterGain: GainNode;
|
|
282
|
+
readonly registerBuffer: (key: string, buffer: AudioBuffer) => void;
|
|
283
|
+
readonly getBuffer: (key: string) => AudioBuffer | undefined;
|
|
284
|
+
readonly keys: () => readonly string[];
|
|
285
|
+
readonly loadBuffer: (key: string, url: string) => Effect.Effect<AudioBuffer, AudioDecodeError>;
|
|
286
|
+
readonly loadBatch: (entries: readonly SampleLoadEntry[], batchSize?: number) => Effect.Effect<SampleBatchLoadResult>;
|
|
287
|
+
readonly playSlice: (key: string, options?: SlicePlaybackOptions) => ActiveSliceHandle | undefined;
|
|
288
|
+
readonly playRandom: (options?: RandomSliceOptions) => ActiveSliceHandle | undefined;
|
|
289
|
+
readonly setVolume: (value: number) => number;
|
|
290
|
+
readonly activeVoiceCount: () => number;
|
|
291
|
+
readonly stopAll: () => void;
|
|
292
|
+
readonly dispose: () => void;
|
|
293
|
+
}
|
|
294
|
+
export declare function createSampler(context: BaseAudioContext, options?: SamplerOptions): BufferSampler;
|
|
295
|
+
export type { ActiveSliceHandle, AudioContextHandle, AudioContextLayerOptions, AudioContextOptionsInput, AudioContextSnapshot, BufferSampler, ChannelSelection, DeviceCaptureOptions, DisplayAudioOptions, LiveInputCapture, LoadPcmCaptureWorkletOptions, MediaElementSourceOptions, MediaElementSourceTarget, MediaEngine, MediaEngineLoadOptions, MediaEngineOptions, MediaEngineSnapshot, MediaSessionController, MediaSessionControllerOptions, MediaSessionHandlers, MediaSessionMetadataInput, PcmCapture, PcmCaptureOptions, RandomSliceOptions, SampleBatchLoadResult, SampleLoadEntry, SamplerOptions, SlicePlaybackOptions, StallRecoveryConfig };
|