@galacean/engine-core 2.0.0-alpha.0 → 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 +9 -2
- package/dist/main.js.map +1 -1
- package/dist/module.js +9 -2
- 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
|
@@ -23062,8 +23062,7 @@ var SkinUpdateFlag = /*#__PURE__*/ function(SkinUpdateFlag) {
|
|
|
23062
23062
|
var boneCountChange = boneCount !== boneDataCreateCache.x;
|
|
23063
23063
|
if (boneCountChange || bsUniformOccupiesCount !== boneDataCreateCache.y) {
|
|
23064
23064
|
// directly use max joint count to avoid shader recompile
|
|
23065
|
-
|
|
23066
|
-
var remainUniformJointCount = Math.ceil((this._maxVertexUniformVectors - (44 + bsUniformOccupiesCount)) / 4);
|
|
23065
|
+
var remainUniformJointCount = Math.ceil((this._maxVertexUniformVectors - (SkinnedMeshRenderer._baseVertexUniformVectorCount + bsUniformOccupiesCount)) / 4);
|
|
23067
23066
|
if (boneCount > remainUniformJointCount) {
|
|
23068
23067
|
var engine = this.engine;
|
|
23069
23068
|
if (engine._hardwareRenderer.canIUseMoreJoints) {
|
|
@@ -23241,6 +23240,8 @@ var SkinUpdateFlag = /*#__PURE__*/ function(SkinUpdateFlag) {
|
|
|
23241
23240
|
]);
|
|
23242
23241
|
return SkinnedMeshRenderer;
|
|
23243
23242
|
}(MeshRenderer);
|
|
23243
|
+
// @TODO: different shader type should use different count, not always 48
|
|
23244
|
+
/** @internal */ SkinnedMeshRenderer._baseVertexUniformVectorCount = 48;
|
|
23244
23245
|
SkinnedMeshRenderer._jointCountProperty = ShaderProperty.getByName("renderer_JointCount");
|
|
23245
23246
|
SkinnedMeshRenderer._jointSamplerProperty = ShaderProperty.getByName("renderer_JointSampler");
|
|
23246
23247
|
SkinnedMeshRenderer._jointMatrixProperty = ShaderProperty.getByName("renderer_JointMatrix");
|
|
@@ -37548,6 +37549,12 @@ var cacheDir = new engineMath.Vector3();
|
|
|
37548
37549
|
*/ var AudioManager = /*#__PURE__*/ function() {
|
|
37549
37550
|
function AudioManager() {}
|
|
37550
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
|
+
/**
|
|
37551
37558
|
* Resume the audio context.
|
|
37552
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.
|
|
37553
37560
|
* @returns A promise that resolves when the audio context is resumed
|