@akashic/headless-driver 2.2.4 → 2.3.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/lib/runner/v3/platform/NodeCanvasResourceFactory.d.ts +1 -1
- package/lib/runner/v3/platform/NodeCanvasResourceFactory.js +2 -2
- package/lib/runner/v3/platform/NullResourceFactory.d.ts +1 -1
- package/lib/runner/v3/platform/NullResourceFactory.js +2 -2
- package/lib/runner/v3/platform/audios/NullAudioAsset.d.ts +2 -1
- package/lib/runner/v3/platform/audios/NullAudioAsset.js +2 -1
- package/package.json +4 -4
|
@@ -13,7 +13,7 @@ export declare class NodeCanvasResourceFactory implements g.ResourceFactory {
|
|
|
13
13
|
constructor({ loadFileHandler, errorHandler }: NodeCanvasResourceFactoryParameters);
|
|
14
14
|
createImageAsset(id: string, assetPath: string, width: number, height: number): g.ImageAsset;
|
|
15
15
|
createVideoAsset(id: string, assetPath: string, width: number, height: number, system: g.VideoSystem, loop: boolean, useRealSize: boolean): g.VideoAsset;
|
|
16
|
-
createAudioAsset(id: string, assetPath: string, duration: number, system: g.AudioSystem, loop: boolean, hint: g.AudioAssetHint): g.AudioAsset;
|
|
16
|
+
createAudioAsset(id: string, assetPath: string, duration: number, system: g.AudioSystem, loop: boolean, hint: g.AudioAssetHint, offset?: number): g.AudioAsset;
|
|
17
17
|
createAudioPlayer(system: g.AudioSystem): g.AudioPlayer;
|
|
18
18
|
createTextAsset(id: string, assetPath: string): g.TextAsset;
|
|
19
19
|
createScriptAsset(id: string, assetPath: string): g.ScriptAsset;
|
|
@@ -25,8 +25,8 @@ class NodeCanvasResourceFactory {
|
|
|
25
25
|
createVideoAsset(id, assetPath, width, height, system, loop, useRealSize) {
|
|
26
26
|
return new NullVideoAsset_1.NullVideoAsset(id, assetPath, width, height, system, loop, useRealSize);
|
|
27
27
|
}
|
|
28
|
-
createAudioAsset(id, assetPath, duration, system, loop, hint) {
|
|
29
|
-
return new NullAudioAsset_1.NullAudioAsset(id, assetPath, duration, system, loop, hint);
|
|
28
|
+
createAudioAsset(id, assetPath, duration, system, loop, hint, offset) {
|
|
29
|
+
return new NullAudioAsset_1.NullAudioAsset(id, assetPath, duration, system, loop, hint, offset !== null && offset !== void 0 ? offset : 0);
|
|
30
30
|
}
|
|
31
31
|
createAudioPlayer(system) {
|
|
32
32
|
return new NullAudioPlayer_1.NullAudioPlayer(system);
|
|
@@ -12,7 +12,7 @@ export declare class NullResourceFactory implements g.ResourceFactory {
|
|
|
12
12
|
constructor({ loadFileHandler, errorHandler }: NullResourceFactoryParameters);
|
|
13
13
|
createImageAsset(id: string, assetPath: string, width: number, height: number): g.ImageAsset;
|
|
14
14
|
createVideoAsset(id: string, assetPath: string, width: number, height: number, system: g.VideoSystem, loop: boolean, useRealSize: boolean): g.VideoAsset;
|
|
15
|
-
createAudioAsset(id: string, assetPath: string, duration: number, system: g.AudioSystem, loop: boolean, hint: g.AudioAssetHint): g.AudioAsset;
|
|
15
|
+
createAudioAsset(id: string, assetPath: string, duration: number, system: g.AudioSystem, loop: boolean, hint: g.AudioAssetHint, offset?: number): g.AudioAsset;
|
|
16
16
|
createAudioPlayer(system: g.AudioSystem): g.AudioPlayer;
|
|
17
17
|
createTextAsset(id: string, assetPath: string): g.TextAsset;
|
|
18
18
|
createScriptAsset(id: string, assetPath: string): g.ScriptAsset;
|
|
@@ -23,8 +23,8 @@ class NullResourceFactory {
|
|
|
23
23
|
createVideoAsset(id, assetPath, width, height, system, loop, useRealSize) {
|
|
24
24
|
return new NullVideoAsset_1.NullVideoAsset(id, assetPath, width, height, system, loop, useRealSize);
|
|
25
25
|
}
|
|
26
|
-
createAudioAsset(id, assetPath, duration, system, loop, hint) {
|
|
27
|
-
return new NullAudioAsset_1.NullAudioAsset(id, assetPath, duration, system, loop, hint);
|
|
26
|
+
createAudioAsset(id, assetPath, duration, system, loop, hint, offset) {
|
|
27
|
+
return new NullAudioAsset_1.NullAudioAsset(id, assetPath, duration, system, loop, hint, offset !== null && offset !== void 0 ? offset : 0);
|
|
28
28
|
}
|
|
29
29
|
createAudioPlayer(system) {
|
|
30
30
|
return new NullAudioPlayer_1.NullAudioPlayer(system);
|
|
@@ -7,7 +7,8 @@ export declare class NullAudioAsset extends Asset implements g.AudioAsset {
|
|
|
7
7
|
loop: boolean;
|
|
8
8
|
hint: g.AudioAssetHint;
|
|
9
9
|
_system: g.AudioSystem;
|
|
10
|
-
|
|
10
|
+
offset: number;
|
|
11
|
+
constructor(id: string, assetPath: string, duration: number, system: g.AudioSystem, loop: boolean, hint: g.AudioAssetHint, offset: number);
|
|
11
12
|
_load(loader: g.AssetLoadHandler): void;
|
|
12
13
|
play(): g.AudioPlayer;
|
|
13
14
|
stop(): void;
|
|
@@ -3,13 +3,14 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.NullAudioAsset = void 0;
|
|
4
4
|
const Asset_1 = require("../assets/Asset");
|
|
5
5
|
class NullAudioAsset extends Asset_1.Asset {
|
|
6
|
-
constructor(id, assetPath, duration, system, loop, hint) {
|
|
6
|
+
constructor(id, assetPath, duration, system, loop, hint, offset) {
|
|
7
7
|
super(id, assetPath);
|
|
8
8
|
this.type = "audio";
|
|
9
9
|
this.duration = duration;
|
|
10
10
|
this.loop = loop;
|
|
11
11
|
this.hint = hint;
|
|
12
12
|
this._system = system;
|
|
13
|
+
this.offset = offset;
|
|
13
14
|
this.data = undefined;
|
|
14
15
|
}
|
|
15
16
|
_load(loader) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@akashic/headless-driver",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.3.0",
|
|
4
4
|
"description": "A library to execute contents using Akashic Engine headlessly",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"author": "DWANGO Co., Ltd.",
|
|
@@ -29,14 +29,14 @@
|
|
|
29
29
|
"@akashic/trigger": "^1.0.1",
|
|
30
30
|
"engine-files-v1": "npm:@akashic/engine-files@1.2.1",
|
|
31
31
|
"engine-files-v2": "npm:@akashic/engine-files@2.2.1",
|
|
32
|
-
"engine-files-v3": "npm:@akashic/engine-files@3.
|
|
32
|
+
"engine-files-v3": "npm:@akashic/engine-files@3.4.0",
|
|
33
33
|
"js-sha256": "^0.9.0",
|
|
34
34
|
"lodash.clonedeep": "^4.5.0",
|
|
35
35
|
"node-fetch": "^2.6.7",
|
|
36
36
|
"vm2": "^3.9.11"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
|
-
"@akashic/eslint-config": "^1.1.
|
|
39
|
+
"@akashic/eslint-config": "^1.1.1",
|
|
40
40
|
"@akashic/remark-preset-lint": "^0.1.2",
|
|
41
41
|
"@types/jest": "^29.1.1",
|
|
42
42
|
"@types/lodash.clonedeep": "^4.5.7",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"eslint": "^8.24.0",
|
|
49
49
|
"eslint-config-prettier": "^8.5.0",
|
|
50
50
|
"eslint-plugin-import": "^2.26.0",
|
|
51
|
-
"eslint-plugin-jest": "^
|
|
51
|
+
"eslint-plugin-jest": "^27.0.0",
|
|
52
52
|
"get-port": "^5.1.1",
|
|
53
53
|
"image-size": "^1.0.2",
|
|
54
54
|
"jest": "^29.1.2",
|