faust-loader
Version:
Webpack loader for Faust .dsp files
48 lines (47 loc) • 3.23 kB
TypeScript
import { IAudioContext } from "standardized-audio-context";
export default function loadProcessor(context: IAudioContext, name: string, wasmUrl: string, processorUrl: string): Promise<{
json: string;
json_object: Record<string, any>;
handleMessage(event: any): void;
destroy(): void;
getJSON(): string;
getMetadata(): Promise<unknown>;
setParamValue(path: any, val: any): void;
setParam(path: any, val: any): void;
getParamValue(path: string): number;
getParam(path: string): number;
setOutputParamHandler(handler: any): void;
getOutputParamHandler(): any;
getNumInputs(): number;
getNumOutputs(): number;
inputChannelCount(): number;
outputChannelCount(): number;
getParams(): any;
getDescriptor(): {};
ctrlChange(channel: any, ctrl: any, value: any): void;
pitchWheel(channel: any, wheel: any): void;
midiMessage(data: any): void;
onMidi(data: any): void;
getState(): Promise<unknown>;
setState(state: any): Promise<unknown>;
setPatch(patch: any): void;
onprocessorerror: import("standardized-audio-context").TErrorEventHandler<any> | null;
readonly parameters: import("standardized-audio-context").TAudioParamMap;
readonly port: MessagePort;
channelCount: number;
channelCountMode: import("standardized-audio-context").TChannelCountMode;
channelInterpretation: import("standardized-audio-context").TChannelInterpretation;
readonly context: IAudioContext;
readonly numberOfInputs: number;
readonly numberOfOutputs: number;
connect<U extends import("standardized-audio-context").TContext, OtherEventMap extends Record<string, Event>, V extends import("standardized-audio-context").IAudioNode<U, OtherEventMap>>(destinationNode: V, output?: number | undefined, input?: number | undefined): V;
connect(destinationParam: import("standardized-audio-context").IAudioParam, output?: number | undefined): void;
disconnect(output?: number | undefined): void;
disconnect<U_1 extends import("standardized-audio-context").TContext, OtherEventMap_1 extends Record<string, Event>>(destinationNode: import("standardized-audio-context").IAudioNode<U_1, OtherEventMap_1>, output?: number | undefined, input?: number | undefined): void;
disconnect(destinationParam: import("standardized-audio-context").IAudioParam, output?: number | undefined): void;
addEventListener<Type extends string | number>(type: Type, listener: (this: any, event: import("standardized-audio-context").IAudioWorkletNodeEventMap[Type]) => void, options?: boolean | AddEventListenerOptions | undefined): void;
addEventListener(type: string, listener: EventListenerOrEventListenerObject | null, options?: boolean | AddEventListenerOptions | undefined): void;
removeEventListener<Type_1 extends string | number>(type: Type_1, listener: (this: any, event: import("standardized-audio-context").IAudioWorkletNodeEventMap[Type_1]) => void, options?: boolean | EventListenerOptions | undefined): void;
removeEventListener(type: string, callback: EventListenerOrEventListenerObject | null, options?: boolean | EventListenerOptions | undefined): void;
dispatchEvent(event: Event): boolean;
} | null>;