@galacean/engine-core 0.0.0-experimental-2.0-game.12 → 0.0.0-experimental-2.0-game.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 +11 -6
- package/dist/main.js.map +1 -1
- package/dist/module.js +11 -6
- package/dist/module.js.map +1 -1
- package/package.json +3 -3
- package/types/asset/AssetType.d.ts +1 -1
package/dist/main.js
CHANGED
|
@@ -7801,7 +7801,13 @@ ShaderFactory._std140TypeInfoMap = {
|
|
|
7801
7801
|
};
|
|
7802
7802
|
ShaderFactory._has300OutInFragReg = /\bout\s+(?:\w+\s+)?vec4\s+\w+\s*;/;
|
|
7803
7803
|
ShaderFactory._precisionStr = "\n#ifdef GL_FRAGMENT_PRECISION_HIGH\n precision highp float;\n precision highp int;\n#else\n precision mediump float;\n precision mediump int;\n#endif\n";
|
|
7804
|
-
|
|
7804
|
+
// Derived built-ins re-exposed on top of `renderer_ModelMat`.
|
|
7805
|
+
// `renderer_NormalMat` uses the cofactor (cross-product) form, which algebraically equals
|
|
7806
|
+
// `det(M) · transpose(inverse(M))`. After `normalize()` it's directionally identical to the
|
|
7807
|
+
// classic `transpose(inverse(M))`, but stays NaN-free when `M` is singular (e.g. any scale
|
|
7808
|
+
// axis is 0 — common in animations that pop / hide via scale). `sign(det)` (`s` below)
|
|
7809
|
+
// keeps mirrored matrices facing the right way
|
|
7810
|
+
ShaderFactory._derivedDefines = "mat3 _normalMatFromModel(mat3 m) {\n vec3 c0 = cross(m[1], m[2]);\n vec3 c1 = cross(m[2], m[0]);\n vec3 c2 = cross(m[0], m[1]);\n float s = (dot(m[0], c0) < 0.0) ? -1.0 : 1.0;\n return mat3(c0 * s, c1 * s, c2 * s);\n}\n#define renderer_MVMat (camera_ViewMat * renderer_ModelMat)\n#define renderer_MVPMat (camera_VPMat * renderer_ModelMat)\n#define renderer_NormalMat mat4(_normalMatFromModel(mat3(renderer_ModelMat)))";
|
|
7805
7811
|
// Built-in renderer uniforms. value=true means derived (remove but not added to UBO)
|
|
7806
7812
|
ShaderFactory._builtinRendererUniforms = {
|
|
7807
7813
|
renderer_ModelMat: false,
|
|
@@ -19119,7 +19125,7 @@ RenderContext._flipYViewProjectionMatrix = new engineMath.Matrix();
|
|
|
19119
19125
|
/** Scene. */ AssetType["Scene"] = "Scene";
|
|
19120
19126
|
/** Font. */ AssetType["Font"] = "Font";
|
|
19121
19127
|
/** Source Font, include ttf, otf and woff. */ AssetType["SourceFont"] = "SourceFont";
|
|
19122
|
-
/** AudioClip, include ogg, wav and
|
|
19128
|
+
/** AudioClip, include ogg, wav, mp3, m4a, aac and flac. */ AssetType["Audio"] = "Audio";
|
|
19123
19129
|
/** Project asset. */ AssetType["Project"] = "project";
|
|
19124
19130
|
/** PhysicsMaterial. */ AssetType["PhysicsMaterial"] = "PhysicsMaterial";
|
|
19125
19131
|
/** RenderTarget. */ AssetType["RenderTarget"] = "RenderTarget";
|
|
@@ -22029,8 +22035,7 @@ __decorate([
|
|
|
22029
22035
|
* You need to obtain the actual number of contact points from the function's return value.
|
|
22030
22036
|
*/ _proto.getContacts = function getContacts(outContacts) {
|
|
22031
22037
|
var nativeCollision = this._nativeCollision;
|
|
22032
|
-
var
|
|
22033
|
-
var factor = this.shape.id === smallerShapeId ? 1 : -1;
|
|
22038
|
+
var factor = this.shape.id === nativeCollision.shape1Id ? 1 : -1;
|
|
22034
22039
|
var nativeContactPoints = nativeCollision.getContacts();
|
|
22035
22040
|
var length = nativeContactPoints.size();
|
|
22036
22041
|
for(var i = 0; i < length; i++){
|
|
@@ -33696,8 +33701,8 @@ function _type_of(obj) {
|
|
|
33696
33701
|
if (this._tryCrossFadeInterrupt(layerData, transitionDuration, destState, deltaTime, aniUpdate)) {
|
|
33697
33702
|
return;
|
|
33698
33703
|
}
|
|
33699
|
-
var srcPlaySpeed =
|
|
33700
|
-
var dstPlaySpeed =
|
|
33704
|
+
var srcPlaySpeed = srcPlayData.speed * speed;
|
|
33705
|
+
var dstPlaySpeed = destPlayData.speed * speed;
|
|
33701
33706
|
var dstPlayDeltaTime = dstPlaySpeed * deltaTime;
|
|
33702
33707
|
srcPlayData && srcPlayData.updateOrientation(srcPlaySpeed * deltaTime);
|
|
33703
33708
|
destPlayData && destPlayData.updateOrientation(dstPlayDeltaTime);
|