@galacean/engine-core 1.6.12 → 1.6.13
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/dist/main.js +58 -39
- package/dist/main.js.map +1 -1
- package/dist/module.js +58 -39
- package/dist/module.js.map +1 -1
- package/package.json +3 -3
- package/types/audio/AudioManager.d.ts +14 -1
- package/types/audio/AudioSource.d.ts +2 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@galacean/engine-core",
|
|
3
|
-
"version": "1.6.
|
|
3
|
+
"version": "1.6.13",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public",
|
|
6
6
|
"registry": "https://registry.npmjs.org"
|
|
@@ -18,10 +18,10 @@
|
|
|
18
18
|
"types/**/*"
|
|
19
19
|
],
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@galacean/engine-math": "1.6.
|
|
21
|
+
"@galacean/engine-math": "1.6.13"
|
|
22
22
|
},
|
|
23
23
|
"devDependencies": {
|
|
24
|
-
"@galacean/engine-design": "1.6.
|
|
24
|
+
"@galacean/engine-design": "1.6.13"
|
|
25
25
|
},
|
|
26
26
|
"scripts": {
|
|
27
27
|
"b:types": "tsc"
|
|
@@ -1 +1,14 @@
|
|
|
1
|
-
|
|
1
|
+
/**
|
|
2
|
+
* Audio Manager for managing global audio context and settings.
|
|
3
|
+
*/
|
|
4
|
+
export declare class AudioManager {
|
|
5
|
+
private static _context;
|
|
6
|
+
private static _gainNode;
|
|
7
|
+
private static _resumePromise;
|
|
8
|
+
/**
|
|
9
|
+
* Resume the audio context.
|
|
10
|
+
* @remarks On iOS Safari, calling this within a user gesture (e.g., click/touch event handler) can pre-unlock audio and reduce playback delay.
|
|
11
|
+
* @returns A promise that resolves when the audio context is resumed
|
|
12
|
+
*/
|
|
13
|
+
static resume(): Promise<void>;
|
|
14
|
+
}
|
|
@@ -7,6 +7,7 @@ export declare class AudioSource extends Component {
|
|
|
7
7
|
/** If set to true, the audio component automatically begins to play on startup. */
|
|
8
8
|
playOnEnabled: boolean;
|
|
9
9
|
private _isPlaying;
|
|
10
|
+
private _pendingPlay;
|
|
10
11
|
private _clip;
|
|
11
12
|
private _gainNode;
|
|
12
13
|
private _sourceNode;
|
|
@@ -66,7 +67,7 @@ export declare class AudioSource extends Component {
|
|
|
66
67
|
*/
|
|
67
68
|
pause(): void;
|
|
68
69
|
private _onPlayEnd;
|
|
70
|
+
private _startPlayback;
|
|
69
71
|
private _initSourceNode;
|
|
70
72
|
private _clearSourceNode;
|
|
71
|
-
private _canPlay;
|
|
72
73
|
}
|