timed-audio-buffer-source-node-audio-worklet 2.1.12 → 2.1.14
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.
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const worklet = "(()=>{\"use strict\";class e extends AudioWorkletProcessor{constructor(
|
|
1
|
+
export declare const worklet = "(()=>{\"use strict\";class e extends AudioWorkletProcessor{constructor({numberOfInputs:e,numberOfOutputs:t,outputChannelCount:o,processorOptions:r}){var n;const s=\"object\"==typeof r&&null!==r&&\"buffer\"in r?r.buffer:null;if(!(null===s||Array.isArray(s)&&s.every((e=>e instanceof Float32Array))))throw new Error(\"The buffer needs to be either null or an array with where each element is a Float32Array.\");if(1!==e)throw new Error(\"The numberOfInputs must be 1.\");if(1!==t)throw new Error(\"The numberOfOutputs must be 1.\");const i=null!==(n=null==s?void 0:s.length)&&void 0!==n?n:1;if(void 0===o||1!==o.length||i!==o[0])throw new Error(\"The outputChannelCount must match the number of channels of the buffer.\");const u=\"object\"==typeof r&&null!==r&&\"position\"in r?r.position:0;if(\"number\"!=typeof u)throw new Error('The position needs to be of type \"number\".');const h=\"object\"==typeof r&&null!==r&&\"timestamp\"in r?r.timestamp:0;if(\"number\"!=typeof h)throw new Error('The timestamp needs to be of type \"number\".');const l=\"object\"==typeof r&&null!==r&&\"velocity\"in r?r.velocity:0;if(![0,1].includes(l))throw new Error(\"The velocity needs to be either 0 or 1.\");super(),this._buffer=s,this._position=u,this._timestamp=h,this._velocity=l}process([e],[t]){if((null==e?void 0:e.length)>0){const[t]=e;t.length>1&&(this._position=Math.round(t[0]),this._timestamp=Math.round(t[1]),this._velocity=Math.round(t[2]))}if(null!==this._buffer){const e=this._buffer.length;for(let o=0;o<e;o+=1){const e=this._buffer[o],r=t[o];for(let t=0;t<128;t+=1){const o=this._position+(currentFrame-this._timestamp+t)*this._velocity;o>=0&&o<e.length&&(r[t]=e[o])}}}return!0}}e.parameterDescriptors=[],registerProcessor(\"timed-audio-buffer-source-node-audio-worklet-processor\",e)})();";
|
|
2
2
|
//# sourceMappingURL=worklet.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"worklet.d.ts","sourceRoot":"","sources":["../../../src/worklet/worklet.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,OAAO,
|
|
1
|
+
{"version":3,"file":"worklet.d.ts","sourceRoot":"","sources":["../../../src/worklet/worklet.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,OAAO,mwDAA6tD,CAAC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
// This is the minified and stringified code of the timed-audio-buffer-source-node-audio-worklet-processor package.
|
|
2
|
-
export const worklet = `(()=>{"use strict";class e extends AudioWorkletProcessor{constructor(
|
|
2
|
+
export const worklet = `(()=>{"use strict";class e extends AudioWorkletProcessor{constructor({numberOfInputs:e,numberOfOutputs:t,outputChannelCount:o,processorOptions:r}){var n;const s="object"==typeof r&&null!==r&&"buffer"in r?r.buffer:null;if(!(null===s||Array.isArray(s)&&s.every((e=>e instanceof Float32Array))))throw new Error("The buffer needs to be either null or an array with where each element is a Float32Array.");if(1!==e)throw new Error("The numberOfInputs must be 1.");if(1!==t)throw new Error("The numberOfOutputs must be 1.");const i=null!==(n=null==s?void 0:s.length)&&void 0!==n?n:1;if(void 0===o||1!==o.length||i!==o[0])throw new Error("The outputChannelCount must match the number of channels of the buffer.");const u="object"==typeof r&&null!==r&&"position"in r?r.position:0;if("number"!=typeof u)throw new Error('The position needs to be of type "number".');const h="object"==typeof r&&null!==r&&"timestamp"in r?r.timestamp:0;if("number"!=typeof h)throw new Error('The timestamp needs to be of type "number".');const l="object"==typeof r&&null!==r&&"velocity"in r?r.velocity:0;if(![0,1].includes(l))throw new Error("The velocity needs to be either 0 or 1.");super(),this._buffer=s,this._position=u,this._timestamp=h,this._velocity=l}process([e],[t]){if((null==e?void 0:e.length)>0){const[t]=e;t.length>1&&(this._position=Math.round(t[0]),this._timestamp=Math.round(t[1]),this._velocity=Math.round(t[2]))}if(null!==this._buffer){const e=this._buffer.length;for(let o=0;o<e;o+=1){const e=this._buffer[o],r=t[o];for(let t=0;t<128;t+=1){const o=this._position+(currentFrame-this._timestamp+t)*this._velocity;o>=0&&o<e.length&&(r[t]=e[o])}}}return!0}}e.parameterDescriptors=[],registerProcessor("timed-audio-buffer-source-node-audio-worklet-processor",e)})();`; // tslint:disable-line:max-line-length
|
|
3
3
|
//# sourceMappingURL=worklet.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"worklet.js","sourceRoot":"","sources":["../../../src/worklet/worklet.ts"],"names":[],"mappings":"AAAA,mHAAmH;AACnH,MAAM,CAAC,MAAM,OAAO,GAAG,
|
|
1
|
+
{"version":3,"file":"worklet.js","sourceRoot":"","sources":["../../../src/worklet/worklet.ts"],"names":[],"mappings":"AAAA,mHAAmH;AACnH,MAAM,CAAC,MAAM,OAAO,GAAG,0tDAA0tD,CAAC,CAAC,sCAAsC"}
|
package/package.json
CHANGED
|
@@ -9,32 +9,32 @@
|
|
|
9
9
|
}
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@babel/runtime": "^7.25.
|
|
12
|
+
"@babel/runtime": "^7.25.7",
|
|
13
13
|
"standardized-audio-context": "^25.3.77",
|
|
14
|
-
"timed-audio-buffer-source-node-audio-worklet-processor": "^2.1.
|
|
15
|
-
"timing-object": "^3.1.
|
|
16
|
-
"tslib": "^2.
|
|
14
|
+
"timed-audio-buffer-source-node-audio-worklet-processor": "^2.1.11",
|
|
15
|
+
"timing-object": "^3.1.83",
|
|
16
|
+
"tslib": "^2.8.0"
|
|
17
17
|
},
|
|
18
18
|
"description": "This module provides a loader for the TimedAudioBufferSourceNodeAudioWorkletProcessor and the corresponding TimedAudioBufferSourceNodeAudioWorkletNode.",
|
|
19
19
|
"devDependencies": {
|
|
20
|
-
"@babel/core": "^7.25.
|
|
21
|
-
"@babel/plugin-external-helpers": "^7.
|
|
22
|
-
"@babel/plugin-transform-runtime": "^7.25.
|
|
23
|
-
"@babel/preset-env": "^7.25.
|
|
24
|
-
"@commitlint/cli": "^19.
|
|
25
|
-
"@commitlint/config-angular": "^19.
|
|
20
|
+
"@babel/core": "^7.25.8",
|
|
21
|
+
"@babel/plugin-external-helpers": "^7.25.7",
|
|
22
|
+
"@babel/plugin-transform-runtime": "^7.25.7",
|
|
23
|
+
"@babel/preset-env": "^7.25.8",
|
|
24
|
+
"@commitlint/cli": "^19.5.0",
|
|
25
|
+
"@commitlint/config-angular": "^19.5.0",
|
|
26
26
|
"@rollup/plugin-babel": "^6.0.4",
|
|
27
|
-
"@rollup/plugin-replace": "^
|
|
28
|
-
"babel-loader": "^9.1
|
|
27
|
+
"@rollup/plugin-replace": "^6.0.1",
|
|
28
|
+
"babel-loader": "^9.2.1",
|
|
29
29
|
"chai": "^4.3.10",
|
|
30
|
-
"commitizen": "^4.3.
|
|
30
|
+
"commitizen": "^4.3.1",
|
|
31
31
|
"cz-conventional-changelog": "^3.3.0",
|
|
32
32
|
"eslint": "^8.57.0",
|
|
33
|
-
"eslint-config-holy-grail": "^
|
|
33
|
+
"eslint-config-holy-grail": "^60.0.10",
|
|
34
34
|
"grunt": "^1.6.1",
|
|
35
35
|
"grunt-cli": "^1.5.0",
|
|
36
36
|
"grunt-sh": "^0.2.1",
|
|
37
|
-
"husky": "^
|
|
37
|
+
"husky": "^9.1.6",
|
|
38
38
|
"karma": "^6.4.4",
|
|
39
39
|
"karma-chrome-launcher": "^3.2.0",
|
|
40
40
|
"karma-firefox-launcher": "^2.1.3",
|
|
@@ -45,20 +45,20 @@
|
|
|
45
45
|
"karma-webpack": "^5.0.1",
|
|
46
46
|
"lint-staged": "^15.2.10",
|
|
47
47
|
"load-grunt-config": "^4.0.1",
|
|
48
|
-
"memfs": "^4.
|
|
48
|
+
"memfs": "^4.14.0",
|
|
49
49
|
"mocha": "^10.7.3",
|
|
50
50
|
"prettier": "^3.3.3",
|
|
51
51
|
"rimraf": "^6.0.1",
|
|
52
|
-
"rollup": "^4.
|
|
52
|
+
"rollup": "^4.24.0",
|
|
53
53
|
"sinon": "^17.0.1",
|
|
54
54
|
"sinon-chai": "^3.7.0",
|
|
55
55
|
"terser-webpack-plugin": "^5.3.10",
|
|
56
56
|
"ts-loader": "^9.5.1",
|
|
57
57
|
"tsconfig-holy-grail": "^15.0.1",
|
|
58
58
|
"tslint": "^6.1.3",
|
|
59
|
-
"tslint-config-holy-grail": "^56.0.
|
|
60
|
-
"typescript": "^5.
|
|
61
|
-
"webpack": "^5.
|
|
59
|
+
"tslint-config-holy-grail": "^56.0.4",
|
|
60
|
+
"typescript": "^5.6.3",
|
|
61
|
+
"webpack": "^5.95.0",
|
|
62
62
|
"webpack-cli": "^5.1.4"
|
|
63
63
|
},
|
|
64
64
|
"files": [
|
|
@@ -81,10 +81,10 @@
|
|
|
81
81
|
"lint:config": "eslint --config config/eslint/config.json --ext .js --report-unused-disable-directives config/",
|
|
82
82
|
"lint:src": "tslint --config config/tslint/src.json --project src/tsconfig.json src/*.ts src/**/*.ts",
|
|
83
83
|
"lint:test": "eslint --config config/eslint/test.json --ext .js --report-unused-disable-directives test/",
|
|
84
|
-
"prepare": "husky
|
|
84
|
+
"prepare": "husky",
|
|
85
85
|
"prepublishOnly": "npm run build",
|
|
86
86
|
"test": "grunt lint && grunt test"
|
|
87
87
|
},
|
|
88
88
|
"types": "build/es2019/module.d.ts",
|
|
89
|
-
"version": "2.1.
|
|
89
|
+
"version": "2.1.14"
|
|
90
90
|
}
|
package/src/worklet/worklet.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// This is the minified and stringified code of the timed-audio-buffer-source-node-audio-worklet-processor package.
|
|
2
|
-
export const worklet = `(()=>{"use strict";class e extends AudioWorkletProcessor{constructor(
|
|
2
|
+
export const worklet = `(()=>{"use strict";class e extends AudioWorkletProcessor{constructor({numberOfInputs:e,numberOfOutputs:t,outputChannelCount:o,processorOptions:r}){var n;const s="object"==typeof r&&null!==r&&"buffer"in r?r.buffer:null;if(!(null===s||Array.isArray(s)&&s.every((e=>e instanceof Float32Array))))throw new Error("The buffer needs to be either null or an array with where each element is a Float32Array.");if(1!==e)throw new Error("The numberOfInputs must be 1.");if(1!==t)throw new Error("The numberOfOutputs must be 1.");const i=null!==(n=null==s?void 0:s.length)&&void 0!==n?n:1;if(void 0===o||1!==o.length||i!==o[0])throw new Error("The outputChannelCount must match the number of channels of the buffer.");const u="object"==typeof r&&null!==r&&"position"in r?r.position:0;if("number"!=typeof u)throw new Error('The position needs to be of type "number".');const h="object"==typeof r&&null!==r&&"timestamp"in r?r.timestamp:0;if("number"!=typeof h)throw new Error('The timestamp needs to be of type "number".');const l="object"==typeof r&&null!==r&&"velocity"in r?r.velocity:0;if(![0,1].includes(l))throw new Error("The velocity needs to be either 0 or 1.");super(),this._buffer=s,this._position=u,this._timestamp=h,this._velocity=l}process([e],[t]){if((null==e?void 0:e.length)>0){const[t]=e;t.length>1&&(this._position=Math.round(t[0]),this._timestamp=Math.round(t[1]),this._velocity=Math.round(t[2]))}if(null!==this._buffer){const e=this._buffer.length;for(let o=0;o<e;o+=1){const e=this._buffer[o],r=t[o];for(let t=0;t<128;t+=1){const o=this._position+(currentFrame-this._timestamp+t)*this._velocity;o>=0&&o<e.length&&(r[t]=e[o])}}}return!0}}e.parameterDescriptors=[],registerProcessor("timed-audio-buffer-source-node-audio-worklet-processor",e)})();`; // tslint:disable-line:max-line-length
|