@grame/faustwasm 0.0.54 → 0.0.56

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@grame/faustwasm",
3
- "version": "0.0.54",
3
+ "version": "0.0.56",
4
4
  "description": "WebAssembly version of Faust Compiler",
5
5
  "main": "dist/cjs/index.js",
6
6
  "types": "dist/esm/index.d.ts",
@@ -397,7 +397,7 @@ export class FaustPolyDspGenerator implements IFaustPolyDspGenerator {
397
397
  name: string,
398
398
  dspCode: string,
399
399
  args: string,
400
- // The ${dspCode} has to be added with wrapping new lines to make is properly formatted and compile
400
+ // The ${dspCode} has to be added with wrapping new lines to make it properly formatted and ready to compile
401
401
  effectCode = `
402
402
  adapt(1,1) = _;
403
403
  adapt(2,2) = _,_;
@@ -411,7 +411,7 @@ export class FaustPolyDspGenerator implements IFaustPolyDspGenerator {
411
411
  ) {
412
412
  this.voiceFactory = await compiler.createPolyDSPFactory(name, dspCode, args);
413
413
  if (!this.voiceFactory) return null;
414
- // Compile effect, possibly failing since 'compilePolyNode2' can be called by 'compilePolyNode'
414
+ // Compile effect, possibly failing
415
415
  try {
416
416
  this.effectFactory = await compiler.createPolyDSPFactory(name, effectCode, args);
417
417
  } catch (e) {
@@ -2457,11 +2457,8 @@ this.fAudioMixingHalf: ${this.fAudioMixingHalf}`;
2457
2457
  }
2458
2458
  }
2459
2459
  });
2460
- if (this.fInstance.effectAPI) {
2461
- console.log("effectAPI.getNumInputs() = %d", this.fInstance.effectAPI.getNumInputs(this.fEffect));
2462
- console.log("effectAPI.getNumOutputs() = %d", this.fInstance.effectAPI.getNumOutputs(this.fEffect));
2460
+ if (this.fInstance.effectAPI)
2463
2461
  this.fInstance.effectAPI.compute(this.fEffect, this.fBufferSize, this.fAudioOutputs, this.fAudioOutputs);
2464
- }
2465
2462
  this.updateOutputs();
2466
2463
  if (output !== void 0) {
2467
2464
  for (let chan = 0; chan < Math.min(this.getNumOutputs(), output.length); chan++) {
@@ -2479,11 +2476,7 @@ this.fAudioMixingHalf: ${this.fAudioMixingHalf}`;
2479
2476
  return this.fInstance.voiceAPI.getNumInputs(0);
2480
2477
  }
2481
2478
  getNumOutputs() {
2482
- if (this.fInstance.effectAPI) {
2483
- console.log("effectAPI.getNumOutputs() = %d", this.fInstance.effectAPI.getNumOutputs(this.fEffect));
2484
- console.log("VOICE.getNumOutputs() = %d", this.fInstance.voiceAPI.getNumOutputs(0));
2485
- }
2486
- return this.fInstance.effectAPI ? this.fInstance.effectAPI.getNumOutputs(this.fEffect) : this.fInstance.voiceAPI.getNumOutputs(0);
2479
+ return this.fInstance.voiceAPI.getNumOutputs(0);
2487
2480
  }
2488
2481
  static findPath(o, p) {
2489
2482
  if (typeof o !== "object") {