@galacean/engine-core 2.0.0-alpha.1 → 2.0.0-alpha.2
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 +6 -0
- package/dist/main.js.map +1 -1
- package/dist/module.js +6 -0
- package/dist/module.js.map +1 -1
- package/package.json +3 -3
- package/types/audio/AudioManager.d.ts +5 -0
package/dist/module.js
CHANGED
|
@@ -37545,6 +37545,12 @@ var cacheDir = new Vector3();
|
|
|
37545
37545
|
*/ var AudioManager = /*#__PURE__*/ function() {
|
|
37546
37546
|
function AudioManager() {}
|
|
37547
37547
|
/**
|
|
37548
|
+
* Suspend the audio context.
|
|
37549
|
+
* @returns A promise that resolves when the audio context is suspended
|
|
37550
|
+
*/ AudioManager.suspend = function suspend() {
|
|
37551
|
+
return AudioManager._context.suspend();
|
|
37552
|
+
};
|
|
37553
|
+
/**
|
|
37548
37554
|
* Resume the audio context.
|
|
37549
37555
|
* @remarks On iOS Safari, calling this within a user gesture (e.g., click/touch event handler) can pre-unlock audio and reduce playback delay.
|
|
37550
37556
|
* @returns A promise that resolves when the audio context is resumed
|