@grame/faustwasm 0.0.65 → 0.0.67

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/TODO.md ADDED
@@ -0,0 +1,5 @@
1
+ # Soundfile handling
2
+
3
+ - la memoire wasm doit être allouée en extene dès qu'il y a des `soundfile` dans le DSP.
4
+
5
+ - actuellement **createMemoryAux** est utilisé pour le mode polyphoncique, il faudra en faire un pour le mode mono on avec soundfile
@@ -131,6 +131,7 @@ export interface FaustUIInputItem {
131
131
  type: FaustUIInputType;
132
132
  label: string;
133
133
  address: string;
134
+ url: string;
134
135
  index: number;
135
136
  init?: number;
136
137
  min?: number;
@@ -158,7 +159,7 @@ export interface FaustUIMeta {
158
159
  }
159
160
  export type FaustUIGroupType = "vgroup" | "hgroup" | "tgroup";
160
161
  export type FaustUIOutputType = "hbargraph" | "vbargraph";
161
- export type FaustUIInputType = "vslider" | "hslider" | "button" | "checkbox" | "nentry";
162
+ export type FaustUIInputType = "vslider" | "hslider" | "button" | "checkbox" | "nentry" | "soundfile";
162
163
  export interface FaustUIGroup {
163
164
  type: FaustUIGroupType;
164
165
  label: string;
@@ -767,7 +768,8 @@ export interface FaustFFTAudioWorkletProcessorOptions {
767
768
  }
768
769
  export declare const getFaustFFTAudioWorkletProcessor: (dependencies: FaustFFTAudioWorkletProcessorDependencies, faustData: FaustFFTData, register?: boolean) => {
769
770
  new (options: AudioWorkletNodeOptions): AudioWorkletProcessor;
770
- prototype: AudioWorkletProcessor; /** Generated from the current window function */
771
+ /** Generated from the current window function */
772
+ prototype: AudioWorkletProcessor;
771
773
  parameterDescriptors: AudioParamDescriptor[];
772
774
  };
773
775
  export interface ILibFaust extends LibFaustWasm {
@@ -1000,8 +1002,8 @@ export interface IFaustCmajor {
1000
1002
  compile(name: string, code: string, args: string): string;
1001
1003
  }
1002
1004
  export declare class FaustCmajor implements IFaustCmajor {
1003
- private compiler;
1004
- constructor(compiler: FaustCompiler);
1005
+ private fLibFaust;
1006
+ constructor(libfaust: LibFaust);
1005
1007
  compile(name: string, code: string, args: string): string;
1006
1008
  }
1007
1009
  export interface WavEncoderOptions {
@@ -2753,12 +2753,12 @@ var FaustSvgDiagrams_default = FaustSvgDiagrams;
2753
2753
 
2754
2754
  // src/FaustCmajor.ts
2755
2755
  var FaustCmajor = class {
2756
- constructor(compiler) {
2757
- this.compiler = compiler;
2756
+ constructor(libfaust) {
2757
+ this.fLibFaust = libfaust;
2758
2758
  }
2759
2759
  compile(name, code, args) {
2760
- const fs = this.compiler.fs();
2761
- const success = this.compiler.generateAuxFiles(name, code, `-lang cmajor-hybrid -cn ${name} -o ${name}.cmajor`);
2760
+ const fs = this.fLibFaust.fs();
2761
+ const success = this.fLibFaust.generateAuxFiles(name, code, `-lang cmajor-hybrid -cn ${name} -o ${name}.cmajor`);
2762
2762
  return success ? fs.readFile(`${name}.cmajor`, { encoding: "utf8" }) : "";
2763
2763
  }
2764
2764
  };