@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/main.js
CHANGED
|
@@ -37549,6 +37549,12 @@ var cacheDir = new engineMath.Vector3();
|
|
|
37549
37549
|
*/ var AudioManager = /*#__PURE__*/ function() {
|
|
37550
37550
|
function AudioManager() {}
|
|
37551
37551
|
/**
|
|
37552
|
+
* Suspend the audio context.
|
|
37553
|
+
* @returns A promise that resolves when the audio context is suspended
|
|
37554
|
+
*/ AudioManager.suspend = function suspend() {
|
|
37555
|
+
return AudioManager._context.suspend();
|
|
37556
|
+
};
|
|
37557
|
+
/**
|
|
37552
37558
|
* Resume the audio context.
|
|
37553
37559
|
* @remarks On iOS Safari, calling this within a user gesture (e.g., click/touch event handler) can pre-unlock audio and reduce playback delay.
|
|
37554
37560
|
* @returns A promise that resolves when the audio context is resumed
|