@galacean/engine-physics-physx 0.9.0-beta.81 → 0.9.0
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/browser.js +1349 -1337
- package/dist/main.js +54 -42
- package/dist/main.js.map +1 -1
- package/dist/miniprogram.js +1297 -803
- package/dist/module.js +54 -42
- package/dist/module.js.map +1 -1
- package/package.json +4 -4
package/dist/miniprogram.js
CHANGED
|
@@ -5,11 +5,9 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
var engineMiniprogramAdapter$3 = require('@galacean/engine-miniprogram-adapter');
|
|
6
6
|
|
|
7
7
|
function _instanceof(left, right) {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
return left instanceof right;
|
|
12
|
-
}
|
|
8
|
+
if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
|
|
9
|
+
return !!right[Symbol.hasInstance](left);
|
|
10
|
+
} else return left instanceof right;
|
|
13
11
|
}
|
|
14
12
|
|
|
15
13
|
/******************************************************************************
|
|
@@ -43,32 +41,24 @@ function __decorate$2(decorators, target, key, desc) {
|
|
|
43
41
|
PhysXRuntimeMode[PhysXRuntimeMode[/** JavaScript mode. */ "JavaScript"] = 2] = "JavaScript";
|
|
44
42
|
})(exports.PhysXRuntimeMode || (exports.PhysXRuntimeMode = {}));
|
|
45
43
|
|
|
46
|
-
function
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
return o;
|
|
50
|
-
};
|
|
44
|
+
function _set_prototype_of$3(o, p) {
|
|
45
|
+
_set_prototype_of$3 = Object.setPrototypeOf || function setPrototypeOf(o, p) {
|
|
46
|
+
o.__proto__ = p;
|
|
51
47
|
|
|
52
|
-
|
|
53
|
-
}
|
|
48
|
+
return o;
|
|
49
|
+
};
|
|
54
50
|
|
|
55
|
-
|
|
56
|
-
return setPrototypeOf$3(o, p);
|
|
51
|
+
return _set_prototype_of$3(o, p);
|
|
57
52
|
}
|
|
58
53
|
|
|
59
54
|
function _inherits$3(subClass, superClass) {
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
subClass.prototype = Object.create(superClass && superClass.prototype, {
|
|
65
|
-
constructor: {
|
|
66
|
-
value: subClass,
|
|
67
|
-
writable: true,
|
|
68
|
-
configurable: true
|
|
55
|
+
if (typeof superClass !== "function" && superClass !== null) {
|
|
56
|
+
throw new TypeError("Super expression must either be null or a function");
|
|
69
57
|
}
|
|
70
|
-
|
|
71
|
-
|
|
58
|
+
|
|
59
|
+
subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } });
|
|
60
|
+
|
|
61
|
+
if (superClass) _set_prototype_of$3(subClass, superClass);
|
|
72
62
|
}
|
|
73
63
|
|
|
74
64
|
function getAugmentedNamespace(n) {
|
|
@@ -106,10 +96,8 @@ var miniprogram$7 = require("@galacean/engine-math/dist/miniprogram");
|
|
|
106
96
|
Platform[Platform[/** Mac platform. */ "Mac"] = 3] = "Mac";
|
|
107
97
|
Platform[Platform[/** Unknown platform. */ "Unknown"] = 4] = "Unknown";
|
|
108
98
|
})(exports.Platform || (exports.Platform = {}));
|
|
109
|
-
function
|
|
110
|
-
if (self === void 0)
|
|
111
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
112
|
-
}
|
|
99
|
+
function _assert_this_initialized(self) {
|
|
100
|
+
if (self === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
113
101
|
return self;
|
|
114
102
|
}
|
|
115
103
|
function _defineProperties$2(target, props) {
|
|
@@ -121,20 +109,17 @@ function _defineProperties$2(target, props) {
|
|
|
121
109
|
Object.defineProperty(target, descriptor.key, descriptor);
|
|
122
110
|
}
|
|
123
111
|
}
|
|
124
|
-
function
|
|
112
|
+
function _create_class$2(Constructor, protoProps, staticProps) {
|
|
125
113
|
if (protoProps) _defineProperties$2(Constructor.prototype, protoProps);
|
|
126
114
|
if (staticProps) _defineProperties$2(Constructor, staticProps);
|
|
127
115
|
return Constructor;
|
|
128
116
|
}
|
|
129
|
-
function
|
|
130
|
-
|
|
117
|
+
function _set_prototype_of$2(o, p) {
|
|
118
|
+
_set_prototype_of$2 = Object.setPrototypeOf || function setPrototypeOf(o, p) {
|
|
131
119
|
o.__proto__ = p;
|
|
132
120
|
return o;
|
|
133
121
|
};
|
|
134
|
-
return
|
|
135
|
-
}
|
|
136
|
-
function _setPrototypeOf$2(o, p) {
|
|
137
|
-
return setPrototypeOf$2(o, p);
|
|
122
|
+
return _set_prototype_of$2(o, p);
|
|
138
123
|
}
|
|
139
124
|
function _inherits$2(subClass, superClass) {
|
|
140
125
|
if (typeof superClass !== "function" && superClass !== null) {
|
|
@@ -147,7 +132,7 @@ function _inherits$2(subClass, superClass) {
|
|
|
147
132
|
configurable: true
|
|
148
133
|
}
|
|
149
134
|
});
|
|
150
|
-
if (superClass)
|
|
135
|
+
if (superClass) _set_prototype_of$2(subClass, superClass);
|
|
151
136
|
}
|
|
152
137
|
/**
|
|
153
138
|
* Common utility methods for math operations.
|
|
@@ -194,9 +179,15 @@ function _inherits$2(subClass, superClass) {
|
|
|
194
179
|
};
|
|
195
180
|
return MathUtil;
|
|
196
181
|
}();
|
|
197
|
-
|
|
198
|
-
/** The
|
|
199
|
-
|
|
182
|
+
(function() {
|
|
183
|
+
/** The value for which all absolute numbers smaller than are considered equal to zero. */ MathUtil.zeroTolerance = 1e-6;
|
|
184
|
+
})();
|
|
185
|
+
(function() {
|
|
186
|
+
/** The conversion factor that radian to degree. */ MathUtil.radToDegreeFactor = 180 / Math.PI;
|
|
187
|
+
})();
|
|
188
|
+
(function() {
|
|
189
|
+
/** The conversion factor that degree to radian. */ MathUtil.degreeToRadFactor = Math.PI / 180;
|
|
190
|
+
})();
|
|
200
191
|
/**
|
|
201
192
|
* Describes a color in the from of RGBA (in order: R, G, B, A).
|
|
202
193
|
*/ var Color = /*#__PURE__*/ function() {
|
|
@@ -405,7 +396,7 @@ function _inherits$2(subClass, superClass) {
|
|
|
405
396
|
out._onValueChanged && out._onValueChanged();
|
|
406
397
|
return out;
|
|
407
398
|
};
|
|
408
|
-
|
|
399
|
+
_create_class$2(Color, [
|
|
409
400
|
{
|
|
410
401
|
key: "r",
|
|
411
402
|
get: /**
|
|
@@ -479,9 +470,7 @@ PERFORMANCE OF THIS SOFTWARE.
|
|
|
479
470
|
function _instanceof1$2(left, right) {
|
|
480
471
|
if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
|
|
481
472
|
return !!right[Symbol.hasInstance](left);
|
|
482
|
-
} else
|
|
483
|
-
return _instanceof(left, right);
|
|
484
|
-
}
|
|
473
|
+
} else return _instanceof(left, right);
|
|
485
474
|
}
|
|
486
475
|
/**
|
|
487
476
|
* Clone mode.
|
|
@@ -660,15 +649,21 @@ function _instanceof1$2(left, right) {
|
|
|
660
649
|
};
|
|
661
650
|
return CloneManager;
|
|
662
651
|
}();
|
|
663
|
-
|
|
664
|
-
/** @internal */ CloneManager.
|
|
665
|
-
|
|
652
|
+
(function() {
|
|
653
|
+
/** @internal */ CloneManager._subCloneModeMap = new Map();
|
|
654
|
+
})();
|
|
655
|
+
(function() {
|
|
656
|
+
/** @internal */ CloneManager._cloneModeMap = new Map();
|
|
657
|
+
})();
|
|
658
|
+
(function() {
|
|
659
|
+
CloneManager._objectType = Object.getPrototypeOf(Object);
|
|
660
|
+
})();
|
|
666
661
|
/**
|
|
667
662
|
* EngineObject.
|
|
668
663
|
*/ var EngineObject = /*#__PURE__*/ function() {
|
|
669
664
|
function EngineObject(engine) {
|
|
670
|
-
this._destroyed = false;
|
|
671
665
|
/** Engine unique id. */ this.instanceId = ++EngineObject._instanceIdCounter;
|
|
666
|
+
this._destroyed = false;
|
|
672
667
|
this._engine = engine;
|
|
673
668
|
}
|
|
674
669
|
var _proto = EngineObject.prototype;
|
|
@@ -680,7 +675,7 @@ CloneManager._objectType = Object.getPrototypeOf(Object);
|
|
|
680
675
|
(_this__engine_resourceManager = this._engine.resourceManager) == null ? void 0 : _this__engine_resourceManager._deleteAsset(this);
|
|
681
676
|
this._destroyed = true;
|
|
682
677
|
};
|
|
683
|
-
|
|
678
|
+
_create_class$2(EngineObject, [
|
|
684
679
|
{
|
|
685
680
|
key: "engine",
|
|
686
681
|
get: /**
|
|
@@ -700,7 +695,9 @@ CloneManager._objectType = Object.getPrototypeOf(Object);
|
|
|
700
695
|
]);
|
|
701
696
|
return EngineObject;
|
|
702
697
|
}();
|
|
703
|
-
|
|
698
|
+
(function() {
|
|
699
|
+
EngineObject._instanceIdCounter = 0;
|
|
700
|
+
})();
|
|
704
701
|
__decorate$1([
|
|
705
702
|
ignoreClone
|
|
706
703
|
], EngineObject.prototype, "instanceId", void 0);
|
|
@@ -715,7 +712,7 @@ __decorate$1([
|
|
|
715
712
|
_this = EngineObject.call(this, engine) || this;
|
|
716
713
|
/** Whether to ignore the garbage collection check, if it is true, it will not be affected by ResourceManager.gc(). */ _this.isGCIgnored = false;
|
|
717
714
|
_this._refCount = 0;
|
|
718
|
-
engine.resourceManager._addRefObject(_this.instanceId,
|
|
715
|
+
engine.resourceManager._addRefObject(_this.instanceId, _assert_this_initialized(_this));
|
|
719
716
|
return _this;
|
|
720
717
|
};
|
|
721
718
|
_inherits$2(RefObject, EngineObject);
|
|
@@ -758,7 +755,7 @@ __decorate$1([
|
|
|
758
755
|
*/ _proto._addToResourceManager = function _addToResourceManager(path) {
|
|
759
756
|
this._engine.resourceManager._addAsset(path, this);
|
|
760
757
|
};
|
|
761
|
-
|
|
758
|
+
_create_class$2(RefObject, [
|
|
762
759
|
{
|
|
763
760
|
key: "refCount",
|
|
764
761
|
get: /**
|
|
@@ -877,7 +874,7 @@ __decorate$1([
|
|
|
877
874
|
_proto.stopPropagation = function stopPropagation() {
|
|
878
875
|
this._propagationStopped = true;
|
|
879
876
|
};
|
|
880
|
-
|
|
877
|
+
_create_class$2(Event, [
|
|
881
878
|
{
|
|
882
879
|
key: "propagationStopped",
|
|
883
880
|
get: function get() {
|
|
@@ -1150,7 +1147,7 @@ var Time = /*#__PURE__*/ function() {
|
|
|
1150
1147
|
this._lastTickTime = now;
|
|
1151
1148
|
this._frameCount++;
|
|
1152
1149
|
};
|
|
1153
|
-
|
|
1150
|
+
_create_class$2(Time, [
|
|
1154
1151
|
{
|
|
1155
1152
|
key: "frameCount",
|
|
1156
1153
|
get: /*
|
|
@@ -1385,7 +1382,7 @@ exports.GLCapabilityType = void 0;
|
|
|
1385
1382
|
_proto._getMipmapCount = function _getMipmapCount() {
|
|
1386
1383
|
return this._mipmap ? Math.floor(Math.log2(Math.max(this._width, this._height))) + 1 : 1;
|
|
1387
1384
|
};
|
|
1388
|
-
|
|
1385
|
+
_create_class$2(Texture, [
|
|
1389
1386
|
{
|
|
1390
1387
|
key: "format",
|
|
1391
1388
|
get: /**
|
|
@@ -1533,7 +1530,7 @@ exports.GLCapabilityType = void 0;
|
|
|
1533
1530
|
}
|
|
1534
1531
|
_this._depthTexture = depth;
|
|
1535
1532
|
}
|
|
1536
|
-
_this._platformRenderTarget = engine._hardwareRenderer.createPlatformRenderTarget(
|
|
1533
|
+
_this._platformRenderTarget = engine._hardwareRenderer.createPlatformRenderTarget(_assert_this_initialized(_this));
|
|
1537
1534
|
return _this;
|
|
1538
1535
|
};
|
|
1539
1536
|
_inherits$2(RenderTarget, EngineObject);
|
|
@@ -1576,7 +1573,7 @@ exports.GLCapabilityType = void 0;
|
|
|
1576
1573
|
*/ _proto._blitRenderTarget = function _blitRenderTarget() {
|
|
1577
1574
|
this._platformRenderTarget.blitRenderTarget();
|
|
1578
1575
|
};
|
|
1579
|
-
|
|
1576
|
+
_create_class$2(RenderTarget, [
|
|
1580
1577
|
{
|
|
1581
1578
|
key: "autoGenerateMipmaps",
|
|
1582
1579
|
get: /**
|
|
@@ -1646,7 +1643,7 @@ exports.GLCapabilityType = void 0;
|
|
|
1646
1643
|
_this._format = format;
|
|
1647
1644
|
_this._mipmapCount = _this._getMipmapCount();
|
|
1648
1645
|
_this._isDepthTexture = format == exports.TextureFormat.Depth || format == exports.TextureFormat.DepthStencil || format == exports.TextureFormat.Depth16 || format == exports.TextureFormat.Depth24 || format == exports.TextureFormat.Depth32 || format == exports.TextureFormat.Depth24Stencil8 || format == exports.TextureFormat.Depth32Stencil8;
|
|
1649
|
-
_this._platformTexture = engine._hardwareRenderer.createPlatformTexture2D(
|
|
1646
|
+
_this._platformTexture = engine._hardwareRenderer.createPlatformTexture2D(_assert_this_initialized(_this));
|
|
1650
1647
|
_this.filterMode = exports.TextureFilterMode.Bilinear;
|
|
1651
1648
|
_this.wrapModeU = _this.wrapModeV = exports.TextureWrapMode.Repeat;
|
|
1652
1649
|
return _this;
|
|
@@ -1712,7 +1709,7 @@ exports.GLCapabilityType = void 0;
|
|
|
1712
1709
|
_this._length = length1;
|
|
1713
1710
|
_this._format = format;
|
|
1714
1711
|
_this._mipmapCount = _this._getMipmapCount();
|
|
1715
|
-
_this._platformTexture = engine._hardwareRenderer.createPlatformTexture2DArray(
|
|
1712
|
+
_this._platformTexture = engine._hardwareRenderer.createPlatformTexture2DArray(_assert_this_initialized(_this));
|
|
1716
1713
|
_this.filterMode = exports.TextureFilterMode.Bilinear;
|
|
1717
1714
|
_this.wrapModeU = _this.wrapModeV = exports.TextureWrapMode.Repeat;
|
|
1718
1715
|
return _this;
|
|
@@ -1765,7 +1762,7 @@ exports.GLCapabilityType = void 0;
|
|
|
1765
1762
|
this._platformTexture.getPixelBuffer(elementIndex, xOrMipLevelOrOut, yOrMipLevel, width, height, mipLevelOrOut, out);
|
|
1766
1763
|
}
|
|
1767
1764
|
};
|
|
1768
|
-
|
|
1765
|
+
_create_class$2(Texture2DArray, [
|
|
1769
1766
|
{
|
|
1770
1767
|
key: "length",
|
|
1771
1768
|
get: /**
|
|
@@ -1790,7 +1787,7 @@ exports.GLCapabilityType = void 0;
|
|
|
1790
1787
|
_this._height = size;
|
|
1791
1788
|
_this._format = format;
|
|
1792
1789
|
_this._mipmapCount = _this._getMipmapCount();
|
|
1793
|
-
_this._platformTexture = engine._hardwareRenderer.createPlatformTextureCube(
|
|
1790
|
+
_this._platformTexture = engine._hardwareRenderer.createPlatformTextureCube(_assert_this_initialized(_this));
|
|
1794
1791
|
_this.filterMode = exports.TextureFilterMode.Bilinear;
|
|
1795
1792
|
_this.wrapModeU = _this.wrapModeV = exports.TextureWrapMode.Clamp;
|
|
1796
1793
|
return _this;
|
|
@@ -1917,7 +1914,7 @@ exports.GLCapabilityType = void 0;
|
|
|
1917
1914
|
_proto.getCharInfo = function getCharInfo(char) {
|
|
1918
1915
|
return this._charInfoMap[char.charCodeAt(0)];
|
|
1919
1916
|
};
|
|
1920
|
-
|
|
1917
|
+
_create_class$2(FontAtlas, [
|
|
1921
1918
|
{
|
|
1922
1919
|
key: "texture",
|
|
1923
1920
|
get: function get() {
|
|
@@ -2063,7 +2060,7 @@ exports.GLCapabilityType = void 0;
|
|
|
2063
2060
|
}
|
|
2064
2061
|
return null;
|
|
2065
2062
|
};
|
|
2066
|
-
|
|
2063
|
+
_create_class$2(Font, [
|
|
2067
2064
|
{
|
|
2068
2065
|
key: "name",
|
|
2069
2066
|
get: /**
|
|
@@ -2075,8 +2072,9 @@ exports.GLCapabilityType = void 0;
|
|
|
2075
2072
|
]);
|
|
2076
2073
|
return Font;
|
|
2077
2074
|
}(RefObject);
|
|
2078
|
-
|
|
2079
|
-
|
|
2075
|
+
(function() {
|
|
2076
|
+
Font._fontMap = {};
|
|
2077
|
+
})();
|
|
2080
2078
|
var AssetPromise = /*#__PURE__*/ function() {
|
|
2081
2079
|
var AssetPromise = function AssetPromise(executor) {
|
|
2082
2080
|
var _this = this;
|
|
@@ -2195,9 +2193,9 @@ var AssetPromise = /*#__PURE__*/ function() {
|
|
|
2195
2193
|
}
|
|
2196
2194
|
});
|
|
2197
2195
|
};
|
|
2198
|
-
|
|
2196
|
+
_create_class$2(AssetPromise, [
|
|
2199
2197
|
{
|
|
2200
|
-
key:
|
|
2198
|
+
key: Symbol.toStringTag,
|
|
2201
2199
|
get: /** compatible with Promise */ function get() {
|
|
2202
2200
|
return "AssetPromise";
|
|
2203
2201
|
}
|
|
@@ -2508,8 +2506,12 @@ var /** @internal */ PromiseState;
|
|
|
2508
2506
|
};
|
|
2509
2507
|
return ResourceManager;
|
|
2510
2508
|
}();
|
|
2511
|
-
|
|
2512
|
-
ResourceManager.
|
|
2509
|
+
(function() {
|
|
2510
|
+
/** Loader collection. */ ResourceManager._loaders = {};
|
|
2511
|
+
})();
|
|
2512
|
+
(function() {
|
|
2513
|
+
ResourceManager._extTypeMapping = {};
|
|
2514
|
+
})();
|
|
2513
2515
|
/**
|
|
2514
2516
|
* Declare ResourceLoader's decorator.
|
|
2515
2517
|
* @param assetType - Type of asset
|
|
@@ -2862,10 +2864,14 @@ var ComponentCloner = /*#__PURE__*/ function() {
|
|
|
2862
2864
|
};
|
|
2863
2865
|
return ComponentsDependencies;
|
|
2864
2866
|
}();
|
|
2865
|
-
|
|
2867
|
+
(function() {
|
|
2868
|
+
/**
|
|
2866
2869
|
* @internal
|
|
2867
2870
|
*/ ComponentsDependencies._dependenciesMap = new Map();
|
|
2868
|
-
|
|
2871
|
+
})();
|
|
2872
|
+
(function() {
|
|
2873
|
+
ComponentsDependencies._invDependenciesMap = new Map();
|
|
2874
|
+
})();
|
|
2869
2875
|
/**
|
|
2870
2876
|
* Dependent components, automatically added if they do not exist.
|
|
2871
2877
|
* @param components - Dependent components
|
|
@@ -3027,7 +3033,7 @@ ComponentsDependencies._invDependenciesMap = new Map();
|
|
|
3027
3033
|
}
|
|
3028
3034
|
}
|
|
3029
3035
|
};
|
|
3030
|
-
|
|
3036
|
+
_create_class$2(Component, [
|
|
3031
3037
|
{
|
|
3032
3038
|
key: "enabled",
|
|
3033
3039
|
get: /**
|
|
@@ -3158,7 +3164,6 @@ __decorate$1([
|
|
|
3158
3164
|
var Transform = function Transform(entity) {
|
|
3159
3165
|
var _this;
|
|
3160
3166
|
_this = Component.call(this, entity) || this;
|
|
3161
|
-
_this._dirtyFlag = 0xbc;
|
|
3162
3167
|
_this._position = new miniprogram$7.Vector3();
|
|
3163
3168
|
_this._rotation = new miniprogram$7.Vector3();
|
|
3164
3169
|
_this._rotationQuaternion = new miniprogram$7.Quaternion();
|
|
@@ -3171,14 +3176,15 @@ __decorate$1([
|
|
|
3171
3176
|
_this._worldMatrix = new miniprogram$7.Matrix();
|
|
3172
3177
|
_this._isParentDirty = true;
|
|
3173
3178
|
_this._parentTransformCache = null;
|
|
3179
|
+
_this._dirtyFlag = 0xbc;
|
|
3174
3180
|
/** @internal */ _this._updateFlagManager = new UpdateFlagManager();
|
|
3175
|
-
_this._onPositionChanged = _this._onPositionChanged.bind(
|
|
3176
|
-
_this._onWorldPositionChanged = _this._onWorldPositionChanged.bind(
|
|
3177
|
-
_this._onRotationChanged = _this._onRotationChanged.bind(
|
|
3178
|
-
_this._onWorldRotationChanged = _this._onWorldRotationChanged.bind(
|
|
3179
|
-
_this._onRotationQuaternionChanged = _this._onRotationQuaternionChanged.bind(
|
|
3180
|
-
_this._onWorldRotationQuaternionChanged = _this._onWorldRotationQuaternionChanged.bind(
|
|
3181
|
-
_this._onScaleChanged = _this._onScaleChanged.bind(
|
|
3181
|
+
_this._onPositionChanged = _this._onPositionChanged.bind(_assert_this_initialized(_this));
|
|
3182
|
+
_this._onWorldPositionChanged = _this._onWorldPositionChanged.bind(_assert_this_initialized(_this));
|
|
3183
|
+
_this._onRotationChanged = _this._onRotationChanged.bind(_assert_this_initialized(_this));
|
|
3184
|
+
_this._onWorldRotationChanged = _this._onWorldRotationChanged.bind(_assert_this_initialized(_this));
|
|
3185
|
+
_this._onRotationQuaternionChanged = _this._onRotationQuaternionChanged.bind(_assert_this_initialized(_this));
|
|
3186
|
+
_this._onWorldRotationQuaternionChanged = _this._onWorldRotationQuaternionChanged.bind(_assert_this_initialized(_this));
|
|
3187
|
+
_this._onScaleChanged = _this._onScaleChanged.bind(_assert_this_initialized(_this));
|
|
3182
3188
|
//@ts-ignore
|
|
3183
3189
|
_this._position._onValueChanged = _this._onPositionChanged;
|
|
3184
3190
|
//@ts-ignore
|
|
@@ -3571,7 +3577,7 @@ __decorate$1([
|
|
|
3571
3577
|
this._setDirtyFlagTrue(0x40);
|
|
3572
3578
|
this._updateWorldScaleFlag();
|
|
3573
3579
|
};
|
|
3574
|
-
|
|
3580
|
+
_create_class$2(Transform, [
|
|
3575
3581
|
{
|
|
3576
3582
|
key: "position",
|
|
3577
3583
|
get: /**
|
|
@@ -3817,15 +3823,33 @@ __decorate$1([
|
|
|
3817
3823
|
]);
|
|
3818
3824
|
return Transform;
|
|
3819
3825
|
}(Component);
|
|
3820
|
-
|
|
3821
|
-
Transform.
|
|
3822
|
-
|
|
3823
|
-
|
|
3824
|
-
Transform.
|
|
3825
|
-
|
|
3826
|
-
|
|
3827
|
-
Transform.
|
|
3828
|
-
|
|
3826
|
+
(function() {
|
|
3827
|
+
Transform._tempQuat0 = new miniprogram$7.Quaternion();
|
|
3828
|
+
})();
|
|
3829
|
+
(function() {
|
|
3830
|
+
Transform._tempVec30 = new miniprogram$7.Vector3();
|
|
3831
|
+
})();
|
|
3832
|
+
(function() {
|
|
3833
|
+
Transform._tempVec31 = new miniprogram$7.Vector3();
|
|
3834
|
+
})();
|
|
3835
|
+
(function() {
|
|
3836
|
+
Transform._tempVec32 = new miniprogram$7.Vector3();
|
|
3837
|
+
})();
|
|
3838
|
+
(function() {
|
|
3839
|
+
Transform._tempMat30 = new miniprogram$7.Matrix3x3();
|
|
3840
|
+
})();
|
|
3841
|
+
(function() {
|
|
3842
|
+
Transform._tempMat31 = new miniprogram$7.Matrix3x3();
|
|
3843
|
+
})();
|
|
3844
|
+
(function() {
|
|
3845
|
+
Transform._tempMat32 = new miniprogram$7.Matrix3x3();
|
|
3846
|
+
})();
|
|
3847
|
+
(function() {
|
|
3848
|
+
Transform._tempMat41 = new miniprogram$7.Matrix();
|
|
3849
|
+
})();
|
|
3850
|
+
(function() {
|
|
3851
|
+
Transform._tempMat42 = new miniprogram$7.Matrix();
|
|
3852
|
+
})();
|
|
3829
3853
|
__decorate$1([
|
|
3830
3854
|
deepClone
|
|
3831
3855
|
], Transform.prototype, "_position", void 0);
|
|
@@ -4324,7 +4348,7 @@ var TransformModifyFlags;
|
|
|
4324
4348
|
this._traverseSetOwnerScene(children[i], scene);
|
|
4325
4349
|
}
|
|
4326
4350
|
};
|
|
4327
|
-
|
|
4351
|
+
_create_class$2(Entity, [
|
|
4328
4352
|
{
|
|
4329
4353
|
key: "isActive",
|
|
4330
4354
|
get: /**
|
|
@@ -4538,7 +4562,7 @@ var TransformModifyFlags;
|
|
|
4538
4562
|
}
|
|
4539
4563
|
}
|
|
4540
4564
|
};
|
|
4541
|
-
|
|
4565
|
+
_create_class$2(SystemInfo, null, [
|
|
4542
4566
|
{
|
|
4543
4567
|
key: "devicePixelRatio",
|
|
4544
4568
|
get: /**
|
|
@@ -4550,8 +4574,12 @@ var TransformModifyFlags;
|
|
|
4550
4574
|
]);
|
|
4551
4575
|
return SystemInfo;
|
|
4552
4576
|
}();
|
|
4553
|
-
|
|
4554
|
-
/** The
|
|
4577
|
+
(function() {
|
|
4578
|
+
/** The platform is running on. */ SystemInfo.platform = exports.Platform.Unknown;
|
|
4579
|
+
})();
|
|
4580
|
+
(function() {
|
|
4581
|
+
/** The operating system is running on. */ SystemInfo.operatingSystem = "";
|
|
4582
|
+
})();
|
|
4555
4583
|
SystemInfo._initialize();
|
|
4556
4584
|
/**
|
|
4557
4585
|
* The keys of the keyboard.
|
|
@@ -5163,7 +5191,7 @@ SystemInfo._initialize();
|
|
|
5163
5191
|
_proto._setGravity = function _setGravity() {
|
|
5164
5192
|
this._nativePhysicsManager.setGravity(this._gravity);
|
|
5165
5193
|
};
|
|
5166
|
-
|
|
5194
|
+
_create_class$2(PhysicsManager, [
|
|
5167
5195
|
{
|
|
5168
5196
|
key: "gravity",
|
|
5169
5197
|
get: /**
|
|
@@ -5219,7 +5247,7 @@ SystemInfo._initialize();
|
|
|
5219
5247
|
*/ _proto._destroy = function _destroy() {
|
|
5220
5248
|
this._nativeMaterial.destroy();
|
|
5221
5249
|
};
|
|
5222
|
-
|
|
5250
|
+
_create_class$2(PhysicsMaterial, [
|
|
5223
5251
|
{
|
|
5224
5252
|
key: "bounciness",
|
|
5225
5253
|
get: /**
|
|
@@ -5297,8 +5325,8 @@ exports.Collider = /*#__PURE__*/ function(Component) {
|
|
|
5297
5325
|
var Collider = function Collider(entity) {
|
|
5298
5326
|
var _this;
|
|
5299
5327
|
_this = Component.call(this, entity) || this;
|
|
5300
|
-
_this._shapes = [];
|
|
5301
5328
|
/** @internal */ _this._index = -1;
|
|
5329
|
+
_this._shapes = [];
|
|
5302
5330
|
_this._updateFlag = _this.entity.transform.registerWorldChangeFlag();
|
|
5303
5331
|
return _this;
|
|
5304
5332
|
};
|
|
@@ -5378,7 +5406,7 @@ exports.Collider = /*#__PURE__*/ function(Component) {
|
|
|
5378
5406
|
this.clearShapes();
|
|
5379
5407
|
this._nativeCollider.destroy();
|
|
5380
5408
|
};
|
|
5381
|
-
|
|
5409
|
+
_create_class$2(Collider, [
|
|
5382
5410
|
{
|
|
5383
5411
|
key: "shapes",
|
|
5384
5412
|
get: /**
|
|
@@ -5415,7 +5443,7 @@ exports.Collider = __decorate$1([
|
|
|
5415
5443
|
_this._upDirection = new miniprogram$7.Vector3(0, 1, 0);
|
|
5416
5444
|
_this._slopeLimit = 0.707;
|
|
5417
5445
|
_this._nativeCollider = PhysicsManager._nativePhysics.createCharacterController();
|
|
5418
|
-
_this._setUpDirection = _this._setUpDirection.bind(
|
|
5446
|
+
_this._setUpDirection = _this._setUpDirection.bind(_assert_this_initialized(_this));
|
|
5419
5447
|
//@ts-ignore
|
|
5420
5448
|
_this._upDirection._onValueChanged = _this._setUpDirection;
|
|
5421
5449
|
return _this;
|
|
@@ -5489,7 +5517,7 @@ exports.Collider = __decorate$1([
|
|
|
5489
5517
|
_proto._setUpDirection = function _setUpDirection() {
|
|
5490
5518
|
this._nativeCollider.setUpDirection(this._upDirection);
|
|
5491
5519
|
};
|
|
5492
|
-
|
|
5520
|
+
_create_class$2(CharacterController, [
|
|
5493
5521
|
{
|
|
5494
5522
|
key: "stepOffset",
|
|
5495
5523
|
get: /**
|
|
@@ -5583,7 +5611,7 @@ exports.Collider = __decorate$1([
|
|
|
5583
5611
|
_proto._setRotation = function _setRotation() {
|
|
5584
5612
|
this._nativeShape.setRotation(this._rotation);
|
|
5585
5613
|
};
|
|
5586
|
-
|
|
5614
|
+
_create_class$2(ColliderShape, [
|
|
5587
5615
|
{
|
|
5588
5616
|
key: "collider",
|
|
5589
5617
|
get: /**
|
|
@@ -5671,7 +5699,9 @@ exports.Collider = __decorate$1([
|
|
|
5671
5699
|
]);
|
|
5672
5700
|
return ColliderShape;
|
|
5673
5701
|
}();
|
|
5674
|
-
|
|
5702
|
+
(function() {
|
|
5703
|
+
ColliderShape._idGenerator = 0;
|
|
5704
|
+
})();
|
|
5675
5705
|
/**
|
|
5676
5706
|
* Physical collider shape for box.
|
|
5677
5707
|
*/ var BoxColliderShape = /*#__PURE__*/ function(ColliderShape) {
|
|
@@ -5680,7 +5710,7 @@ ColliderShape._idGenerator = 0;
|
|
|
5680
5710
|
_this = ColliderShape.call(this) || this;
|
|
5681
5711
|
_this._size = new miniprogram$7.Vector3(1, 1, 1);
|
|
5682
5712
|
_this._nativeShape = PhysicsManager._nativePhysics.createBoxColliderShape(_this._id, _this._size, _this._material._nativeMaterial);
|
|
5683
|
-
_this._setSize = _this._setSize.bind(
|
|
5713
|
+
_this._setSize = _this._setSize.bind(_assert_this_initialized(_this));
|
|
5684
5714
|
//@ts-ignore
|
|
5685
5715
|
_this._size._onValueChanged = _this._setSize;
|
|
5686
5716
|
return _this;
|
|
@@ -5690,7 +5720,7 @@ ColliderShape._idGenerator = 0;
|
|
|
5690
5720
|
_proto._setSize = function _setSize() {
|
|
5691
5721
|
this._nativeShape.setSize(this._size);
|
|
5692
5722
|
};
|
|
5693
|
-
|
|
5723
|
+
_create_class$2(BoxColliderShape, [
|
|
5694
5724
|
{
|
|
5695
5725
|
key: "size",
|
|
5696
5726
|
get: /**
|
|
@@ -5718,7 +5748,7 @@ ColliderShape._idGenerator = 0;
|
|
|
5718
5748
|
return _this;
|
|
5719
5749
|
};
|
|
5720
5750
|
_inherits$2(SphereColliderShape, ColliderShape);
|
|
5721
|
-
|
|
5751
|
+
_create_class$2(SphereColliderShape, [
|
|
5722
5752
|
{
|
|
5723
5753
|
key: "radius",
|
|
5724
5754
|
get: /**
|
|
@@ -5769,7 +5799,7 @@ ColliderShape._idGenerator = 0;
|
|
|
5769
5799
|
return _this;
|
|
5770
5800
|
};
|
|
5771
5801
|
_inherits$2(CapsuleColliderShape, ColliderShape);
|
|
5772
|
-
|
|
5802
|
+
_create_class$2(CapsuleColliderShape, [
|
|
5773
5803
|
{
|
|
5774
5804
|
key: "radius",
|
|
5775
5805
|
get: /**
|
|
@@ -5827,7 +5857,7 @@ exports.Joint = /*#__PURE__*/ function(Component) {
|
|
|
5827
5857
|
return _this;
|
|
5828
5858
|
};
|
|
5829
5859
|
_inherits$2(Joint, Component);
|
|
5830
|
-
|
|
5860
|
+
_create_class$2(Joint, [
|
|
5831
5861
|
{
|
|
5832
5862
|
key: "connectedCollider",
|
|
5833
5863
|
get: /**
|
|
@@ -6004,7 +6034,7 @@ exports.Joint = __decorate$1([
|
|
|
6004
6034
|
collider.collider = this.entity.getComponent(exports.Collider);
|
|
6005
6035
|
this._nativeJoint = PhysicsManager._nativePhysics.createHingeJoint(collider.collider._nativeCollider);
|
|
6006
6036
|
};
|
|
6007
|
-
|
|
6037
|
+
_create_class$2(HingeJoint, [
|
|
6008
6038
|
{
|
|
6009
6039
|
key: "axis",
|
|
6010
6040
|
get: /**
|
|
@@ -6155,7 +6185,7 @@ exports.Joint = __decorate$1([
|
|
|
6155
6185
|
collider.collider = this.entity.getComponent(exports.Collider);
|
|
6156
6186
|
this._nativeJoint = PhysicsManager._nativePhysics.createSpringJoint(collider.collider._nativeCollider);
|
|
6157
6187
|
};
|
|
6158
|
-
|
|
6188
|
+
_create_class$2(SpringJoint, [
|
|
6159
6189
|
{
|
|
6160
6190
|
key: "swingOffset",
|
|
6161
6191
|
get: /**
|
|
@@ -6305,10 +6335,10 @@ exports.Joint = __decorate$1([
|
|
|
6305
6335
|
_this._sleepThreshold = 5e-3;
|
|
6306
6336
|
var transform = _this.entity.transform;
|
|
6307
6337
|
_this._nativeCollider = PhysicsManager._nativePhysics.createDynamicCollider(transform.worldPosition, transform.worldRotationQuaternion);
|
|
6308
|
-
_this._setLinearVelocity = _this._setLinearVelocity.bind(
|
|
6309
|
-
_this._setAngularVelocity = _this._setAngularVelocity.bind(
|
|
6310
|
-
_this._setCenterOfMass = _this._setCenterOfMass.bind(
|
|
6311
|
-
_this._setInertiaTensor = _this._setInertiaTensor.bind(
|
|
6338
|
+
_this._setLinearVelocity = _this._setLinearVelocity.bind(_assert_this_initialized(_this));
|
|
6339
|
+
_this._setAngularVelocity = _this._setAngularVelocity.bind(_assert_this_initialized(_this));
|
|
6340
|
+
_this._setCenterOfMass = _this._setCenterOfMass.bind(_assert_this_initialized(_this));
|
|
6341
|
+
_this._setInertiaTensor = _this._setInertiaTensor.bind(_assert_this_initialized(_this));
|
|
6312
6342
|
//@ts-ignore
|
|
6313
6343
|
_this._linearVelocity._onValueChanged = _this._setLinearVelocity;
|
|
6314
6344
|
//@ts-ignore
|
|
@@ -6367,7 +6397,7 @@ exports.Joint = __decorate$1([
|
|
|
6367
6397
|
_proto._setInertiaTensor = function _setInertiaTensor() {
|
|
6368
6398
|
this._nativeCollider.setInertiaTensor(this._inertiaTensor);
|
|
6369
6399
|
};
|
|
6370
|
-
|
|
6400
|
+
_create_class$2(DynamicCollider, [
|
|
6371
6401
|
{
|
|
6372
6402
|
key: "linearDamping",
|
|
6373
6403
|
get: /**
|
|
@@ -6909,9 +6939,15 @@ exports.DynamicColliderConstraints = void 0;
|
|
|
6909
6939
|
};
|
|
6910
6940
|
return PointerManager;
|
|
6911
6941
|
}();
|
|
6912
|
-
|
|
6913
|
-
PointerManager.
|
|
6914
|
-
|
|
6942
|
+
(function() {
|
|
6943
|
+
PointerManager._tempRay = new miniprogram$7.Ray();
|
|
6944
|
+
})();
|
|
6945
|
+
(function() {
|
|
6946
|
+
PointerManager._tempPoint = new miniprogram$7.Vector2();
|
|
6947
|
+
})();
|
|
6948
|
+
(function() {
|
|
6949
|
+
PointerManager._tempHitResult = new HitResult();
|
|
6950
|
+
})();
|
|
6915
6951
|
/**
|
|
6916
6952
|
* Wheel Manager.
|
|
6917
6953
|
* @internal
|
|
@@ -7115,7 +7151,7 @@ PointerManager._tempHitResult = new HitResult();
|
|
|
7115
7151
|
this._pointerManager._onFocus();
|
|
7116
7152
|
this._keyboardManager._onFocus();
|
|
7117
7153
|
};
|
|
7118
|
-
|
|
7154
|
+
_create_class$2(InputManager, [
|
|
7119
7155
|
{
|
|
7120
7156
|
key: "pointers",
|
|
7121
7157
|
get: /**
|
|
@@ -7290,8 +7326,12 @@ PointerManager._tempHitResult = new HitResult();
|
|
|
7290
7326
|
}
|
|
7291
7327
|
this._nameId = nameID;
|
|
7292
7328
|
};
|
|
7293
|
-
|
|
7294
|
-
ShaderMacro.
|
|
7329
|
+
(function() {
|
|
7330
|
+
/** @internal */ ShaderMacro._macroNameIdMap = Object.create(null);
|
|
7331
|
+
})();
|
|
7332
|
+
(function() {
|
|
7333
|
+
ShaderMacro._macroNameCounter = 0;
|
|
7334
|
+
})();
|
|
7295
7335
|
/**
|
|
7296
7336
|
* Shader macro collection.
|
|
7297
7337
|
* @internal
|
|
@@ -7441,29 +7481,21 @@ ShaderMacro._macroNameCounter = 0;
|
|
|
7441
7481
|
};
|
|
7442
7482
|
return ShaderMacroCollection;
|
|
7443
7483
|
}();
|
|
7444
|
-
function
|
|
7445
|
-
|
|
7484
|
+
function _extends$2() {
|
|
7485
|
+
_extends$2 = Object.assign || function assign(target) {
|
|
7446
7486
|
for(var i = 1; i < arguments.length; i++){
|
|
7447
7487
|
var source = arguments[i];
|
|
7448
|
-
for(var key in source)
|
|
7449
|
-
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
7450
|
-
target[key] = source[key];
|
|
7451
|
-
}
|
|
7452
|
-
}
|
|
7488
|
+
for(var key in source)if (Object.prototype.hasOwnProperty.call(source, key)) target[key] = source[key];
|
|
7453
7489
|
}
|
|
7454
7490
|
return target;
|
|
7455
7491
|
};
|
|
7456
|
-
return
|
|
7457
|
-
}
|
|
7458
|
-
function _extends$2() {
|
|
7459
|
-
return extends_$2.apply(this, arguments);
|
|
7492
|
+
return _extends$2.apply(this, arguments);
|
|
7460
7493
|
}
|
|
7461
7494
|
var camera_declare = "#define GLSLIFY 1\nuniform vec3 u_cameraPos;"; // eslint-disable-line
|
|
7462
7495
|
var common = "#define GLSLIFY 1\n#define PI 3.14159265359\n#define RECIPROCAL_PI 0.31830988618\n#define EPSILON 1e-6\n#define LOG2 1.442695\n#define saturate( a ) clamp( a, 0.0, 1.0 )\nfloat pow2(float x){return x*x;}vec4 RGBMToLinear(vec4 value,float maxRange){return vec4(value.rgb*value.a*maxRange,1.0);}vec4 gammaToLinear(vec4 srgbIn){return vec4(pow(srgbIn.rgb,vec3(2.2)),srgbIn.a);}vec4 linearToGamma(vec4 linearIn){return vec4(pow(linearIn.rgb,vec3(1.0/2.2)),linearIn.a);}\n#ifdef GRAPHICS_API_WEBGL2\n#define INVERSE_MAT(mat) inverse(mat)\n#else\nmat2 inverseMat(mat2 m){return mat2(m[1][1],-m[0][1],-m[1][0],m[0][0])/(m[0][0]*m[1][1]-m[0][1]*m[1][0]);}mat3 inverseMat(mat3 m){float a00=m[0][0],a01=m[0][1],a02=m[0][2];float a10=m[1][0],a11=m[1][1],a12=m[1][2];float a20=m[2][0],a21=m[2][1],a22=m[2][2];float b01=a22*a11-a12*a21;float b11=-a22*a10+a12*a20;float b21=a21*a10-a11*a20;float det=a00*b01+a01*b11+a02*b21;return mat3(b01,(-a22*a01+a02*a21),(a12*a01-a02*a11),b11,(a22*a00-a02*a20),(-a12*a00+a02*a10),b21,(-a21*a00+a01*a20),(a11*a00-a01*a10))/det;}mat4 inverseMat(mat4 m){float a00=m[0][0],a01=m[0][1],a02=m[0][2],a03=m[0][3],a10=m[1][0],a11=m[1][1],a12=m[1][2],a13=m[1][3],a20=m[2][0],a21=m[2][1],a22=m[2][2],a23=m[2][3],a30=m[3][0],a31=m[3][1],a32=m[3][2],a33=m[3][3],b00=a00*a11-a01*a10,b01=a00*a12-a02*a10,b02=a00*a13-a03*a10,b03=a01*a12-a02*a11,b04=a01*a13-a03*a11,b05=a02*a13-a03*a12,b06=a20*a31-a21*a30,b07=a20*a32-a22*a30,b08=a20*a33-a23*a30,b09=a21*a32-a22*a31,b10=a21*a33-a23*a31,b11=a22*a33-a23*a32,det=b00*b11-b01*b10+b02*b09+b03*b08-b04*b07+b05*b06;return mat4(a11*b11-a12*b10+a13*b09,a02*b10-a01*b11-a03*b09,a31*b05-a32*b04+a33*b03,a22*b04-a21*b05-a23*b03,a12*b08-a10*b11-a13*b07,a00*b11-a02*b08+a03*b07,a32*b02-a30*b05-a33*b01,a20*b05-a22*b02+a23*b01,a10*b10-a11*b08+a13*b06,a01*b08-a00*b10-a03*b06,a30*b04-a31*b02+a33*b00,a21*b02-a20*b04-a23*b00,a11*b07-a10*b09-a12*b06,a00*b09-a01*b07+a02*b06,a31*b01-a30*b03-a32*b00,a20*b03-a21*b01+a22*b00)/det;}\n#define INVERSE_MAT(mat) inverseMat(mat)\n#endif\n"; // eslint-disable-line
|
|
7463
7496
|
var common_vert = "#define GLSLIFY 1\nattribute vec3 POSITION;\n#ifdef O3_HAS_UV\nattribute vec2 TEXCOORD_0;\n#endif\n#ifdef O3_HAS_UV1\nattribute vec2 TEXCOORD_1;\n#endif\n#ifdef O3_HAS_SKIN\nattribute vec4 JOINTS_0;attribute vec4 WEIGHTS_0;\n#ifdef O3_USE_JOINT_TEXTURE\nuniform sampler2D u_jointSampler;uniform float u_jointCount;mat4 getJointMatrix(sampler2D smp,float index){float base=index/u_jointCount;float hf=0.5/u_jointCount;float v=base+hf;vec4 m0=texture2D(smp,vec2(0.125,v));vec4 m1=texture2D(smp,vec2(0.375,v));vec4 m2=texture2D(smp,vec2(0.625,v));vec4 m3=texture2D(smp,vec2(0.875,v));return mat4(m0,m1,m2,m3);}\n#else\nuniform mat4 u_jointMatrix[O3_JOINTS_NUM];\n#endif\n#endif\n#ifdef O3_HAS_VERTEXCOLOR\nattribute vec4 COLOR_0;\n#endif\n#include <transform_declare>\n#include <camera_declare>\nuniform vec4 u_tilingOffset;\n#ifndef OMIT_NORMAL\n#ifdef O3_HAS_NORMAL\nattribute vec3 NORMAL;\n#endif\n#ifdef O3_HAS_TANGENT\nattribute vec4 TANGENT;\n#endif\n#endif\n"; // eslint-disable-line
|
|
7464
7497
|
var transform_declare = "#define GLSLIFY 1\nuniform mat4 u_localMat;uniform mat4 u_modelMat;uniform mat4 u_viewMat;uniform mat4 u_projMat;uniform mat4 u_MVMat;uniform mat4 u_MVPMat;uniform mat4 u_normalMat;"; // eslint-disable-line
|
|
7465
7498
|
var color_share = "#define GLSLIFY 1\n#ifdef O3_HAS_VERTEXCOLOR\nvarying vec4 v_color;\n#endif\n"; // eslint-disable-line
|
|
7466
|
-
var RendererFragmentDeclaration = "#define GLSLIFY 1\nuniform highp ivec4 oasis_RendererLayer;"; // eslint-disable-line
|
|
7467
7499
|
var FogFragmentDeclaration = "#define GLSLIFY 1\n#if OASIS_FOG_MODE != 0\nvarying vec3 v_positionVS;uniform vec4 oasis_FogColor;uniform vec4 oasis_FogParams;float ComputeFogIntensity(float fogDepth){\n#if OASIS_FOG_MODE == 1\nreturn clamp(fogDepth*oasis_FogParams.x+oasis_FogParams.y,0.0,1.0);\n#elif OASIS_FOG_MODE == 2\nreturn clamp(exp2(-fogDepth*oasis_FogParams.z),0.0,1.0);\n#elif OASIS_FOG_MODE == 3\nfloat factor=fogDepth*oasis_FogParams.w;return clamp(exp2(-factor*factor),0.0,1.0);\n#endif\n}\n#endif\n"; // eslint-disable-line
|
|
7468
7500
|
var FogVertexDeclaration = "#define GLSLIFY 1\n#if OASIS_FOG_MODE != 0\nvarying vec3 v_positionVS;\n#endif\n"; // eslint-disable-line
|
|
7469
7501
|
var normal_share = "#define GLSLIFY 1\n#ifndef OMIT_NORMAL\n#ifdef O3_HAS_NORMAL\nvarying vec3 v_normal;\n#if defined(O3_HAS_TANGENT) && ( defined(NORMALTEXTURE) || defined(HAS_CLEARCOATNORMALTEXTURE) )\nvarying mat3 v_TBN;\n#endif\n#endif\n#endif\n"; // eslint-disable-line
|
|
@@ -7481,7 +7513,7 @@ var skinning_vert = "#define GLSLIFY 1\n#ifdef O3_HAS_SKIN\n#ifdef O3_USE_JOINT_
|
|
|
7481
7513
|
var uv_vert = "#define GLSLIFY 1\n#ifdef O3_HAS_UV\nv_uv=TEXCOORD_0;\n#else\nv_uv=vec2(0.,0.);\n#endif\n#ifdef O3_HAS_UV1\nv_uv1=TEXCOORD_1;\n#endif\n#ifdef O3_NEED_TILINGOFFSET\nv_uv=v_uv*u_tilingOffset.xy+u_tilingOffset.zw;\n#endif\n"; // eslint-disable-line
|
|
7482
7514
|
var worldpos_vert = "#define GLSLIFY 1\n#ifdef O3_NEED_WORLDPOS\nvec4 temp_pos=u_modelMat*position;v_pos=temp_pos.xyz/temp_pos.w;\n#endif\n"; // eslint-disable-line
|
|
7483
7515
|
var FogFragment = "#define GLSLIFY 1\n#if OASIS_FOG_MODE != 0\nfloat fogIntensity=ComputeFogIntensity(length(v_positionVS));gl_FragColor.rgb=mix(oasis_FogColor.rgb,gl_FragColor.rgb,fogIntensity);\n#endif\n"; // eslint-disable-line
|
|
7484
|
-
var light_frag_define = "#define GLSLIFY 1\n#ifdef O3_DIRECT_LIGHT_COUNT\nstruct DirectLight{vec3 color;vec3 direction;};uniform ivec2 u_directLightCullingMask[O3_DIRECT_LIGHT_COUNT];uniform vec3 u_directLightColor[O3_DIRECT_LIGHT_COUNT];uniform vec3 u_directLightDirection[O3_DIRECT_LIGHT_COUNT];\n#endif\n#ifdef O3_POINT_LIGHT_COUNT\nstruct PointLight{vec3 color;vec3 position;float distance;};uniform ivec2 u_pointLightCullingMask[O3_POINT_LIGHT_COUNT];uniform vec3 u_pointLightColor[O3_POINT_LIGHT_COUNT];uniform vec3 u_pointLightPosition[O3_POINT_LIGHT_COUNT];uniform float u_pointLightDistance[O3_POINT_LIGHT_COUNT];\n#endif\n#ifdef O3_SPOT_LIGHT_COUNT\nstruct SpotLight{vec3 color;vec3 position;vec3 direction;float distance;float angleCos;float penumbraCos;};uniform ivec2 u_spotLightCullingMask[O3_SPOT_LIGHT_COUNT];uniform vec3 u_spotLightColor[O3_SPOT_LIGHT_COUNT];uniform vec3 u_spotLightPosition[O3_SPOT_LIGHT_COUNT];uniform vec3 u_spotLightDirection[O3_SPOT_LIGHT_COUNT];uniform float u_spotLightDistance[O3_SPOT_LIGHT_COUNT];uniform float u_spotLightAngleCos[O3_SPOT_LIGHT_COUNT];uniform float u_spotLightPenumbraCos[O3_SPOT_LIGHT_COUNT];\n#endif\nstruct EnvMapLight{vec3 diffuse;float mipMapLevel;float diffuseIntensity;float specularIntensity;};uniform EnvMapLight u_envMapLight;\n#ifdef O3_USE_SH\nuniform vec3 u_env_sh[9];\n#endif\n#ifdef O3_USE_SPECULAR_ENV\nuniform samplerCube u_env_specularSampler;\n#endif\n#ifndef GRAPHICS_API_WEBGL2\nbool isBitSet(float value,float mask,float bitIndex){return mod(floor(value/pow(2.0,bitIndex)),2.0)==1.0&&mod(floor(mask/pow(2.0,bitIndex)),2.0)==1.0;}\n#endif\nbool isRendererCulledByLight(ivec2 rendererLayer,ivec2 lightCullingMask){\n#ifdef GRAPHICS_API_WEBGL2\nreturn!((rendererLayer.x&lightCullingMask.x)!=0||(rendererLayer.y&lightCullingMask.y)!=0);\n#else\nfor(int i=0;i<16;i++){if(isBitSet(float(rendererLayer.x),float(lightCullingMask.x),float(i))||isBitSet(float(rendererLayer.y),float(lightCullingMask.y),float(i))){return false;}}return true;\n#endif\n}"; // eslint-disable-line
|
|
7516
|
+
var light_frag_define = "#define GLSLIFY 1\n#ifdef O3_DIRECT_LIGHT_COUNT\nstruct DirectLight{vec3 color;vec3 direction;};uniform ivec2 u_directLightCullingMask[O3_DIRECT_LIGHT_COUNT];uniform vec3 u_directLightColor[O3_DIRECT_LIGHT_COUNT];uniform vec3 u_directLightDirection[O3_DIRECT_LIGHT_COUNT];\n#endif\n#ifdef O3_POINT_LIGHT_COUNT\nstruct PointLight{vec3 color;vec3 position;float distance;};uniform ivec2 u_pointLightCullingMask[O3_POINT_LIGHT_COUNT];uniform vec3 u_pointLightColor[O3_POINT_LIGHT_COUNT];uniform vec3 u_pointLightPosition[O3_POINT_LIGHT_COUNT];uniform float u_pointLightDistance[O3_POINT_LIGHT_COUNT];\n#endif\n#ifdef O3_SPOT_LIGHT_COUNT\nstruct SpotLight{vec3 color;vec3 position;vec3 direction;float distance;float angleCos;float penumbraCos;};uniform ivec2 u_spotLightCullingMask[O3_SPOT_LIGHT_COUNT];uniform vec3 u_spotLightColor[O3_SPOT_LIGHT_COUNT];uniform vec3 u_spotLightPosition[O3_SPOT_LIGHT_COUNT];uniform vec3 u_spotLightDirection[O3_SPOT_LIGHT_COUNT];uniform float u_spotLightDistance[O3_SPOT_LIGHT_COUNT];uniform float u_spotLightAngleCos[O3_SPOT_LIGHT_COUNT];uniform float u_spotLightPenumbraCos[O3_SPOT_LIGHT_COUNT];\n#endif\nstruct EnvMapLight{vec3 diffuse;float mipMapLevel;float diffuseIntensity;float specularIntensity;};uniform EnvMapLight u_envMapLight;uniform ivec4 oasis_RendererLayer;\n#ifdef O3_USE_SH\nuniform vec3 u_env_sh[9];\n#endif\n#ifdef O3_USE_SPECULAR_ENV\nuniform samplerCube u_env_specularSampler;\n#endif\n#ifndef GRAPHICS_API_WEBGL2\nbool isBitSet(float value,float mask,float bitIndex){return mod(floor(value/pow(2.0,bitIndex)),2.0)==1.0&&mod(floor(mask/pow(2.0,bitIndex)),2.0)==1.0;}\n#endif\nbool isRendererCulledByLight(ivec2 rendererLayer,ivec2 lightCullingMask){\n#ifdef GRAPHICS_API_WEBGL2\nreturn!((rendererLayer.x&lightCullingMask.x)!=0||(rendererLayer.y&lightCullingMask.y)!=0);\n#else\nfor(int i=0;i<16;i++){if(isBitSet(float(rendererLayer.x),float(lightCullingMask.x),float(i))||isBitSet(float(rendererLayer.y),float(lightCullingMask.y),float(i))){return false;}}return true;\n#endif\n}"; // eslint-disable-line
|
|
7485
7517
|
var mobile_material_frag = "#define GLSLIFY 1\nuniform vec4 u_emissiveColor;uniform vec4 u_baseColor;uniform vec4 u_specularColor;uniform float u_shininess;uniform float u_normalIntensity;uniform float u_alphaCutoff;\n#ifdef EMISSIVETEXTURE\nuniform sampler2D u_emissiveTexture;\n#endif\n#ifdef BASETEXTURE\nuniform sampler2D u_baseTexture;\n#endif\n#ifdef O3_SPECULAR_TEXTURE\nuniform sampler2D u_specularTexture;\n#endif\n#ifdef NORMALTEXTURE\nuniform sampler2D u_normalTexture;\n#endif\n"; // eslint-disable-line
|
|
7486
7518
|
var begin_mobile_frag = "#define GLSLIFY 1\nvec4 ambient=vec4(0.0);vec4 emission=u_emissiveColor;vec4 diffuse=u_baseColor;vec4 specular=u_specularColor;\n#ifdef EMISSIVETEXTURE\nvec4 emissiveTextureColor=texture2D(u_emissiveTexture,v_uv);\n#ifndef OASIS_COLORSPACE_GAMMA\nemissiveTextureColor=gammaToLinear(emissiveTextureColor);\n#endif\nemission*=emissiveTextureColor;\n#endif\n#ifdef BASETEXTURE\nvec4 diffuseTextureColor=texture2D(u_baseTexture,v_uv);\n#ifndef OASIS_COLORSPACE_GAMMA\ndiffuseTextureColor=gammaToLinear(diffuseTextureColor);\n#endif\ndiffuse*=diffuseTextureColor;\n#endif\n#ifdef O3_HAS_VERTEXCOLOR\ndiffuse*=v_color;\n#endif\n#ifdef O3_SPECULAR_TEXTURE\nvec4 specularTextureColor=texture2D(u_specularTexture,v_uv);\n#ifndef OASIS_COLORSPACE_GAMMA\nspecularTextureColor=gammaToLinear(specularTextureColor);\n#endif\nspecular*=specularTextureColor;\n#endif\nambient=vec4(u_envMapLight.diffuse*u_envMapLight.diffuseIntensity,1.0)*diffuse;"; // eslint-disable-line
|
|
7487
7519
|
var begin_viewdir_frag = "#define GLSLIFY 1\n#ifdef O3_NEED_WORLDPOS\nvec3 V=normalize(u_cameraPos-v_pos);\n#endif\n"; // eslint-disable-line
|
|
@@ -7538,7 +7570,6 @@ var ShaderLib = _extends$2({
|
|
|
7538
7570
|
normal_share: normal_share,
|
|
7539
7571
|
uv_share: uv_share,
|
|
7540
7572
|
worldpos_share: worldpos_share,
|
|
7541
|
-
RendererFragmentDeclaration: RendererFragmentDeclaration,
|
|
7542
7573
|
FogVertexDeclaration: FogVertexDeclaration,
|
|
7543
7574
|
FogFragmentDeclaration: FogFragmentDeclaration,
|
|
7544
7575
|
begin_normal_vert: begin_normal_vert,
|
|
@@ -8237,7 +8268,7 @@ var ShaderFactory = /*#__PURE__*/ function() {
|
|
|
8237
8268
|
return prefix + line;
|
|
8238
8269
|
}).join("\n");
|
|
8239
8270
|
};
|
|
8240
|
-
|
|
8271
|
+
_create_class$2(ShaderProgram, [
|
|
8241
8272
|
{
|
|
8242
8273
|
key: "isValid",
|
|
8243
8274
|
get: /**
|
|
@@ -8249,7 +8280,9 @@ var ShaderFactory = /*#__PURE__*/ function() {
|
|
|
8249
8280
|
]);
|
|
8250
8281
|
return ShaderProgram;
|
|
8251
8282
|
}();
|
|
8252
|
-
|
|
8283
|
+
(function() {
|
|
8284
|
+
ShaderProgram._counter = 0;
|
|
8285
|
+
})();
|
|
8253
8286
|
/**
|
|
8254
8287
|
* Shader pass containing vertex and fragment source.
|
|
8255
8288
|
*/ var ShaderPass = /*#__PURE__*/ function() {
|
|
@@ -8293,7 +8326,9 @@ ShaderProgram._counter = 0;
|
|
|
8293
8326
|
};
|
|
8294
8327
|
return ShaderPass;
|
|
8295
8328
|
}();
|
|
8296
|
-
|
|
8329
|
+
(function() {
|
|
8330
|
+
ShaderPass._shaderPassCounter = 0;
|
|
8331
|
+
})();
|
|
8297
8332
|
/**
|
|
8298
8333
|
* Shader property.
|
|
8299
8334
|
*/ var ShaderProperty = /*#__PURE__*/ function() {
|
|
@@ -8301,7 +8336,7 @@ ShaderPass._shaderPassCounter = 0;
|
|
|
8301
8336
|
this.name = name;
|
|
8302
8337
|
this._uniqueId = ShaderProperty._propertyNameCounter++;
|
|
8303
8338
|
}
|
|
8304
|
-
|
|
8339
|
+
_create_class$2(ShaderProperty, [
|
|
8305
8340
|
{
|
|
8306
8341
|
key: "type",
|
|
8307
8342
|
get: /**
|
|
@@ -8313,7 +8348,9 @@ ShaderPass._shaderPassCounter = 0;
|
|
|
8313
8348
|
]);
|
|
8314
8349
|
return ShaderProperty;
|
|
8315
8350
|
}();
|
|
8316
|
-
|
|
8351
|
+
(function() {
|
|
8352
|
+
ShaderProperty._propertyNameCounter = 0;
|
|
8353
|
+
})();
|
|
8317
8354
|
/**
|
|
8318
8355
|
* Shader for rendering.
|
|
8319
8356
|
*/ var Shader = /*#__PURE__*/ function() {
|
|
@@ -8425,7 +8462,7 @@ ShaderProperty._propertyNameCounter = 0;
|
|
|
8425
8462
|
}
|
|
8426
8463
|
}
|
|
8427
8464
|
};
|
|
8428
|
-
|
|
8465
|
+
_create_class$2(Shader, [
|
|
8429
8466
|
{
|
|
8430
8467
|
key: "passes",
|
|
8431
8468
|
get: /**
|
|
@@ -8437,18 +8474,34 @@ ShaderProperty._propertyNameCounter = 0;
|
|
|
8437
8474
|
]);
|
|
8438
8475
|
return Shader;
|
|
8439
8476
|
}();
|
|
8440
|
-
|
|
8441
|
-
/** @internal */ Shader.
|
|
8442
|
-
|
|
8443
|
-
|
|
8444
|
-
|
|
8445
|
-
|
|
8446
|
-
|
|
8447
|
-
|
|
8448
|
-
|
|
8449
|
-
|
|
8450
|
-
|
|
8451
|
-
Shader.
|
|
8477
|
+
(function() {
|
|
8478
|
+
/** @internal */ Shader._compileMacros = new ShaderMacroCollection();
|
|
8479
|
+
})();
|
|
8480
|
+
(function() {
|
|
8481
|
+
/** @internal */ Shader._shaderExtension = [
|
|
8482
|
+
"GL_EXT_shader_texture_lod",
|
|
8483
|
+
"GL_OES_standard_derivatives",
|
|
8484
|
+
"GL_EXT_draw_buffers"
|
|
8485
|
+
];
|
|
8486
|
+
})();
|
|
8487
|
+
(function() {
|
|
8488
|
+
/** @internal */ Shader._propertyIdMap = Object.create(null);
|
|
8489
|
+
})();
|
|
8490
|
+
(function() {
|
|
8491
|
+
Shader._shaderMap = Object.create(null);
|
|
8492
|
+
})();
|
|
8493
|
+
(function() {
|
|
8494
|
+
Shader._propertyNameMap = Object.create(null);
|
|
8495
|
+
})();
|
|
8496
|
+
(function() {
|
|
8497
|
+
Shader._macroMaskMap = [];
|
|
8498
|
+
})();
|
|
8499
|
+
(function() {
|
|
8500
|
+
Shader._macroCounter = 0;
|
|
8501
|
+
})();
|
|
8502
|
+
(function() {
|
|
8503
|
+
Shader._macroMap = Object.create(null);
|
|
8504
|
+
})();
|
|
8452
8505
|
/**
|
|
8453
8506
|
* Shader data collection,Correspondence includes shader properties data and macros data.
|
|
8454
8507
|
*/ var ShaderData = /*#__PURE__*/ function() {
|
|
@@ -8703,9 +8756,9 @@ Shader._macroMap = Object.create(null);
|
|
|
8703
8756
|
/** Shadow mapping normal-based bias. */ _this.shadowNormalBias = 1;
|
|
8704
8757
|
/** Near plane value to use for shadow frustums. */ _this.shadowNearPlane = 0.1;
|
|
8705
8758
|
/** Shadow intensity, the larger the value, the clearer and darker the shadow. */ _this.shadowStrength = 1.0;
|
|
8759
|
+
/** @internal */ _this._lightIndex = -1;
|
|
8706
8760
|
_this._color = new miniprogram$7.Color(1, 1, 1, 1);
|
|
8707
8761
|
_this._lightColor = new miniprogram$7.Color();
|
|
8708
|
-
/** @internal */ _this._lightIndex = -1;
|
|
8709
8762
|
return _this;
|
|
8710
8763
|
};
|
|
8711
8764
|
_inherits$2(Light, Component);
|
|
@@ -8717,7 +8770,7 @@ Shader._macroMap = Object.create(null);
|
|
|
8717
8770
|
this._lightColor.a = this.color.a * this.intensity;
|
|
8718
8771
|
return this._lightColor;
|
|
8719
8772
|
};
|
|
8720
|
-
|
|
8773
|
+
_create_class$2(Light, [
|
|
8721
8774
|
{
|
|
8722
8775
|
key: "color",
|
|
8723
8776
|
get: /**
|
|
@@ -8754,9 +8807,11 @@ Shader._macroMap = Object.create(null);
|
|
|
8754
8807
|
]);
|
|
8755
8808
|
return Light;
|
|
8756
8809
|
}(Component);
|
|
8757
|
-
|
|
8810
|
+
(function() {
|
|
8811
|
+
/**
|
|
8758
8812
|
* Each type of light source is at most 10, beyond which it will not take effect.
|
|
8759
8813
|
* */ Light._maxLight = 10;
|
|
8814
|
+
})();
|
|
8760
8815
|
__decorate$1([
|
|
8761
8816
|
ignoreClone
|
|
8762
8817
|
], Light.prototype, "_lightIndex", void 0);
|
|
@@ -8813,7 +8868,7 @@ __decorate$1([
|
|
|
8813
8868
|
shaderData.setFloatArray(DirectLight._colorProperty, data.color);
|
|
8814
8869
|
shaderData.setFloatArray(DirectLight._directionProperty, data.direction);
|
|
8815
8870
|
};
|
|
8816
|
-
|
|
8871
|
+
_create_class$2(DirectLight, [
|
|
8817
8872
|
{
|
|
8818
8873
|
key: "direction",
|
|
8819
8874
|
get: /**
|
|
@@ -8844,14 +8899,22 @@ __decorate$1([
|
|
|
8844
8899
|
]);
|
|
8845
8900
|
return DirectLight;
|
|
8846
8901
|
}(Light);
|
|
8847
|
-
|
|
8848
|
-
DirectLight.
|
|
8849
|
-
|
|
8850
|
-
|
|
8851
|
-
|
|
8852
|
-
|
|
8853
|
-
|
|
8854
|
-
|
|
8902
|
+
(function() {
|
|
8903
|
+
DirectLight._cullingMaskProperty = Shader.getPropertyByName("u_directLightCullingMask");
|
|
8904
|
+
})();
|
|
8905
|
+
(function() {
|
|
8906
|
+
DirectLight._colorProperty = Shader.getPropertyByName("u_directLightColor");
|
|
8907
|
+
})();
|
|
8908
|
+
(function() {
|
|
8909
|
+
DirectLight._directionProperty = Shader.getPropertyByName("u_directLightDirection");
|
|
8910
|
+
})();
|
|
8911
|
+
(function() {
|
|
8912
|
+
DirectLight._combinedData = {
|
|
8913
|
+
cullingMask: new Int32Array(Light._maxLight * 2),
|
|
8914
|
+
color: new Float32Array(Light._maxLight * 3),
|
|
8915
|
+
direction: new Float32Array(Light._maxLight * 3)
|
|
8916
|
+
};
|
|
8917
|
+
})();
|
|
8855
8918
|
/**
|
|
8856
8919
|
* Point light.
|
|
8857
8920
|
*/ var PointLight = /*#__PURE__*/ function(Light) {
|
|
@@ -8907,7 +8970,7 @@ DirectLight._combinedData = {
|
|
|
8907
8970
|
shaderData.setFloatArray(PointLight._positionProperty, data.position);
|
|
8908
8971
|
shaderData.setFloatArray(PointLight._distanceProperty, data.distance);
|
|
8909
8972
|
};
|
|
8910
|
-
|
|
8973
|
+
_create_class$2(PointLight, [
|
|
8911
8974
|
{
|
|
8912
8975
|
key: "position",
|
|
8913
8976
|
get: /**
|
|
@@ -8928,16 +8991,26 @@ DirectLight._combinedData = {
|
|
|
8928
8991
|
]);
|
|
8929
8992
|
return PointLight;
|
|
8930
8993
|
}(Light);
|
|
8931
|
-
|
|
8932
|
-
PointLight.
|
|
8933
|
-
|
|
8934
|
-
|
|
8935
|
-
PointLight.
|
|
8936
|
-
|
|
8937
|
-
|
|
8938
|
-
|
|
8939
|
-
|
|
8940
|
-
|
|
8994
|
+
(function() {
|
|
8995
|
+
PointLight._cullingMaskProperty = Shader.getPropertyByName("u_pointLightCullingMask");
|
|
8996
|
+
})();
|
|
8997
|
+
(function() {
|
|
8998
|
+
PointLight._colorProperty = Shader.getPropertyByName("u_pointLightColor");
|
|
8999
|
+
})();
|
|
9000
|
+
(function() {
|
|
9001
|
+
PointLight._positionProperty = Shader.getPropertyByName("u_pointLightPosition");
|
|
9002
|
+
})();
|
|
9003
|
+
(function() {
|
|
9004
|
+
PointLight._distanceProperty = Shader.getPropertyByName("u_pointLightDistance");
|
|
9005
|
+
})();
|
|
9006
|
+
(function() {
|
|
9007
|
+
PointLight._combinedData = {
|
|
9008
|
+
cullingMask: new Int32Array(Light._maxLight * 2),
|
|
9009
|
+
color: new Float32Array(Light._maxLight * 3),
|
|
9010
|
+
position: new Float32Array(Light._maxLight * 3),
|
|
9011
|
+
distance: new Float32Array(Light._maxLight)
|
|
9012
|
+
};
|
|
9013
|
+
})();
|
|
8941
9014
|
/**
|
|
8942
9015
|
* Spot light.
|
|
8943
9016
|
*/ var SpotLight = /*#__PURE__*/ function(Light) {
|
|
@@ -9010,7 +9083,7 @@ PointLight._combinedData = {
|
|
|
9010
9083
|
shaderData.setFloatArray(SpotLight._angleCosProperty, data.angleCos);
|
|
9011
9084
|
shaderData.setFloatArray(SpotLight._penumbraCosProperty, data.penumbraCos);
|
|
9012
9085
|
};
|
|
9013
|
-
|
|
9086
|
+
_create_class$2(SpotLight, [
|
|
9014
9087
|
{
|
|
9015
9088
|
key: "position",
|
|
9016
9089
|
get: /**
|
|
@@ -9052,22 +9125,38 @@ PointLight._combinedData = {
|
|
|
9052
9125
|
]);
|
|
9053
9126
|
return SpotLight;
|
|
9054
9127
|
}(Light);
|
|
9055
|
-
|
|
9056
|
-
SpotLight.
|
|
9057
|
-
|
|
9058
|
-
|
|
9059
|
-
SpotLight.
|
|
9060
|
-
|
|
9061
|
-
|
|
9062
|
-
SpotLight.
|
|
9063
|
-
|
|
9064
|
-
|
|
9065
|
-
|
|
9066
|
-
|
|
9067
|
-
|
|
9068
|
-
|
|
9069
|
-
|
|
9070
|
-
|
|
9128
|
+
(function() {
|
|
9129
|
+
SpotLight._cullingMaskProperty = Shader.getPropertyByName("u_spotLightCullingMask");
|
|
9130
|
+
})();
|
|
9131
|
+
(function() {
|
|
9132
|
+
SpotLight._colorProperty = Shader.getPropertyByName("u_spotLightColor");
|
|
9133
|
+
})();
|
|
9134
|
+
(function() {
|
|
9135
|
+
SpotLight._positionProperty = Shader.getPropertyByName("u_spotLightPosition");
|
|
9136
|
+
})();
|
|
9137
|
+
(function() {
|
|
9138
|
+
SpotLight._directionProperty = Shader.getPropertyByName("u_spotLightDirection");
|
|
9139
|
+
})();
|
|
9140
|
+
(function() {
|
|
9141
|
+
SpotLight._distanceProperty = Shader.getPropertyByName("u_spotLightDistance");
|
|
9142
|
+
})();
|
|
9143
|
+
(function() {
|
|
9144
|
+
SpotLight._angleCosProperty = Shader.getPropertyByName("u_spotLightAngleCos");
|
|
9145
|
+
})();
|
|
9146
|
+
(function() {
|
|
9147
|
+
SpotLight._penumbraCosProperty = Shader.getPropertyByName("u_spotLightPenumbraCos");
|
|
9148
|
+
})();
|
|
9149
|
+
(function() {
|
|
9150
|
+
SpotLight._combinedData = {
|
|
9151
|
+
cullingMask: new Int32Array(Light._maxLight * 2),
|
|
9152
|
+
color: new Float32Array(Light._maxLight * 3),
|
|
9153
|
+
position: new Float32Array(Light._maxLight * 3),
|
|
9154
|
+
direction: new Float32Array(Light._maxLight * 3),
|
|
9155
|
+
distance: new Float32Array(Light._maxLight),
|
|
9156
|
+
angleCos: new Float32Array(Light._maxLight),
|
|
9157
|
+
penumbraCos: new Float32Array(Light._maxLight)
|
|
9158
|
+
};
|
|
9159
|
+
})();
|
|
9071
9160
|
/**
|
|
9072
9161
|
* Light manager.
|
|
9073
9162
|
*/ var LightManager = /*#__PURE__*/ function() {
|
|
@@ -9620,7 +9709,7 @@ SpotLight._combinedData = {
|
|
|
9620
9709
|
/**
|
|
9621
9710
|
* @override
|
|
9622
9711
|
*/ _proto._onDestroy = function _onDestroy() {};
|
|
9623
|
-
|
|
9712
|
+
_create_class$2(Material, [
|
|
9624
9713
|
{
|
|
9625
9714
|
key: "shader",
|
|
9626
9715
|
get: /**
|
|
@@ -9724,9 +9813,15 @@ var RenderElement = function RenderElement() {};
|
|
|
9724
9813
|
};
|
|
9725
9814
|
return RenderContext;
|
|
9726
9815
|
}();
|
|
9727
|
-
|
|
9728
|
-
RenderContext.
|
|
9729
|
-
|
|
9816
|
+
(function() {
|
|
9817
|
+
/** @internal */ RenderContext._vpMatrixProperty = Shader.getPropertyByName("u_VPMat");
|
|
9818
|
+
})();
|
|
9819
|
+
(function() {
|
|
9820
|
+
RenderContext._viewMatrixProperty = Shader.getPropertyByName("u_viewMat");
|
|
9821
|
+
})();
|
|
9822
|
+
(function() {
|
|
9823
|
+
RenderContext._projectionMatrixProperty = Shader.getPropertyByName("u_projMat");
|
|
9824
|
+
})();
|
|
9730
9825
|
var SpriteElement = /*#__PURE__*/ function(RenderElement) {
|
|
9731
9826
|
var SpriteElement = function SpriteElement() {
|
|
9732
9827
|
var _this;
|
|
@@ -9776,7 +9871,6 @@ exports.Renderer = (_Renderer = /*#__PURE__*/ function(Component) {
|
|
|
9776
9871
|
var Renderer1 = function Renderer1(entity) {
|
|
9777
9872
|
var _this;
|
|
9778
9873
|
_this = Component.call(this, entity) || this;
|
|
9779
|
-
/** Whether cast shadow. */ _this.castShadows = true;
|
|
9780
9874
|
/** ShaderData related to renderer. */ _this.shaderData = new ShaderData(ShaderDataGroup.Renderer);
|
|
9781
9875
|
/** @internal */ _this._onUpdateIndex = -1;
|
|
9782
9876
|
/** @internal */ _this._rendererIndex = -1;
|
|
@@ -9793,11 +9887,12 @@ exports.Renderer = (_Renderer = /*#__PURE__*/ function(Component) {
|
|
|
9793
9887
|
_this._priority = 0;
|
|
9794
9888
|
_this._receiveShadows = true;
|
|
9795
9889
|
_this._rendererLayer = new miniprogram$7.Vector4();
|
|
9890
|
+
/** Whether cast shadow. */ _this.castShadows = true;
|
|
9796
9891
|
var prototype = exports.Renderer.prototype;
|
|
9797
9892
|
var shaderData = _this.shaderData;
|
|
9798
9893
|
_this._overrideUpdate = _this.update !== prototype.update;
|
|
9799
9894
|
shaderData._addRefCount(1);
|
|
9800
|
-
_this._onTransformChanged = _this._onTransformChanged.bind(
|
|
9895
|
+
_this._onTransformChanged = _this._onTransformChanged.bind(_assert_this_initialized(_this));
|
|
9801
9896
|
_this._registerEntityTransformListener();
|
|
9802
9897
|
shaderData.enableMacro(exports.Renderer._receiveShadowMacro);
|
|
9803
9898
|
shaderData.setVector4(exports.Renderer._rendererLayerProperty, _this._rendererLayer);
|
|
@@ -9983,7 +10078,7 @@ exports.Renderer = (_Renderer = /*#__PURE__*/ function(Component) {
|
|
|
9983
10078
|
_proto._onTransformChanged = function _onTransformChanged(type) {
|
|
9984
10079
|
this._dirtyUpdateFlag |= 0x1;
|
|
9985
10080
|
};
|
|
9986
|
-
|
|
10081
|
+
_create_class$2(Renderer1, [
|
|
9987
10082
|
{
|
|
9988
10083
|
key: "isCulled",
|
|
9989
10084
|
get: /**
|
|
@@ -10049,7 +10144,25 @@ exports.Renderer = (_Renderer = /*#__PURE__*/ function(Component) {
|
|
|
10049
10144
|
}
|
|
10050
10145
|
]);
|
|
10051
10146
|
return Renderer1;
|
|
10052
|
-
}(Component),
|
|
10147
|
+
}(Component), function() {
|
|
10148
|
+
_Renderer._tempVector0 = new miniprogram$7.Vector3();
|
|
10149
|
+
}(), function() {
|
|
10150
|
+
_Renderer._receiveShadowMacro = Shader.getMacroByName("OASIS_RECEIVE_SHADOWS");
|
|
10151
|
+
}(), function() {
|
|
10152
|
+
_Renderer._localMatrixProperty = Shader.getPropertyByName("u_localMat");
|
|
10153
|
+
}(), function() {
|
|
10154
|
+
_Renderer._worldMatrixProperty = Shader.getPropertyByName("u_modelMat");
|
|
10155
|
+
}(), function() {
|
|
10156
|
+
_Renderer._mvMatrixProperty = Shader.getPropertyByName("u_MVMat");
|
|
10157
|
+
}(), function() {
|
|
10158
|
+
_Renderer._mvpMatrixProperty = Shader.getPropertyByName("u_MVPMat");
|
|
10159
|
+
}(), function() {
|
|
10160
|
+
_Renderer._mvInvMatrixProperty = Shader.getPropertyByName("u_MVInvMat");
|
|
10161
|
+
}(), function() {
|
|
10162
|
+
_Renderer._normalMatrixProperty = Shader.getPropertyByName("u_normalMat");
|
|
10163
|
+
}(), function() {
|
|
10164
|
+
_Renderer._rendererLayerProperty = Shader.getPropertyByName("oasis_RendererLayer");
|
|
10165
|
+
}(), _Renderer);
|
|
10053
10166
|
__decorate$1([
|
|
10054
10167
|
deepClone
|
|
10055
10168
|
], exports.Renderer.prototype, "shaderData", void 0);
|
|
@@ -10176,14 +10289,18 @@ var SimpleSpriteAssembler = (_SimpleSpriteAssembler = /*#__PURE__*/ function() {
|
|
|
10176
10289
|
renderUVs[3].set(right, top);
|
|
10177
10290
|
};
|
|
10178
10291
|
return SimpleSpriteAssembler1;
|
|
10179
|
-
}(),
|
|
10180
|
-
|
|
10181
|
-
|
|
10182
|
-
|
|
10183
|
-
|
|
10184
|
-
|
|
10185
|
-
|
|
10186
|
-
|
|
10292
|
+
}(), function() {
|
|
10293
|
+
_SimpleSpriteAssembler._rectangleTriangles = [
|
|
10294
|
+
0,
|
|
10295
|
+
1,
|
|
10296
|
+
2,
|
|
10297
|
+
2,
|
|
10298
|
+
1,
|
|
10299
|
+
3
|
|
10300
|
+
];
|
|
10301
|
+
}(), function() {
|
|
10302
|
+
_SimpleSpriteAssembler._worldMatrix = new miniprogram$7.Matrix();
|
|
10303
|
+
}(), _SimpleSpriteAssembler);
|
|
10187
10304
|
SimpleSpriteAssembler = __decorate$1([
|
|
10188
10305
|
StaticInterfaceImplement$1()
|
|
10189
10306
|
], SimpleSpriteAssembler);
|
|
@@ -10264,10 +10381,10 @@ SimpleSpriteAssembler = __decorate$1([
|
|
|
10264
10381
|
_this._flipY = false;
|
|
10265
10382
|
_this._alphaCutoff = 0.5;
|
|
10266
10383
|
_this._renderData = new RenderData2D(4, [], []);
|
|
10267
|
-
SimpleSpriteAssembler.resetData(
|
|
10384
|
+
SimpleSpriteAssembler.resetData(_assert_this_initialized(_this));
|
|
10268
10385
|
_this.setMaterial(_this._engine._spriteMaskDefaultMaterial);
|
|
10269
10386
|
_this.shaderData.setFloat(SpriteMask._alphaCutoffProperty, _this._alphaCutoff);
|
|
10270
|
-
_this._onSpriteChange = _this._onSpriteChange.bind(
|
|
10387
|
+
_this._onSpriteChange = _this._onSpriteChange.bind(_assert_this_initialized(_this));
|
|
10271
10388
|
return _this;
|
|
10272
10389
|
}
|
|
10273
10390
|
var _proto = SpriteMask.prototype;
|
|
@@ -10335,7 +10452,7 @@ SimpleSpriteAssembler = __decorate$1([
|
|
|
10335
10452
|
break;
|
|
10336
10453
|
}
|
|
10337
10454
|
};
|
|
10338
|
-
|
|
10455
|
+
_create_class$2(SpriteMask, [
|
|
10339
10456
|
{
|
|
10340
10457
|
key: "width",
|
|
10341
10458
|
get: /**
|
|
@@ -10437,8 +10554,12 @@ SimpleSpriteAssembler = __decorate$1([
|
|
|
10437
10554
|
]);
|
|
10438
10555
|
return SpriteMask;
|
|
10439
10556
|
}(exports.Renderer);
|
|
10440
|
-
|
|
10441
|
-
/** @internal */ SpriteMask.
|
|
10557
|
+
(function() {
|
|
10558
|
+
/** @internal */ SpriteMask._textureProperty = Shader.getPropertyByName("u_maskTexture");
|
|
10559
|
+
})();
|
|
10560
|
+
(function() {
|
|
10561
|
+
/** @internal */ SpriteMask._alphaCutoffProperty = Shader.getPropertyByName("u_maskAlphaCutoff");
|
|
10562
|
+
})();
|
|
10442
10563
|
__decorate$1([
|
|
10443
10564
|
assignmentClone
|
|
10444
10565
|
], SpriteMask.prototype, "influenceLayers", void 0);
|
|
@@ -10639,7 +10760,7 @@ var BufferUtil = /*#__PURE__*/ function() {
|
|
|
10639
10760
|
this._glElementInfo = BufferUtil._getElementInfo(this.format);
|
|
10640
10761
|
this._instanceStepRate = Math.floor(instanceStepRate);
|
|
10641
10762
|
};
|
|
10642
|
-
|
|
10763
|
+
_create_class$2(VertexElement, [
|
|
10643
10764
|
{
|
|
10644
10765
|
key: "semantic",
|
|
10645
10766
|
get: /**
|
|
@@ -10796,7 +10917,7 @@ var BufferUtil = /*#__PURE__*/ function() {
|
|
|
10796
10917
|
gl.bufferData(this._glBindTarget, dataLength, this._glBufferUsage);
|
|
10797
10918
|
this._byteLength = dataLength;
|
|
10798
10919
|
};
|
|
10799
|
-
|
|
10920
|
+
_create_class$2(Buffer, [
|
|
10800
10921
|
{
|
|
10801
10922
|
key: "type",
|
|
10802
10923
|
get: /**
|
|
@@ -10843,7 +10964,7 @@ var BufferUtil = /*#__PURE__*/ function() {
|
|
|
10843
10964
|
this._buffer = buffer;
|
|
10844
10965
|
this._format = format;
|
|
10845
10966
|
};
|
|
10846
|
-
|
|
10967
|
+
_create_class$2(IndexBufferBinding, [
|
|
10847
10968
|
{
|
|
10848
10969
|
key: "buffer",
|
|
10849
10970
|
get: /**
|
|
@@ -10889,8 +11010,8 @@ var BufferUtil = /*#__PURE__*/ function() {
|
|
|
10889
11010
|
_this._bounds = new miniprogram$7.BoundingBox();
|
|
10890
11011
|
_this._subMeshes = [];
|
|
10891
11012
|
_this.name = name;
|
|
10892
|
-
_this._platformPrimitive = _this._engine._hardwareRenderer.createPlatformPrimitive(
|
|
10893
|
-
_this._onBoundsChanged = _this._onBoundsChanged.bind(
|
|
11013
|
+
_this._platformPrimitive = _this._engine._hardwareRenderer.createPlatformPrimitive(_assert_this_initialized(_this));
|
|
11014
|
+
_this._onBoundsChanged = _this._onBoundsChanged.bind(_assert_this_initialized(_this));
|
|
10894
11015
|
var bounds = _this._bounds;
|
|
10895
11016
|
// @ts-ignore
|
|
10896
11017
|
bounds.min._onValueChanged = _this._onBoundsChanged;
|
|
@@ -11008,7 +11129,7 @@ var BufferUtil = /*#__PURE__*/ function() {
|
|
|
11008
11129
|
_proto._onBoundsChanged = function _onBoundsChanged() {
|
|
11009
11130
|
this._updateFlagManager.dispatch(0x1);
|
|
11010
11131
|
};
|
|
11011
|
-
|
|
11132
|
+
_create_class$2(Mesh, [
|
|
11012
11133
|
{
|
|
11013
11134
|
key: "bounds",
|
|
11014
11135
|
get: /**
|
|
@@ -11053,7 +11174,7 @@ var MeshModifyFlags;
|
|
|
11053
11174
|
this._buffer = buffer;
|
|
11054
11175
|
this._stride = stride;
|
|
11055
11176
|
};
|
|
11056
|
-
|
|
11177
|
+
_create_class$2(VertexBufferBinding, [
|
|
11057
11178
|
{
|
|
11058
11179
|
key: "buffer",
|
|
11059
11180
|
get: /**
|
|
@@ -11498,13 +11619,27 @@ var MeshModifyFlags;
|
|
|
11498
11619
|
};
|
|
11499
11620
|
return BlendShapeManager;
|
|
11500
11621
|
}();
|
|
11501
|
-
|
|
11502
|
-
BlendShapeManager.
|
|
11503
|
-
|
|
11504
|
-
|
|
11505
|
-
BlendShapeManager.
|
|
11506
|
-
|
|
11507
|
-
|
|
11622
|
+
(function() {
|
|
11623
|
+
BlendShapeManager._blendShapeMacro = Shader.getMacroByName("OASIS_BLENDSHAPE");
|
|
11624
|
+
})();
|
|
11625
|
+
(function() {
|
|
11626
|
+
BlendShapeManager._blendShapeTextureMacro = Shader.getMacroByName("OASIS_BLENDSHAPE_TEXTURE");
|
|
11627
|
+
})();
|
|
11628
|
+
(function() {
|
|
11629
|
+
BlendShapeManager._blendShapeNormalMacro = Shader.getMacroByName("OASIS_BLENDSHAPE_NORMAL");
|
|
11630
|
+
})();
|
|
11631
|
+
(function() {
|
|
11632
|
+
BlendShapeManager._blendShapeTangentMacro = Shader.getMacroByName("OASIS_BLENDSHAPE_TANGENT");
|
|
11633
|
+
})();
|
|
11634
|
+
(function() {
|
|
11635
|
+
BlendShapeManager._blendShapeWeightsProperty = Shader.getPropertyByName("u_blendShapeWeights");
|
|
11636
|
+
})();
|
|
11637
|
+
(function() {
|
|
11638
|
+
BlendShapeManager._blendShapeTextureProperty = Shader.getPropertyByName("u_blendShapeTexture");
|
|
11639
|
+
})();
|
|
11640
|
+
(function() {
|
|
11641
|
+
BlendShapeManager._blendShapeTextureInfoProperty = Shader.getPropertyByName("u_blendShapeTextureInfo");
|
|
11642
|
+
})();
|
|
11508
11643
|
/**
|
|
11509
11644
|
* Vertex attribute types of a vertex in a ModelMesh.
|
|
11510
11645
|
*/ var VertexAttribute;
|
|
@@ -11558,7 +11693,7 @@ BlendShapeManager._blendShapeTextureInfoProperty = Shader.getPropertyByName("u_b
|
|
|
11558
11693
|
_this._customVertexElements = [];
|
|
11559
11694
|
_this._vertexCountChanged = false;
|
|
11560
11695
|
_this.name = name;
|
|
11561
|
-
_this._blendShapeManager = new BlendShapeManager(engine,
|
|
11696
|
+
_this._blendShapeManager = new BlendShapeManager(engine, _assert_this_initialized(_this));
|
|
11562
11697
|
return _this;
|
|
11563
11698
|
};
|
|
11564
11699
|
_inherits$2(ModelMesh, Mesh);
|
|
@@ -12509,7 +12644,7 @@ BlendShapeManager._blendShapeTextureInfoProperty = Shader.getPropertyByName("u_b
|
|
|
12509
12644
|
this._uv7 = null;
|
|
12510
12645
|
this._blendShapeManager._releaseMemoryCache();
|
|
12511
12646
|
};
|
|
12512
|
-
|
|
12647
|
+
_create_class$2(ModelMesh, [
|
|
12513
12648
|
{
|
|
12514
12649
|
key: "accessible",
|
|
12515
12650
|
get: /**
|
|
@@ -12577,11 +12712,21 @@ BlendShapeManager._blendShapeTextureInfoProperty = Shader.getPropertyByName("u_b
|
|
|
12577
12712
|
]);
|
|
12578
12713
|
return ModelMesh;
|
|
12579
12714
|
}(Mesh);
|
|
12580
|
-
|
|
12581
|
-
ModelMesh.
|
|
12582
|
-
|
|
12583
|
-
|
|
12584
|
-
ModelMesh.
|
|
12715
|
+
(function() {
|
|
12716
|
+
ModelMesh._tempVec0 = new miniprogram$7.Vector3();
|
|
12717
|
+
})();
|
|
12718
|
+
(function() {
|
|
12719
|
+
ModelMesh._tempVec1 = new miniprogram$7.Vector3();
|
|
12720
|
+
})();
|
|
12721
|
+
(function() {
|
|
12722
|
+
ModelMesh._tempVec2 = new miniprogram$7.Vector3();
|
|
12723
|
+
})();
|
|
12724
|
+
(function() {
|
|
12725
|
+
ModelMesh._tempVec3 = new miniprogram$7.Vector3();
|
|
12726
|
+
})();
|
|
12727
|
+
(function() {
|
|
12728
|
+
ModelMesh._tempVec4 = new miniprogram$7.Vector3();
|
|
12729
|
+
})();
|
|
12585
12730
|
var VertexChangedFlags;
|
|
12586
12731
|
(function(VertexChangedFlags) {
|
|
12587
12732
|
VertexChangedFlags[VertexChangedFlags["Position"] = 0x1] = "Position";
|
|
@@ -12621,7 +12766,7 @@ var VertexChangedFlags;
|
|
|
12621
12766
|
var MeshRenderer = function MeshRenderer(entity) {
|
|
12622
12767
|
var _this;
|
|
12623
12768
|
_this = Renderer.call(this, entity) || this;
|
|
12624
|
-
_this._onMeshChanged = _this._onMeshChanged.bind(
|
|
12769
|
+
_this._onMeshChanged = _this._onMeshChanged.bind(_assert_this_initialized(_this));
|
|
12625
12770
|
return _this;
|
|
12626
12771
|
};
|
|
12627
12772
|
_inherits$2(MeshRenderer, Renderer);
|
|
@@ -12725,7 +12870,7 @@ var VertexChangedFlags;
|
|
|
12725
12870
|
type & MeshModifyFlags.Bounds && (this._dirtyUpdateFlag |= RendererUpdateFlags.WorldVolume);
|
|
12726
12871
|
type & MeshModifyFlags.VertexElements && (this._dirtyUpdateFlag |= 0x2);
|
|
12727
12872
|
};
|
|
12728
|
-
|
|
12873
|
+
_create_class$2(MeshRenderer, [
|
|
12729
12874
|
{
|
|
12730
12875
|
key: "mesh",
|
|
12731
12876
|
get: /**
|
|
@@ -12742,11 +12887,21 @@ var VertexChangedFlags;
|
|
|
12742
12887
|
]);
|
|
12743
12888
|
return MeshRenderer;
|
|
12744
12889
|
}(exports.Renderer);
|
|
12745
|
-
|
|
12746
|
-
MeshRenderer.
|
|
12747
|
-
|
|
12748
|
-
|
|
12749
|
-
MeshRenderer.
|
|
12890
|
+
(function() {
|
|
12891
|
+
MeshRenderer._uvMacro = Shader.getMacroByName("O3_HAS_UV");
|
|
12892
|
+
})();
|
|
12893
|
+
(function() {
|
|
12894
|
+
MeshRenderer._uv1Macro = Shader.getMacroByName("O3_HAS_UV1");
|
|
12895
|
+
})();
|
|
12896
|
+
(function() {
|
|
12897
|
+
MeshRenderer._normalMacro = Shader.getMacroByName("O3_HAS_NORMAL");
|
|
12898
|
+
})();
|
|
12899
|
+
(function() {
|
|
12900
|
+
MeshRenderer._tangentMacro = Shader.getMacroByName("O3_HAS_TANGENT");
|
|
12901
|
+
})();
|
|
12902
|
+
(function() {
|
|
12903
|
+
MeshRenderer._vertexColorMacro = Shader.getMacroByName("O3_HAS_VERTEXCOLOR");
|
|
12904
|
+
})();
|
|
12750
12905
|
__decorate$1([
|
|
12751
12906
|
ignoreClone
|
|
12752
12907
|
], MeshRenderer.prototype, "_mesh", void 0);
|
|
@@ -12845,7 +13000,7 @@ var rePropName = RegExp("[^.[\\]]+" + "|" + // Or match property names within br
|
|
|
12845
13000
|
// For renderer is "ANGLE (AMD, AMD Radeon(TM) Graphics Direct3011 vs_5_0 ps_5_0, D3011)", compile shader si very slow because of max uniform is 4096.
|
|
12846
13001
|
maxVertexUniformVectors = Math.min(maxVertexUniformVectors, 256);
|
|
12847
13002
|
_this._maxVertexUniformVectors = maxVertexUniformVectors;
|
|
12848
|
-
_this._onLocalBoundsChanged = _this._onLocalBoundsChanged.bind(
|
|
13003
|
+
_this._onLocalBoundsChanged = _this._onLocalBoundsChanged.bind(_assert_this_initialized(_this));
|
|
12849
13004
|
var localBounds = _this._localBounds;
|
|
12850
13005
|
// @ts-ignore
|
|
12851
13006
|
localBounds.min._onValueChanged = _this._onLocalBoundsChanged;
|
|
@@ -13044,7 +13199,7 @@ var rePropName = RegExp("[^.[\\]]+" + "|" + // Or match property names within br
|
|
|
13044
13199
|
_proto._onLocalBoundsChanged = function _onLocalBoundsChanged() {
|
|
13045
13200
|
this._dirtyUpdateFlag |= RendererUpdateFlags.WorldVolume;
|
|
13046
13201
|
};
|
|
13047
|
-
|
|
13202
|
+
_create_class$2(SkinnedMeshRenderer, [
|
|
13048
13203
|
{
|
|
13049
13204
|
key: "blendShapeWeights",
|
|
13050
13205
|
get: /**
|
|
@@ -13109,10 +13264,18 @@ var rePropName = RegExp("[^.[\\]]+" + "|" + // Or match property names within br
|
|
|
13109
13264
|
]);
|
|
13110
13265
|
return SkinnedMeshRenderer;
|
|
13111
13266
|
}(MeshRenderer);
|
|
13112
|
-
|
|
13113
|
-
SkinnedMeshRenderer.
|
|
13114
|
-
|
|
13115
|
-
|
|
13267
|
+
(function() {
|
|
13268
|
+
SkinnedMeshRenderer._tempMatrix = new miniprogram$7.Matrix();
|
|
13269
|
+
})();
|
|
13270
|
+
(function() {
|
|
13271
|
+
SkinnedMeshRenderer._jointCountProperty = Shader.getPropertyByName("u_jointCount");
|
|
13272
|
+
})();
|
|
13273
|
+
(function() {
|
|
13274
|
+
SkinnedMeshRenderer._jointSamplerProperty = Shader.getPropertyByName("u_jointSampler");
|
|
13275
|
+
})();
|
|
13276
|
+
(function() {
|
|
13277
|
+
SkinnedMeshRenderer._jointMatrixProperty = Shader.getPropertyByName("u_jointMatrix");
|
|
13278
|
+
})();
|
|
13116
13279
|
__decorate$1([
|
|
13117
13280
|
ignoreClone
|
|
13118
13281
|
], SkinnedMeshRenderer.prototype, "_hasInitSkin", void 0);
|
|
@@ -13871,7 +14034,7 @@ __decorate$1([
|
|
|
13871
14034
|
}
|
|
13872
14035
|
this._setIndexBufferBinding(binding);
|
|
13873
14036
|
};
|
|
13874
|
-
|
|
14037
|
+
_create_class$2(BufferMesh, [
|
|
13875
14038
|
{
|
|
13876
14039
|
key: "instanceCount",
|
|
13877
14040
|
get: /**
|
|
@@ -13983,7 +14146,7 @@ __decorate$1([
|
|
|
13983
14146
|
this._layoutChangeManager.dispatch(0, this);
|
|
13984
14147
|
}
|
|
13985
14148
|
};
|
|
13986
|
-
|
|
14149
|
+
_create_class$2(BlendShape, [
|
|
13987
14150
|
{
|
|
13988
14151
|
key: "frames",
|
|
13989
14152
|
get: /**
|
|
@@ -14140,8 +14303,12 @@ var Basic2DBatcher = /*#__PURE__*/ function() {
|
|
|
14140
14303
|
};
|
|
14141
14304
|
return Basic2DBatcher;
|
|
14142
14305
|
}();
|
|
14143
|
-
|
|
14144
|
-
Basic2DBatcher.
|
|
14306
|
+
(function() {
|
|
14307
|
+
/** The maximum number of vertex. */ Basic2DBatcher.MAX_VERTEX_COUNT = 4096;
|
|
14308
|
+
})();
|
|
14309
|
+
(function() {
|
|
14310
|
+
Basic2DBatcher._canUploadSameBuffer = true;
|
|
14311
|
+
})();
|
|
14145
14312
|
var SpriteMaskBatcher = /*#__PURE__*/ function(Basic2DBatcher) {
|
|
14146
14313
|
var SpriteMaskBatcher = function SpriteMaskBatcher() {
|
|
14147
14314
|
return Basic2DBatcher.apply(this, arguments);
|
|
@@ -14350,9 +14517,15 @@ var TextRenderElement = /*#__PURE__*/ function(RenderElement) {
|
|
|
14350
14517
|
};
|
|
14351
14518
|
return Sky;
|
|
14352
14519
|
}();
|
|
14353
|
-
|
|
14354
|
-
Sky.
|
|
14355
|
-
|
|
14520
|
+
(function() {
|
|
14521
|
+
Sky._epsilon = 1e-6;
|
|
14522
|
+
})();
|
|
14523
|
+
(function() {
|
|
14524
|
+
Sky._viewProjMatrix = new miniprogram$7.Matrix();
|
|
14525
|
+
})();
|
|
14526
|
+
(function() {
|
|
14527
|
+
Sky._projectionMatrix = new miniprogram$7.Matrix(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, Sky._epsilon - 1, -1, 0, 0, 0, 0);
|
|
14528
|
+
})();
|
|
14356
14529
|
/**
|
|
14357
14530
|
* Background of scene.
|
|
14358
14531
|
*/ var Background = /*#__PURE__*/ function() {
|
|
@@ -14433,7 +14606,7 @@ Sky._projectionMatrix = new miniprogram$7.Matrix(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, S
|
|
|
14433
14606
|
mesh.addSubMesh(0, indices.length);
|
|
14434
14607
|
return mesh;
|
|
14435
14608
|
};
|
|
14436
|
-
|
|
14609
|
+
_create_class$2(Background, [
|
|
14437
14610
|
{
|
|
14438
14611
|
key: "texture",
|
|
14439
14612
|
get: /**
|
|
@@ -14598,7 +14771,7 @@ Sky._projectionMatrix = new miniprogram$7.Matrix(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, S
|
|
|
14598
14771
|
out[25] = src[25] * 0.429042;
|
|
14599
14772
|
out[26] = src[26] * 0.429042;
|
|
14600
14773
|
};
|
|
14601
|
-
|
|
14774
|
+
_create_class$2(AmbientLight, [
|
|
14602
14775
|
{
|
|
14603
14776
|
key: "specularTextureDecodeRGBM",
|
|
14604
14777
|
get: /**
|
|
@@ -14709,15 +14882,33 @@ Sky._projectionMatrix = new miniprogram$7.Matrix(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, S
|
|
|
14709
14882
|
]);
|
|
14710
14883
|
return AmbientLight;
|
|
14711
14884
|
}();
|
|
14712
|
-
|
|
14713
|
-
AmbientLight.
|
|
14714
|
-
|
|
14715
|
-
|
|
14716
|
-
AmbientLight.
|
|
14717
|
-
|
|
14718
|
-
|
|
14719
|
-
AmbientLight.
|
|
14720
|
-
|
|
14885
|
+
(function() {
|
|
14886
|
+
AmbientLight._shMacro = Shader.getMacroByName("O3_USE_SH");
|
|
14887
|
+
})();
|
|
14888
|
+
(function() {
|
|
14889
|
+
AmbientLight._specularMacro = Shader.getMacroByName("O3_USE_SPECULAR_ENV");
|
|
14890
|
+
})();
|
|
14891
|
+
(function() {
|
|
14892
|
+
AmbientLight._decodeRGBMMacro = Shader.getMacroByName("O3_DECODE_ENV_RGBM");
|
|
14893
|
+
})();
|
|
14894
|
+
(function() {
|
|
14895
|
+
AmbientLight._diffuseColorProperty = Shader.getPropertyByName("u_envMapLight.diffuse");
|
|
14896
|
+
})();
|
|
14897
|
+
(function() {
|
|
14898
|
+
AmbientLight._diffuseSHProperty = Shader.getPropertyByName("u_env_sh");
|
|
14899
|
+
})();
|
|
14900
|
+
(function() {
|
|
14901
|
+
AmbientLight._diffuseIntensityProperty = Shader.getPropertyByName("u_envMapLight.diffuseIntensity");
|
|
14902
|
+
})();
|
|
14903
|
+
(function() {
|
|
14904
|
+
AmbientLight._specularTextureProperty = Shader.getPropertyByName("u_env_specularSampler");
|
|
14905
|
+
})();
|
|
14906
|
+
(function() {
|
|
14907
|
+
AmbientLight._specularIntensityProperty = Shader.getPropertyByName("u_envMapLight.specularIntensity");
|
|
14908
|
+
})();
|
|
14909
|
+
(function() {
|
|
14910
|
+
AmbientLight._mipLevelProperty = Shader.getPropertyByName("u_envMapLight.mipMapLevel");
|
|
14911
|
+
})();
|
|
14721
14912
|
/**
|
|
14722
14913
|
* Scene.
|
|
14723
14914
|
*/ var Scene = /*#__PURE__*/ function(EngineObject) {
|
|
@@ -14747,7 +14938,7 @@ AmbientLight._mipLevelProperty = Shader.getPropertyByName("u_envMapLight.mipMapL
|
|
|
14747
14938
|
var shaderData = _this.shaderData;
|
|
14748
14939
|
shaderData._addRefCount(1);
|
|
14749
14940
|
_this.ambientLight = new AmbientLight();
|
|
14750
|
-
engine.sceneManager._allScenes.push(
|
|
14941
|
+
engine.sceneManager._allScenes.push(_assert_this_initialized(_this));
|
|
14751
14942
|
shaderData.enableMacro("OASIS_FOG_MODE", _this._fogMode.toString());
|
|
14752
14943
|
shaderData.enableMacro("CASCADED_COUNT", _this.shadowCascades.toString());
|
|
14753
14944
|
shaderData.setColor(Scene._fogColorProperty, _this._fogColor);
|
|
@@ -14954,7 +15145,7 @@ AmbientLight._mipLevelProperty = Shader.getPropertyByName("u_envMapLight.mipMapL
|
|
|
14954
15145
|
this._fogParams.z = density / Math.LN2;
|
|
14955
15146
|
this._fogParams.w = density / Math.sqrt(Math.LN2);
|
|
14956
15147
|
};
|
|
14957
|
-
|
|
15148
|
+
_create_class$2(Scene, [
|
|
14958
15149
|
{
|
|
14959
15150
|
key: "shadowCascades",
|
|
14960
15151
|
get: /**
|
|
@@ -15082,8 +15273,12 @@ AmbientLight._mipLevelProperty = Shader.getPropertyByName("u_envMapLight.mipMapL
|
|
|
15082
15273
|
]);
|
|
15083
15274
|
return Scene;
|
|
15084
15275
|
}(EngineObject);
|
|
15085
|
-
|
|
15086
|
-
Scene.
|
|
15276
|
+
(function() {
|
|
15277
|
+
Scene._fogColorProperty = Shader.getPropertyByName("oasis_FogColor");
|
|
15278
|
+
})();
|
|
15279
|
+
(function() {
|
|
15280
|
+
Scene._fogParamsProperty = Shader.getPropertyByName("oasis_FogParams");
|
|
15281
|
+
})();
|
|
15087
15282
|
/**
|
|
15088
15283
|
* Scene manager.
|
|
15089
15284
|
*/ var SceneManager = /*#__PURE__*/ function() {
|
|
@@ -15130,7 +15325,7 @@ Scene._fogParamsProperty = Shader.getPropertyByName("oasis_FogParams");
|
|
|
15130
15325
|
}
|
|
15131
15326
|
allScenes.length = 0;
|
|
15132
15327
|
};
|
|
15133
|
-
|
|
15328
|
+
_create_class$2(SceneManager, [
|
|
15134
15329
|
{
|
|
15135
15330
|
key: "activeScene",
|
|
15136
15331
|
get: /**
|
|
@@ -15150,11 +15345,11 @@ Scene._fogParamsProperty = Shader.getPropertyByName("oasis_FogParams");
|
|
|
15150
15345
|
]);
|
|
15151
15346
|
return SceneManager;
|
|
15152
15347
|
}();
|
|
15153
|
-
var blinnPhongFs = "#define GLSLIFY 1\n#include <common>\n#include <camera_declare>\n#include <uv_share>\n#include <normal_share>\n#include <color_share>\n#include <worldpos_share>\n#include <light_frag_define>\n#include <ShadowFragmentDeclaration>\n#include <mobile_material_frag>\n#include <
|
|
15348
|
+
var blinnPhongFs = "#define GLSLIFY 1\n#include <common>\n#include <camera_declare>\n#include <uv_share>\n#include <normal_share>\n#include <color_share>\n#include <worldpos_share>\n#include <light_frag_define>\n#include <ShadowFragmentDeclaration>\n#include <mobile_material_frag>\n#include <FogFragmentDeclaration>\n#include <normal_get>\nvoid main(){\n#include <begin_mobile_frag>\n#include <begin_viewdir_frag>\n#include <mobile_blinnphong_frag>\ngl_FragColor=emission+ambient+diffuse+specular;\n#ifdef OASIS_TRANSPARENT\ngl_FragColor.a=diffuse.a;\n#else\ngl_FragColor.a=1.0;\n#endif\n#include <FogFragment>\n#ifndef OASIS_COLORSPACE_GAMMA\ngl_FragColor=linearToGamma(gl_FragColor);\n#endif\n}"; // eslint-disable-line
|
|
15154
15349
|
var blinnPhongVs = "#define GLSLIFY 1\n#include <common>\n#include <common_vert>\n#include <blendShape_input>\n#include <uv_share>\n#include <color_share>\n#include <normal_share>\n#include <worldpos_share>\n#include <ShadowVertexDeclaration>\n#include <FogVertexDeclaration>\nvoid main(){\n#include <begin_position_vert>\n#include <begin_normal_vert>\n#include <blendShape_vert>\n#include <skinning_vert>\n#include <uv_vert>\n#include <color_vert>\n#include <normal_vert>\n#include <worldpos_vert>\n#include <position_vert>\n#include <ShadowVertex>\n#include <FogVertex>\n}"; // eslint-disable-line
|
|
15155
15350
|
var particleFs = "#define GLSLIFY 1\nvarying vec4 v_color;varying float v_lifeLeft;varying vec2 v_uv;uniform sampler2D u_texture;void main(){if(v_lifeLeft==1.0){discard;}float alphaFactor=1.0;\n#ifdef fadeIn\nfloat fadeInFactor=step(0.5,v_lifeLeft);alphaFactor=2.0*fadeInFactor*(1.0-v_lifeLeft)+(1.0-fadeInFactor);\n#endif\n#ifdef fadeOut\nfloat fadeOutFactor=step(0.5,v_lifeLeft);alphaFactor=alphaFactor*2.0*(1.0-fadeOutFactor)*v_lifeLeft+alphaFactor*fadeOutFactor;\n#endif\n#ifdef particleTexture\nvec4 tex=texture2D(u_texture,v_uv);\n#ifdef useOriginColor\ngl_FragColor=vec4(tex.rgb,alphaFactor*tex.a*v_color.w);\n#else\ngl_FragColor=vec4(v_color.xyz*tex.rgb,alphaFactor*tex.a*v_color.w);\n#endif\n#else\ngl_FragColor=vec4(v_color.xyz,alphaFactor*v_color.w);\n#endif\n}"; // eslint-disable-line
|
|
15156
15351
|
var particleVs = "#define GLSLIFY 1\nattribute vec3 a_position;attribute vec3 a_velocity;attribute vec3 a_acceleration;attribute vec4 a_color;attribute vec4 a_lifeAndSize;attribute vec2 a_rotation;attribute vec3 a_uv;attribute vec2 a_normalizedUv;uniform float u_time;uniform bool u_once;uniform mat4 u_MVPMat;varying vec4 v_color;varying float v_lifeLeft;varying vec2 v_uv;\n#ifdef is2d\nuniform mat4 u_viewInvMat;uniform mat4 u_projMat;uniform mat4 u_viewMat;uniform mat4 u_modelMat;\n#endif\nmat2 rotation2d(float angle){float s=sin(angle);float c=cos(angle);return mat2(c,-s,s,c);}void main(){v_color=a_color;v_uv=a_uv.xy;float life=a_lifeAndSize.y;float startTime=a_lifeAndSize.x;float deltaTime=max(mod(u_time-startTime,life),0.0);if((u_once&&u_time>life+startTime)){deltaTime=0.0;}v_lifeLeft=1.0-deltaTime/life;float scale=a_lifeAndSize.z;vec3 position=a_position+(a_velocity+a_acceleration*deltaTime*0.5)*deltaTime;\n#ifdef isScaleByLifetime\nscale*=v_lifeLeft;\n#else\nscale*=pow(a_lifeAndSize.w,deltaTime);\n#endif\n#ifdef rotateToVelocity\nvec3 v=a_velocity+a_acceleration*deltaTime;float angle=atan(v.z,v.x)*2.0;\n#else\nfloat deltaAngle=deltaTime*a_rotation.y;float angle=a_rotation.x+deltaAngle;\n#endif\n#ifdef is2d\nvec2 rotatedPoint=rotation2d(angle)*vec2(a_normalizedUv.x,a_normalizedUv.y*a_uv.z);vec3 basisX=u_viewInvMat[0].xyz;vec3 basisZ=u_viewInvMat[1].xyz;vec3 localPosition=vec3(basisX*rotatedPoint.x+basisZ*rotatedPoint.y)*scale+position;gl_Position=u_projMat*u_viewMat*vec4(localPosition+u_modelMat[3].xyz,1.);\n#else\n#ifdef rotateToVelocity\nfloat s=sin(angle);float c=cos(angle);\n#else\nfloat s=sin(angle);float c=cos(angle);\n#endif\nvec4 rotatedPoint=vec4((a_normalizedUv.x*c+a_normalizedUv.y*a_uv.z*s)*scale,0.,(a_normalizedUv.x*s-a_normalizedUv.y*a_uv.z*c)*scale,1.);vec4 orientation=vec4(0,0,0,1);vec4 q2=orientation+orientation;vec4 qx=orientation.xxxw*q2.xyzx;vec4 qy=orientation.xyyw*q2.xyzy;vec4 qz=orientation.xxzw*q2.xxzz;mat4 localMatrix=mat4((1.0-qy.y)-qz.z,qx.y+qz.w,qx.z-qy.w,0,qx.y-qz.w,(1.0-qx.x)-qz.z,qy.z+qx.w,0,qx.z+qy.w,qy.z-qx.w,(1.0-qx.x)-qy.y,0,position.x,position.y,position.z,1);rotatedPoint=localMatrix*rotatedPoint;gl_Position=u_MVPMat*rotatedPoint;\n#endif\n}"; // eslint-disable-line
|
|
15157
|
-
var pbrFs = "#define GLSLIFY 1\n#define IS_METALLIC_WORKFLOW\n#include <common>\n#include <camera_declare>\n#include <
|
|
15352
|
+
var pbrFs = "#define GLSLIFY 1\n#define IS_METALLIC_WORKFLOW\n#include <common>\n#include <camera_declare>\n#include <FogFragmentDeclaration>\n#include <uv_share>\n#include <normal_share>\n#include <color_share>\n#include <worldpos_share>\n#include <light_frag_define>\n#include <pbr_frag_define>\n#include <pbr_helper>\nvoid main(){\n#include <pbr_frag>\n#include <FogFragment>\n#ifndef OASIS_COLORSPACE_GAMMA\ngl_FragColor=linearToGamma(gl_FragColor);\n#endif\n}"; // eslint-disable-line
|
|
15158
15353
|
var pbrSpecularFs = "#define GLSLIFY 1\n#include <common>\n#include <camera_declare>\n#include <FogFragmentDeclaration>\n#include <uv_share>\n#include <normal_share>\n#include <color_share>\n#include <worldpos_share>\n#include <light_frag_define>\n#include <pbr_frag_define>\n#include <pbr_helper>\nvoid main(){\n#include <pbr_frag>\n#include <FogFragment>\n#ifndef OASIS_COLORSPACE_GAMMA\ngl_FragColor=linearToGamma(gl_FragColor);\n#endif\n}"; // eslint-disable-line
|
|
15159
15354
|
var pbrVs = "#define GLSLIFY 1\n#include <common>\n#include <common_vert>\n#include <blendShape_input>\n#include <uv_share>\n#include <color_share>\n#include <normal_share>\n#include <worldpos_share>\n#include <ShadowVertexDeclaration>\n#include <FogVertexDeclaration>\nvoid main(){\n#include <begin_position_vert>\n#include <begin_normal_vert>\n#include <blendShape_vert>\n#include <skinning_vert>\n#include <uv_vert>\n#include <color_vert>\n#include <normal_vert>\n#include <worldpos_vert>\n#include <position_vert>\n#include <ShadowVertex>\n#include <FogVertex>\n}"; // eslint-disable-line
|
|
15160
15355
|
var shadowMapFs = "#define GLSLIFY 1\n#ifdef OASIS_NO_DEPTH_TEXTURE\nvec4 pack(float depth){const vec4 bitShift=vec4(1.0,256.0,256.0*256.0,256.0*256.0*256.0);const vec4 bitMask=vec4(1.0/256.0,1.0/256.0,1.0/256.0,0.0);vec4 rgbaDepth=fract(depth*bitShift);rgbaDepth-=rgbaDepth.gbaa*bitMask;return rgbaDepth;}\n#endif\nvoid main(){\n#ifdef OASIS_NO_DEPTH_TEXTURE\ngl_FragColor=pack(gl_FragCoord.z);\n#else\ngl_FragColor=vec4(0.0,0.0,0.0,0.0);\n#endif\n}"; // eslint-disable-line
|
|
@@ -15279,8 +15474,8 @@ ShaderPool.init();
|
|
|
15279
15474
|
/** @internal */ _this._canSpriteBatch = true;
|
|
15280
15475
|
/** @internal @todo: temporary solution */ _this._macroCollection = new ShaderMacroCollection();
|
|
15281
15476
|
_this._settings = {};
|
|
15282
|
-
_this._resourceManager = new ResourceManager(
|
|
15283
|
-
_this._sceneManager = new SceneManager(
|
|
15477
|
+
_this._resourceManager = new ResourceManager(_assert_this_initialized(_this));
|
|
15478
|
+
_this._sceneManager = new SceneManager(_assert_this_initialized(_this));
|
|
15284
15479
|
_this._vSyncCount = 1;
|
|
15285
15480
|
_this._targetFrameRate = 60;
|
|
15286
15481
|
_this._time = new Time();
|
|
@@ -15304,25 +15499,25 @@ ShaderPool.init();
|
|
|
15304
15499
|
};
|
|
15305
15500
|
_this._hardwareRenderer = hardwareRenderer;
|
|
15306
15501
|
_this._hardwareRenderer.init(canvas);
|
|
15307
|
-
_this.physicsManager = new PhysicsManager(
|
|
15502
|
+
_this.physicsManager = new PhysicsManager(_assert_this_initialized(_this));
|
|
15308
15503
|
_this._canvas = canvas;
|
|
15309
|
-
_this._sceneManager.activeScene = new Scene(
|
|
15310
|
-
_this._spriteMaskManager = new SpriteMaskManager(
|
|
15504
|
+
_this._sceneManager.activeScene = new Scene(_assert_this_initialized(_this), "DefaultScene");
|
|
15505
|
+
_this._spriteMaskManager = new SpriteMaskManager(_assert_this_initialized(_this));
|
|
15311
15506
|
_this._spriteDefaultMaterial = _this._createSpriteMaterial();
|
|
15312
15507
|
_this._spriteMaskDefaultMaterial = _this._createSpriteMaskMaterial();
|
|
15313
|
-
_this._textDefaultFont = Font.createFromOS(
|
|
15508
|
+
_this._textDefaultFont = Font.createFromOS(_assert_this_initialized(_this), "Arial");
|
|
15314
15509
|
_this._textDefaultFont.isGCIgnored = false;
|
|
15315
|
-
_this.inputManager = new InputManager(
|
|
15510
|
+
_this.inputManager = new InputManager(_assert_this_initialized(_this));
|
|
15316
15511
|
var magentaPixel = new Uint8Array([
|
|
15317
15512
|
255,
|
|
15318
15513
|
0,
|
|
15319
15514
|
255,
|
|
15320
15515
|
255
|
|
15321
15516
|
]);
|
|
15322
|
-
var magentaTexture2D = new Texture2D(
|
|
15517
|
+
var magentaTexture2D = new Texture2D(_assert_this_initialized(_this), 1, 1, exports.TextureFormat.R8G8B8A8, false);
|
|
15323
15518
|
magentaTexture2D.setPixelBuffer(magentaPixel);
|
|
15324
15519
|
magentaTexture2D.isGCIgnored = true;
|
|
15325
|
-
var magentaTextureCube = new TextureCube(
|
|
15520
|
+
var magentaTextureCube = new TextureCube(_assert_this_initialized(_this), 1, exports.TextureFormat.R8G8B8A8, false);
|
|
15326
15521
|
magentaTextureCube.setPixelBuffer(exports.TextureCubeFace.PositiveX, magentaPixel);
|
|
15327
15522
|
magentaTextureCube.setPixelBuffer(exports.TextureCubeFace.NegativeX, magentaPixel);
|
|
15328
15523
|
magentaTextureCube.setPixelBuffer(exports.TextureCubeFace.PositiveY, magentaPixel);
|
|
@@ -15333,22 +15528,22 @@ ShaderPool.init();
|
|
|
15333
15528
|
if (!hardwareRenderer.canIUse(exports.GLCapabilityType.depthTexture)) {
|
|
15334
15529
|
_this._macroCollection.enable(Engine._noDepthTextureMacro);
|
|
15335
15530
|
} else {
|
|
15336
|
-
var depthTexture2D = new Texture2D(
|
|
15531
|
+
var depthTexture2D = new Texture2D(_assert_this_initialized(_this), 1, 1, exports.TextureFormat.Depth16, false);
|
|
15337
15532
|
depthTexture2D.isGCIgnored = true;
|
|
15338
15533
|
_this._depthTexture2D = depthTexture2D;
|
|
15339
15534
|
}
|
|
15340
15535
|
_this._magentaTexture2D = magentaTexture2D;
|
|
15341
15536
|
_this._magentaTextureCube = magentaTextureCube;
|
|
15342
15537
|
if (hardwareRenderer.isWebGL2) {
|
|
15343
|
-
var magentaTexture2DArray = new Texture2DArray(
|
|
15538
|
+
var magentaTexture2DArray = new Texture2DArray(_assert_this_initialized(_this), 1, 1, 1, exports.TextureFormat.R8G8B8A8, false);
|
|
15344
15539
|
magentaTexture2DArray.setPixelBuffer(0, magentaPixel);
|
|
15345
15540
|
magentaTexture2DArray.isGCIgnored = true;
|
|
15346
15541
|
_this._magentaTexture2DArray = magentaTexture2DArray;
|
|
15347
15542
|
}
|
|
15348
|
-
var magentaMaterial = new Material(
|
|
15543
|
+
var magentaMaterial = new Material(_assert_this_initialized(_this), Shader.find("unlit"));
|
|
15349
15544
|
magentaMaterial.shaderData.setColor("u_baseColor", new Color(1.0, 0.0, 1.01, 1.0));
|
|
15350
15545
|
_this._magentaMaterial = magentaMaterial;
|
|
15351
|
-
var backgroundTextureMaterial = new Material(
|
|
15546
|
+
var backgroundTextureMaterial = new Material(_assert_this_initialized(_this), Shader.find("background-texture"));
|
|
15352
15547
|
backgroundTextureMaterial.isGCIgnored = true;
|
|
15353
15548
|
backgroundTextureMaterial.renderState.depthState.compareFunction = exports.CompareFunction.LessEqual;
|
|
15354
15549
|
_this._backgroundTextureMaterial = backgroundTextureMaterial;
|
|
@@ -15519,7 +15714,7 @@ ShaderPool.init();
|
|
|
15519
15714
|
material.isGCIgnored = true;
|
|
15520
15715
|
return material;
|
|
15521
15716
|
};
|
|
15522
|
-
|
|
15717
|
+
_create_class$2(Engine, [
|
|
15523
15718
|
{
|
|
15524
15719
|
key: "settings",
|
|
15525
15720
|
get: /**
|
|
@@ -15607,9 +15802,15 @@ ShaderPool.init();
|
|
|
15607
15802
|
]);
|
|
15608
15803
|
return Engine;
|
|
15609
15804
|
}(EventDispatcher);
|
|
15610
|
-
|
|
15611
|
-
/** @internal */ Engine.
|
|
15612
|
-
|
|
15805
|
+
(function() {
|
|
15806
|
+
/** @internal */ Engine._gammaMacro = Shader.getMacroByName("OASIS_COLORSPACE_GAMMA");
|
|
15807
|
+
})();
|
|
15808
|
+
(function() {
|
|
15809
|
+
/** @internal */ Engine._noDepthTextureMacro = Shader.getMacroByName("OASIS_NO_DEPTH_TEXTURE");
|
|
15810
|
+
})();
|
|
15811
|
+
(function() {
|
|
15812
|
+
/** @internal Conversion of space units to pixel units for 2D. */ Engine._pixelsPerUnit = 100;
|
|
15813
|
+
})();
|
|
15613
15814
|
/**
|
|
15614
15815
|
* Script class, used for logic writing.
|
|
15615
15816
|
*/ var Script = /*#__PURE__*/ function(Component) {
|
|
@@ -15922,7 +16123,9 @@ __decorate$1([
|
|
|
15922
16123
|
};
|
|
15923
16124
|
return SpriteBatcher;
|
|
15924
16125
|
}(Basic2DBatcher);
|
|
15925
|
-
|
|
16126
|
+
(function() {
|
|
16127
|
+
SpriteBatcher._textureProperty = Shader.getPropertyByName("u_spriteTexture");
|
|
16128
|
+
})();
|
|
15926
16129
|
/**
|
|
15927
16130
|
* Render queue.
|
|
15928
16131
|
*/ var RenderQueue = /*#__PURE__*/ function() {
|
|
@@ -16416,227 +16619,247 @@ var /**
|
|
|
16416
16619
|
};
|
|
16417
16620
|
return ShadowUtils;
|
|
16418
16621
|
}();
|
|
16419
|
-
|
|
16420
|
-
|
|
16421
|
-
|
|
16422
|
-
|
|
16423
|
-
|
|
16424
|
-
new miniprogram$7.
|
|
16425
|
-
|
|
16426
|
-
|
|
16427
|
-
|
|
16428
|
-
|
|
16429
|
-
|
|
16430
|
-
|
|
16431
|
-
|
|
16432
|
-
|
|
16433
|
-
|
|
16434
|
-
|
|
16435
|
-
|
|
16436
|
-
|
|
16437
|
-
|
|
16438
|
-
|
|
16439
|
-
|
|
16440
|
-
|
|
16441
|
-
|
|
16442
|
-
|
|
16443
|
-
|
|
16444
|
-
|
|
16445
|
-
|
|
16446
|
-
|
|
16447
|
-
|
|
16448
|
-
|
|
16449
|
-
|
|
16450
|
-
|
|
16451
|
-
|
|
16452
|
-
miniprogram$7.FrustumFace.Top,
|
|
16453
|
-
miniprogram$7.FrustumFace.Bottom
|
|
16454
|
-
],
|
|
16455
|
-
[
|
|
16456
|
-
miniprogram$7.FrustumFace.Near,
|
|
16457
|
-
miniprogram$7.FrustumFace.Far,
|
|
16458
|
-
miniprogram$7.FrustumFace.Top,
|
|
16459
|
-
miniprogram$7.FrustumFace.Bottom
|
|
16460
|
-
],
|
|
16461
|
-
[
|
|
16462
|
-
miniprogram$7.FrustumFace.Near,
|
|
16463
|
-
miniprogram$7.FrustumFace.Far,
|
|
16464
|
-
miniprogram$7.FrustumFace.Left,
|
|
16465
|
-
miniprogram$7.FrustumFace.Right
|
|
16466
|
-
],
|
|
16467
|
-
[
|
|
16468
|
-
miniprogram$7.FrustumFace.Near,
|
|
16469
|
-
miniprogram$7.FrustumFace.Far,
|
|
16470
|
-
miniprogram$7.FrustumFace.Left,
|
|
16471
|
-
miniprogram$7.FrustumFace.Right
|
|
16472
|
-
]
|
|
16473
|
-
];
|
|
16474
|
-
/** near, far, left, right, bottom, top */ ShadowUtils._frustumTwoPlaneCorners = [
|
|
16475
|
-
[
|
|
16476
|
-
// near, far, left, right, bottom, top
|
|
16477
|
-
[
|
|
16478
|
-
8,
|
|
16479
|
-
8
|
|
16480
|
-
],
|
|
16481
|
-
[
|
|
16482
|
-
8,
|
|
16483
|
-
8
|
|
16484
|
-
],
|
|
16485
|
-
[
|
|
16486
|
-
4,
|
|
16487
|
-
5
|
|
16488
|
-
],
|
|
16489
|
-
[
|
|
16490
|
-
6,
|
|
16491
|
-
7
|
|
16492
|
-
],
|
|
16493
|
-
[
|
|
16494
|
-
7,
|
|
16495
|
-
4
|
|
16496
|
-
],
|
|
16497
|
-
[
|
|
16498
|
-
5,
|
|
16499
|
-
6
|
|
16500
|
-
]
|
|
16501
|
-
],
|
|
16502
|
-
[
|
|
16503
|
-
// near, far, left, right, bottom, top
|
|
16504
|
-
[
|
|
16505
|
-
8,
|
|
16506
|
-
8
|
|
16507
|
-
],
|
|
16508
|
-
[
|
|
16509
|
-
8,
|
|
16510
|
-
8
|
|
16511
|
-
],
|
|
16512
|
-
[
|
|
16513
|
-
1,
|
|
16514
|
-
0
|
|
16515
|
-
],
|
|
16516
|
-
[
|
|
16517
|
-
3,
|
|
16518
|
-
2
|
|
16519
|
-
],
|
|
16520
|
-
[
|
|
16521
|
-
0,
|
|
16522
|
-
3
|
|
16523
|
-
],
|
|
16524
|
-
[
|
|
16525
|
-
2,
|
|
16526
|
-
1
|
|
16527
|
-
]
|
|
16528
|
-
],
|
|
16529
|
-
[
|
|
16530
|
-
// near, far, left, right, bottom, top
|
|
16531
|
-
[
|
|
16532
|
-
5,
|
|
16533
|
-
4
|
|
16534
|
-
],
|
|
16535
|
-
[
|
|
16536
|
-
0,
|
|
16537
|
-
1
|
|
16538
|
-
],
|
|
16539
|
-
[
|
|
16540
|
-
8,
|
|
16541
|
-
8
|
|
16542
|
-
],
|
|
16543
|
-
[
|
|
16544
|
-
8,
|
|
16545
|
-
8
|
|
16546
|
-
],
|
|
16547
|
-
[
|
|
16548
|
-
4,
|
|
16549
|
-
0
|
|
16550
|
-
],
|
|
16551
|
-
[
|
|
16552
|
-
1,
|
|
16553
|
-
5
|
|
16554
|
-
]
|
|
16555
|
-
],
|
|
16556
|
-
[
|
|
16557
|
-
// near, far, left, right, bottom, top
|
|
16558
|
-
[
|
|
16559
|
-
7,
|
|
16560
|
-
6
|
|
16561
|
-
],
|
|
16562
|
-
[
|
|
16563
|
-
2,
|
|
16564
|
-
3
|
|
16565
|
-
],
|
|
16566
|
-
[
|
|
16567
|
-
8,
|
|
16568
|
-
8
|
|
16569
|
-
],
|
|
16570
|
-
[
|
|
16571
|
-
8,
|
|
16572
|
-
8
|
|
16573
|
-
],
|
|
16574
|
-
[
|
|
16575
|
-
3,
|
|
16576
|
-
7
|
|
16577
|
-
],
|
|
16578
|
-
[
|
|
16579
|
-
6,
|
|
16580
|
-
2
|
|
16581
|
-
]
|
|
16582
|
-
],
|
|
16583
|
-
[
|
|
16584
|
-
// near, far, left, right, bottom, top
|
|
16622
|
+
(function() {
|
|
16623
|
+
ShadowUtils._tempMatrix0 = new miniprogram$7.Matrix();
|
|
16624
|
+
})();
|
|
16625
|
+
(function() {
|
|
16626
|
+
// prettier-ignore
|
|
16627
|
+
/** @internal */ ShadowUtils._shadowMapCoordMatrix = new miniprogram$7.Matrix(0.5, 0.0, 0.0, 0.0, 0.0, 0.5, 0.0, 0.0, 0.0, 0.0, 0.5, 0.0, 0.5, 0.5, 0.5, 1.0);
|
|
16628
|
+
})();
|
|
16629
|
+
(function() {
|
|
16630
|
+
ShadowUtils._frustumCorners = [
|
|
16631
|
+
new miniprogram$7.Vector3(),
|
|
16632
|
+
new miniprogram$7.Vector3(),
|
|
16633
|
+
new miniprogram$7.Vector3(),
|
|
16634
|
+
new miniprogram$7.Vector3(),
|
|
16635
|
+
new miniprogram$7.Vector3(),
|
|
16636
|
+
new miniprogram$7.Vector3(),
|
|
16637
|
+
new miniprogram$7.Vector3(),
|
|
16638
|
+
new miniprogram$7.Vector3()
|
|
16639
|
+
];
|
|
16640
|
+
})();
|
|
16641
|
+
(function() {
|
|
16642
|
+
ShadowUtils._adjustNearPlane = new miniprogram$7.Plane(new miniprogram$7.Vector3());
|
|
16643
|
+
})();
|
|
16644
|
+
(function() {
|
|
16645
|
+
ShadowUtils._adjustFarPlane = new miniprogram$7.Plane(new miniprogram$7.Vector3());
|
|
16646
|
+
})();
|
|
16647
|
+
(function() {
|
|
16648
|
+
ShadowUtils._backPlaneFaces = new Array(5);
|
|
16649
|
+
})();
|
|
16650
|
+
(function() {
|
|
16651
|
+
ShadowUtils._edgePlanePoint2 = new miniprogram$7.Vector3();
|
|
16652
|
+
})();
|
|
16653
|
+
(function() {
|
|
16654
|
+
/** near, far, left, right, bottom, top */ ShadowUtils._frustumPlaneNeighbors = [
|
|
16585
16655
|
[
|
|
16586
|
-
|
|
16587
|
-
7
|
|
16656
|
+
miniprogram$7.FrustumFace.Left,
|
|
16657
|
+
miniprogram$7.FrustumFace.Right,
|
|
16658
|
+
miniprogram$7.FrustumFace.Top,
|
|
16659
|
+
miniprogram$7.FrustumFace.Bottom
|
|
16588
16660
|
],
|
|
16589
16661
|
[
|
|
16590
|
-
|
|
16591
|
-
|
|
16662
|
+
miniprogram$7.FrustumFace.Left,
|
|
16663
|
+
miniprogram$7.FrustumFace.Right,
|
|
16664
|
+
miniprogram$7.FrustumFace.Top,
|
|
16665
|
+
miniprogram$7.FrustumFace.Bottom
|
|
16592
16666
|
],
|
|
16593
16667
|
[
|
|
16594
|
-
|
|
16595
|
-
|
|
16668
|
+
miniprogram$7.FrustumFace.Near,
|
|
16669
|
+
miniprogram$7.FrustumFace.Far,
|
|
16670
|
+
miniprogram$7.FrustumFace.Top,
|
|
16671
|
+
miniprogram$7.FrustumFace.Bottom
|
|
16596
16672
|
],
|
|
16597
16673
|
[
|
|
16598
|
-
7,
|
|
16599
|
-
|
|
16674
|
+
miniprogram$7.FrustumFace.Near,
|
|
16675
|
+
miniprogram$7.FrustumFace.Far,
|
|
16676
|
+
miniprogram$7.FrustumFace.Top,
|
|
16677
|
+
miniprogram$7.FrustumFace.Bottom
|
|
16600
16678
|
],
|
|
16601
16679
|
[
|
|
16602
|
-
|
|
16603
|
-
|
|
16680
|
+
miniprogram$7.FrustumFace.Near,
|
|
16681
|
+
miniprogram$7.FrustumFace.Far,
|
|
16682
|
+
miniprogram$7.FrustumFace.Left,
|
|
16683
|
+
miniprogram$7.FrustumFace.Right
|
|
16604
16684
|
],
|
|
16605
16685
|
[
|
|
16606
|
-
|
|
16607
|
-
|
|
16686
|
+
miniprogram$7.FrustumFace.Near,
|
|
16687
|
+
miniprogram$7.FrustumFace.Far,
|
|
16688
|
+
miniprogram$7.FrustumFace.Left,
|
|
16689
|
+
miniprogram$7.FrustumFace.Right
|
|
16608
16690
|
]
|
|
16609
|
-
]
|
|
16610
|
-
|
|
16611
|
-
|
|
16691
|
+
];
|
|
16692
|
+
})();
|
|
16693
|
+
(function() {
|
|
16694
|
+
/** near, far, left, right, bottom, top */ ShadowUtils._frustumTwoPlaneCorners = [
|
|
16612
16695
|
[
|
|
16613
|
-
|
|
16614
|
-
|
|
16696
|
+
// near, far, left, right, bottom, top
|
|
16697
|
+
[
|
|
16698
|
+
8,
|
|
16699
|
+
8
|
|
16700
|
+
],
|
|
16701
|
+
[
|
|
16702
|
+
8,
|
|
16703
|
+
8
|
|
16704
|
+
],
|
|
16705
|
+
[
|
|
16706
|
+
4,
|
|
16707
|
+
5
|
|
16708
|
+
],
|
|
16709
|
+
[
|
|
16710
|
+
6,
|
|
16711
|
+
7
|
|
16712
|
+
],
|
|
16713
|
+
[
|
|
16714
|
+
7,
|
|
16715
|
+
4
|
|
16716
|
+
],
|
|
16717
|
+
[
|
|
16718
|
+
5,
|
|
16719
|
+
6
|
|
16720
|
+
]
|
|
16615
16721
|
],
|
|
16616
16722
|
[
|
|
16617
|
-
|
|
16618
|
-
|
|
16723
|
+
// near, far, left, right, bottom, top
|
|
16724
|
+
[
|
|
16725
|
+
8,
|
|
16726
|
+
8
|
|
16727
|
+
],
|
|
16728
|
+
[
|
|
16729
|
+
8,
|
|
16730
|
+
8
|
|
16731
|
+
],
|
|
16732
|
+
[
|
|
16733
|
+
1,
|
|
16734
|
+
0
|
|
16735
|
+
],
|
|
16736
|
+
[
|
|
16737
|
+
3,
|
|
16738
|
+
2
|
|
16739
|
+
],
|
|
16740
|
+
[
|
|
16741
|
+
0,
|
|
16742
|
+
3
|
|
16743
|
+
],
|
|
16744
|
+
[
|
|
16745
|
+
2,
|
|
16746
|
+
1
|
|
16747
|
+
]
|
|
16619
16748
|
],
|
|
16620
16749
|
[
|
|
16621
|
-
|
|
16622
|
-
|
|
16750
|
+
// near, far, left, right, bottom, top
|
|
16751
|
+
[
|
|
16752
|
+
5,
|
|
16753
|
+
4
|
|
16754
|
+
],
|
|
16755
|
+
[
|
|
16756
|
+
0,
|
|
16757
|
+
1
|
|
16758
|
+
],
|
|
16759
|
+
[
|
|
16760
|
+
8,
|
|
16761
|
+
8
|
|
16762
|
+
],
|
|
16763
|
+
[
|
|
16764
|
+
8,
|
|
16765
|
+
8
|
|
16766
|
+
],
|
|
16767
|
+
[
|
|
16768
|
+
4,
|
|
16769
|
+
0
|
|
16770
|
+
],
|
|
16771
|
+
[
|
|
16772
|
+
1,
|
|
16773
|
+
5
|
|
16774
|
+
]
|
|
16623
16775
|
],
|
|
16624
16776
|
[
|
|
16625
|
-
|
|
16626
|
-
|
|
16777
|
+
// near, far, left, right, bottom, top
|
|
16778
|
+
[
|
|
16779
|
+
7,
|
|
16780
|
+
6
|
|
16781
|
+
],
|
|
16782
|
+
[
|
|
16783
|
+
2,
|
|
16784
|
+
3
|
|
16785
|
+
],
|
|
16786
|
+
[
|
|
16787
|
+
8,
|
|
16788
|
+
8
|
|
16789
|
+
],
|
|
16790
|
+
[
|
|
16791
|
+
8,
|
|
16792
|
+
8
|
|
16793
|
+
],
|
|
16794
|
+
[
|
|
16795
|
+
3,
|
|
16796
|
+
7
|
|
16797
|
+
],
|
|
16798
|
+
[
|
|
16799
|
+
6,
|
|
16800
|
+
2
|
|
16801
|
+
]
|
|
16627
16802
|
],
|
|
16628
16803
|
[
|
|
16629
|
-
|
|
16630
|
-
|
|
16804
|
+
// near, far, left, right, bottom, top
|
|
16805
|
+
[
|
|
16806
|
+
4,
|
|
16807
|
+
7
|
|
16808
|
+
],
|
|
16809
|
+
[
|
|
16810
|
+
3,
|
|
16811
|
+
0
|
|
16812
|
+
],
|
|
16813
|
+
[
|
|
16814
|
+
0,
|
|
16815
|
+
4
|
|
16816
|
+
],
|
|
16817
|
+
[
|
|
16818
|
+
7,
|
|
16819
|
+
3
|
|
16820
|
+
],
|
|
16821
|
+
[
|
|
16822
|
+
8,
|
|
16823
|
+
8
|
|
16824
|
+
],
|
|
16825
|
+
[
|
|
16826
|
+
8,
|
|
16827
|
+
8
|
|
16828
|
+
]
|
|
16631
16829
|
],
|
|
16632
16830
|
[
|
|
16633
|
-
|
|
16634
|
-
|
|
16831
|
+
// near, far, left, right, bottom, top
|
|
16832
|
+
[
|
|
16833
|
+
6,
|
|
16834
|
+
5
|
|
16835
|
+
],
|
|
16836
|
+
[
|
|
16837
|
+
1,
|
|
16838
|
+
2
|
|
16839
|
+
],
|
|
16840
|
+
[
|
|
16841
|
+
5,
|
|
16842
|
+
1
|
|
16843
|
+
],
|
|
16844
|
+
[
|
|
16845
|
+
2,
|
|
16846
|
+
6
|
|
16847
|
+
],
|
|
16848
|
+
[
|
|
16849
|
+
8,
|
|
16850
|
+
8
|
|
16851
|
+
],
|
|
16852
|
+
[
|
|
16853
|
+
8,
|
|
16854
|
+
8
|
|
16855
|
+
]
|
|
16635
16856
|
]
|
|
16636
|
-
]
|
|
16637
|
-
|
|
16638
|
-
|
|
16639
|
-
|
|
16857
|
+
];
|
|
16858
|
+
})();
|
|
16859
|
+
(function() {
|
|
16860
|
+
//now max shadow sample tent is 5x5, atlas borderSize at least 3=ceil(2.5),and +1 pixel is for global border for no cascade mode.
|
|
16861
|
+
ShadowUtils.atlasBorderSize = 4.0;
|
|
16862
|
+
})();
|
|
16640
16863
|
/**
|
|
16641
16864
|
* Cascade shadow caster.
|
|
16642
16865
|
*/ var CascadedShadowCasterPass = /*#__PURE__*/ function() {
|
|
@@ -16872,18 +17095,42 @@ ShadowUtils.atlasBorderSize = 4.0;
|
|
|
16872
17095
|
};
|
|
16873
17096
|
return CascadedShadowCasterPass;
|
|
16874
17097
|
}();
|
|
16875
|
-
|
|
16876
|
-
CascadedShadowCasterPass.
|
|
16877
|
-
|
|
16878
|
-
|
|
16879
|
-
CascadedShadowCasterPass.
|
|
16880
|
-
|
|
16881
|
-
|
|
16882
|
-
CascadedShadowCasterPass.
|
|
16883
|
-
|
|
16884
|
-
|
|
16885
|
-
CascadedShadowCasterPass.
|
|
16886
|
-
|
|
17098
|
+
(function() {
|
|
17099
|
+
CascadedShadowCasterPass._lightShadowBiasProperty = Shader.getPropertyByName("u_shadowBias");
|
|
17100
|
+
})();
|
|
17101
|
+
(function() {
|
|
17102
|
+
CascadedShadowCasterPass._lightDirectionProperty = Shader.getPropertyByName("u_lightDirection");
|
|
17103
|
+
})();
|
|
17104
|
+
(function() {
|
|
17105
|
+
CascadedShadowCasterPass._shadowMatricesProperty = Shader.getPropertyByName("u_shadowMatrices");
|
|
17106
|
+
})();
|
|
17107
|
+
(function() {
|
|
17108
|
+
CascadedShadowCasterPass._shadowMapSize = Shader.getPropertyByName("u_shadowMapSize");
|
|
17109
|
+
})();
|
|
17110
|
+
(function() {
|
|
17111
|
+
CascadedShadowCasterPass._shadowInfosProperty = Shader.getPropertyByName("u_shadowInfo");
|
|
17112
|
+
})();
|
|
17113
|
+
(function() {
|
|
17114
|
+
CascadedShadowCasterPass._shadowMapsProperty = Shader.getPropertyByName("u_shadowMap");
|
|
17115
|
+
})();
|
|
17116
|
+
(function() {
|
|
17117
|
+
CascadedShadowCasterPass._shadowSplitSpheresProperty = Shader.getPropertyByName("u_shadowSplitSpheres");
|
|
17118
|
+
})();
|
|
17119
|
+
(function() {
|
|
17120
|
+
CascadedShadowCasterPass._maxCascades = 4;
|
|
17121
|
+
})();
|
|
17122
|
+
(function() {
|
|
17123
|
+
CascadedShadowCasterPass._cascadesSplitDistance = new Array(CascadedShadowCasterPass._maxCascades + 1);
|
|
17124
|
+
})();
|
|
17125
|
+
(function() {
|
|
17126
|
+
CascadedShadowCasterPass._clearColor = new miniprogram$7.Color(1, 1, 1, 1);
|
|
17127
|
+
})();
|
|
17128
|
+
(function() {
|
|
17129
|
+
CascadedShadowCasterPass._tempVector = new miniprogram$7.Vector3();
|
|
17130
|
+
})();
|
|
17131
|
+
(function() {
|
|
17132
|
+
CascadedShadowCasterPass._tempMatrix0 = new miniprogram$7.Matrix();
|
|
17133
|
+
})();
|
|
16887
17134
|
var passNum = 0;
|
|
16888
17135
|
/**
|
|
16889
17136
|
* RenderPass.
|
|
@@ -17114,7 +17361,7 @@ var passNum = 0;
|
|
|
17114
17361
|
renderer._prepareRender(context);
|
|
17115
17362
|
}
|
|
17116
17363
|
};
|
|
17117
|
-
|
|
17364
|
+
_create_class$2(BasicRenderPipeline, [
|
|
17118
17365
|
{
|
|
17119
17366
|
key: "defaultRenderPass",
|
|
17120
17367
|
get: /**
|
|
@@ -17126,13 +17373,23 @@ var passNum = 0;
|
|
|
17126
17373
|
]);
|
|
17127
17374
|
return BasicRenderPipeline;
|
|
17128
17375
|
}();
|
|
17129
|
-
|
|
17130
|
-
BasicRenderPipeline.
|
|
17376
|
+
(function() {
|
|
17377
|
+
BasicRenderPipeline._tempVector0 = new miniprogram$7.Vector3();
|
|
17378
|
+
})();
|
|
17379
|
+
(function() {
|
|
17380
|
+
BasicRenderPipeline._tempVector1 = new miniprogram$7.Vector3();
|
|
17381
|
+
})();
|
|
17131
17382
|
var _Camera;
|
|
17132
17383
|
var MathTemp = function MathTemp() {};
|
|
17133
|
-
|
|
17134
|
-
MathTemp.
|
|
17135
|
-
|
|
17384
|
+
(function() {
|
|
17385
|
+
MathTemp.tempVec4 = new miniprogram$7.Vector4();
|
|
17386
|
+
})();
|
|
17387
|
+
(function() {
|
|
17388
|
+
MathTemp.tempVec3 = new miniprogram$7.Vector3();
|
|
17389
|
+
})();
|
|
17390
|
+
(function() {
|
|
17391
|
+
MathTemp.tempVec2 = new miniprogram$7.Vector2();
|
|
17392
|
+
})();
|
|
17136
17393
|
exports.Camera = (_Camera = /*#__PURE__*/ function(Component) {
|
|
17137
17394
|
var Camera1 = function Camera1(entity) {
|
|
17138
17395
|
var _this;
|
|
@@ -17149,6 +17406,8 @@ exports.Camera = (_Camera = /*#__PURE__*/ function(Component) {
|
|
|
17149
17406
|
* @remarks Support bit manipulation, corresponding to `Layer`.
|
|
17150
17407
|
*/ _this.cullingMask = exports.Layer.Everything;
|
|
17151
17408
|
/** @internal */ _this._globalShaderMacro = new ShaderMacroCollection();
|
|
17409
|
+
/** @internal */ _this._frustum = new miniprogram$7.BoundingFrustum();
|
|
17410
|
+
/** @internal */ _this._virtualCamera = new VirtualCamera();
|
|
17152
17411
|
_this._isProjMatSetting = false;
|
|
17153
17412
|
_this._nearClipPlane = 0.1;
|
|
17154
17413
|
_this._farClipPlane = 100;
|
|
@@ -17159,8 +17418,6 @@ exports.Camera = (_Camera = /*#__PURE__*/ function(Component) {
|
|
|
17159
17418
|
_this._isFrustumProjectDirty = true;
|
|
17160
17419
|
_this._customAspectRatio = undefined;
|
|
17161
17420
|
_this._renderTarget = null;
|
|
17162
|
-
/** @internal */ _this._frustum = new miniprogram$7.BoundingFrustum();
|
|
17163
|
-
/** @internal */ _this._virtualCamera = new VirtualCamera();
|
|
17164
17421
|
_this._viewport = new miniprogram$7.Vector4(0, 0, 1, 1);
|
|
17165
17422
|
_this._inverseProjectionMatrix = new miniprogram$7.Matrix();
|
|
17166
17423
|
_this._lastAspectSize = new miniprogram$7.Vector2(0, 0);
|
|
@@ -17170,7 +17427,7 @@ exports.Camera = (_Camera = /*#__PURE__*/ function(Component) {
|
|
|
17170
17427
|
_this._isViewMatrixDirty = transform.registerWorldChangeFlag();
|
|
17171
17428
|
_this._isInvViewProjDirty = transform.registerWorldChangeFlag();
|
|
17172
17429
|
_this._frustumViewChangeFlag = transform.registerWorldChangeFlag();
|
|
17173
|
-
_this._renderPipeline = new BasicRenderPipeline(
|
|
17430
|
+
_this._renderPipeline = new BasicRenderPipeline(_assert_this_initialized(_this));
|
|
17174
17431
|
_this.shaderData._addRefCount(1);
|
|
17175
17432
|
return _this;
|
|
17176
17433
|
};
|
|
@@ -17388,7 +17645,7 @@ exports.Camera = (_Camera = /*#__PURE__*/ function(Component) {
|
|
|
17388
17645
|
}
|
|
17389
17646
|
return this._inverseProjectionMatrix;
|
|
17390
17647
|
};
|
|
17391
|
-
|
|
17648
|
+
_create_class$2(Camera1, [
|
|
17392
17649
|
{
|
|
17393
17650
|
key: "nearClipPlane",
|
|
17394
17651
|
get: /**
|
|
@@ -17552,7 +17809,11 @@ exports.Camera = (_Camera = /*#__PURE__*/ function(Component) {
|
|
|
17552
17809
|
}
|
|
17553
17810
|
]);
|
|
17554
17811
|
return Camera1;
|
|
17555
|
-
}(Component),
|
|
17812
|
+
}(Component), function() {
|
|
17813
|
+
/** @internal */ _Camera._inverseViewMatrixProperty = Shader.getPropertyByName("u_viewInvMat");
|
|
17814
|
+
}(), function() {
|
|
17815
|
+
/** @internal */ _Camera._cameraPositionProperty = Shader.getPropertyByName("u_cameraPos");
|
|
17816
|
+
}(), _Camera);
|
|
17556
17817
|
__decorate$1([
|
|
17557
17818
|
deepClone
|
|
17558
17819
|
], exports.Camera.prototype, "_frustum", void 0);
|
|
@@ -17761,7 +18022,9 @@ var MultiExecutor = /*#__PURE__*/ function() {
|
|
|
17761
18022
|
};
|
|
17762
18023
|
return Loader;
|
|
17763
18024
|
}();
|
|
17764
|
-
|
|
18025
|
+
(function() {
|
|
18026
|
+
Loader._engineObjects = {};
|
|
18027
|
+
})();
|
|
17765
18028
|
/**
|
|
17766
18029
|
* Asset Type.
|
|
17767
18030
|
*/ exports.AssetType = void 0;
|
|
@@ -17910,7 +18173,7 @@ var BaseMaterial = /*#__PURE__*/ function(Material) {
|
|
|
17910
18173
|
target._isTransparent = this._isTransparent;
|
|
17911
18174
|
target._blendMode = this._blendMode;
|
|
17912
18175
|
};
|
|
17913
|
-
|
|
18176
|
+
_create_class$2(BaseMaterial, [
|
|
17914
18177
|
{
|
|
17915
18178
|
key: "shader",
|
|
17916
18179
|
get: /**
|
|
@@ -18010,19 +18273,45 @@ var BaseMaterial = /*#__PURE__*/ function(Material) {
|
|
|
18010
18273
|
]);
|
|
18011
18274
|
return BaseMaterial;
|
|
18012
18275
|
}(Material);
|
|
18013
|
-
|
|
18014
|
-
BaseMaterial.
|
|
18015
|
-
|
|
18016
|
-
|
|
18017
|
-
BaseMaterial.
|
|
18018
|
-
|
|
18019
|
-
|
|
18020
|
-
BaseMaterial.
|
|
18021
|
-
|
|
18022
|
-
|
|
18023
|
-
BaseMaterial.
|
|
18024
|
-
|
|
18025
|
-
|
|
18276
|
+
(function() {
|
|
18277
|
+
BaseMaterial._baseColorProp = Shader.getPropertyByName("u_baseColor");
|
|
18278
|
+
})();
|
|
18279
|
+
(function() {
|
|
18280
|
+
BaseMaterial._baseTextureProp = Shader.getPropertyByName("u_baseTexture");
|
|
18281
|
+
})();
|
|
18282
|
+
(function() {
|
|
18283
|
+
BaseMaterial._baseTextureMacro = Shader.getMacroByName("BASETEXTURE");
|
|
18284
|
+
})();
|
|
18285
|
+
(function() {
|
|
18286
|
+
BaseMaterial._tilingOffsetProp = Shader.getPropertyByName("u_tilingOffset");
|
|
18287
|
+
})();
|
|
18288
|
+
(function() {
|
|
18289
|
+
BaseMaterial._normalTextureProp = Shader.getPropertyByName("u_normalTexture");
|
|
18290
|
+
})();
|
|
18291
|
+
(function() {
|
|
18292
|
+
BaseMaterial._normalIntensityProp = Shader.getPropertyByName("u_normalIntensity");
|
|
18293
|
+
})();
|
|
18294
|
+
(function() {
|
|
18295
|
+
BaseMaterial._normalTextureMacro = Shader.getMacroByName("NORMALTEXTURE");
|
|
18296
|
+
})();
|
|
18297
|
+
(function() {
|
|
18298
|
+
BaseMaterial._emissiveColorProp = Shader.getPropertyByName("u_emissiveColor");
|
|
18299
|
+
})();
|
|
18300
|
+
(function() {
|
|
18301
|
+
BaseMaterial._emissiveTextureProp = Shader.getPropertyByName("u_emissiveTexture");
|
|
18302
|
+
})();
|
|
18303
|
+
(function() {
|
|
18304
|
+
BaseMaterial._emissiveTextureMacro = Shader.getMacroByName("EMISSIVETEXTURE");
|
|
18305
|
+
})();
|
|
18306
|
+
(function() {
|
|
18307
|
+
BaseMaterial._transparentMacro = Shader.getMacroByName("OASIS_TRANSPARENT");
|
|
18308
|
+
})();
|
|
18309
|
+
(function() {
|
|
18310
|
+
BaseMaterial._alphaCutoffProp = Shader.getPropertyByName("u_alphaCutoff");
|
|
18311
|
+
})();
|
|
18312
|
+
(function() {
|
|
18313
|
+
BaseMaterial._alphaCutoffMacro = Shader.getMacroByName("ALPHA_CUTOFF");
|
|
18314
|
+
})();
|
|
18026
18315
|
/**
|
|
18027
18316
|
* Blinn-phong Material.
|
|
18028
18317
|
*/ var BlinnPhongMaterial = /*#__PURE__*/ function(BaseMaterial) {
|
|
@@ -18049,7 +18338,7 @@ BaseMaterial._alphaCutoffMacro = Shader.getMacroByName("ALPHA_CUTOFF");
|
|
|
18049
18338
|
this.cloneTo(dest);
|
|
18050
18339
|
return dest;
|
|
18051
18340
|
};
|
|
18052
|
-
|
|
18341
|
+
_create_class$2(BlinnPhongMaterial, [
|
|
18053
18342
|
{
|
|
18054
18343
|
key: "baseColor",
|
|
18055
18344
|
get: /**
|
|
@@ -18195,9 +18484,15 @@ BaseMaterial._alphaCutoffMacro = Shader.getMacroByName("ALPHA_CUTOFF");
|
|
|
18195
18484
|
]);
|
|
18196
18485
|
return BlinnPhongMaterial;
|
|
18197
18486
|
}(BaseMaterial);
|
|
18198
|
-
|
|
18199
|
-
BlinnPhongMaterial.
|
|
18200
|
-
|
|
18487
|
+
(function() {
|
|
18488
|
+
BlinnPhongMaterial._specularColorProp = Shader.getPropertyByName("u_specularColor");
|
|
18489
|
+
})();
|
|
18490
|
+
(function() {
|
|
18491
|
+
BlinnPhongMaterial._shininessProp = Shader.getPropertyByName("u_shininess");
|
|
18492
|
+
})();
|
|
18493
|
+
(function() {
|
|
18494
|
+
BlinnPhongMaterial._specularTextureProp = Shader.getPropertyByName("u_specularTexture");
|
|
18495
|
+
})();
|
|
18201
18496
|
/**
|
|
18202
18497
|
* Texture UV coordinate.
|
|
18203
18498
|
*/ exports.TextureCoordinate = void 0;
|
|
@@ -18231,7 +18526,7 @@ BlinnPhongMaterial._specularTextureProp = Shader.getPropertyByName("u_specularTe
|
|
|
18231
18526
|
shaderData.setFloat(PBRBaseMaterial._clearCoatRoughnessProp, 0);
|
|
18232
18527
|
return _this;
|
|
18233
18528
|
}
|
|
18234
|
-
|
|
18529
|
+
_create_class$2(PBRBaseMaterial, [
|
|
18235
18530
|
{
|
|
18236
18531
|
key: "baseColor",
|
|
18237
18532
|
get: /**
|
|
@@ -18455,14 +18750,30 @@ BlinnPhongMaterial._specularTextureProp = Shader.getPropertyByName("u_specularTe
|
|
|
18455
18750
|
]);
|
|
18456
18751
|
return PBRBaseMaterial;
|
|
18457
18752
|
}(BaseMaterial);
|
|
18458
|
-
|
|
18459
|
-
PBRBaseMaterial.
|
|
18460
|
-
|
|
18461
|
-
|
|
18462
|
-
PBRBaseMaterial.
|
|
18463
|
-
|
|
18464
|
-
|
|
18465
|
-
PBRBaseMaterial.
|
|
18753
|
+
(function() {
|
|
18754
|
+
PBRBaseMaterial._occlusionTextureIntensityProp = Shader.getPropertyByName("u_occlusionIntensity");
|
|
18755
|
+
})();
|
|
18756
|
+
(function() {
|
|
18757
|
+
PBRBaseMaterial._occlusionTextureCoordProp = Shader.getPropertyByName("u_occlusionTextureCoord");
|
|
18758
|
+
})();
|
|
18759
|
+
(function() {
|
|
18760
|
+
PBRBaseMaterial._occlusionTextureProp = Shader.getPropertyByName("u_occlusionTexture");
|
|
18761
|
+
})();
|
|
18762
|
+
(function() {
|
|
18763
|
+
PBRBaseMaterial._clearCoatProp = Shader.getPropertyByName("u_clearCoat");
|
|
18764
|
+
})();
|
|
18765
|
+
(function() {
|
|
18766
|
+
PBRBaseMaterial._clearCoatTextureProp = Shader.getPropertyByName("u_clearCoatTexture");
|
|
18767
|
+
})();
|
|
18768
|
+
(function() {
|
|
18769
|
+
PBRBaseMaterial._clearCoatRoughnessProp = Shader.getPropertyByName("u_clearCoatRoughness");
|
|
18770
|
+
})();
|
|
18771
|
+
(function() {
|
|
18772
|
+
PBRBaseMaterial._clearCoatRoughnessTextureProp = Shader.getPropertyByName("u_clearCoatRoughnessTexture");
|
|
18773
|
+
})();
|
|
18774
|
+
(function() {
|
|
18775
|
+
PBRBaseMaterial._clearCoatNormalTextureProp = Shader.getPropertyByName("u_clearCoatNormalTexture");
|
|
18776
|
+
})();
|
|
18466
18777
|
/**
|
|
18467
18778
|
* PBR (Metallic-Roughness Workflow) Material.
|
|
18468
18779
|
*/ var PBRMaterial = /*#__PURE__*/ function(PBRBaseMaterial) {
|
|
@@ -18482,7 +18793,7 @@ PBRBaseMaterial._clearCoatNormalTextureProp = Shader.getPropertyByName("u_clearC
|
|
|
18482
18793
|
this.cloneTo(dest);
|
|
18483
18794
|
return dest;
|
|
18484
18795
|
};
|
|
18485
|
-
|
|
18796
|
+
_create_class$2(PBRMaterial, [
|
|
18486
18797
|
{
|
|
18487
18798
|
key: "metallic",
|
|
18488
18799
|
get: /**
|
|
@@ -18525,9 +18836,15 @@ PBRBaseMaterial._clearCoatNormalTextureProp = Shader.getPropertyByName("u_clearC
|
|
|
18525
18836
|
]);
|
|
18526
18837
|
return PBRMaterial;
|
|
18527
18838
|
}(PBRBaseMaterial);
|
|
18528
|
-
|
|
18529
|
-
PBRMaterial.
|
|
18530
|
-
|
|
18839
|
+
(function() {
|
|
18840
|
+
PBRMaterial._metallicProp = Shader.getPropertyByName("u_metal");
|
|
18841
|
+
})();
|
|
18842
|
+
(function() {
|
|
18843
|
+
PBRMaterial._roughnessProp = Shader.getPropertyByName("u_roughness");
|
|
18844
|
+
})();
|
|
18845
|
+
(function() {
|
|
18846
|
+
PBRMaterial._roughnessMetallicTextureProp = Shader.getPropertyByName("u_roughnessMetallicTexture");
|
|
18847
|
+
})();
|
|
18531
18848
|
/**
|
|
18532
18849
|
* PBR (Specular-Glossiness Workflow) Material.
|
|
18533
18850
|
*/ var PBRSpecularMaterial = /*#__PURE__*/ function(PBRBaseMaterial) {
|
|
@@ -18547,7 +18864,7 @@ PBRMaterial._roughnessMetallicTextureProp = Shader.getPropertyByName("u_roughnes
|
|
|
18547
18864
|
this.cloneTo(dest);
|
|
18548
18865
|
return dest;
|
|
18549
18866
|
};
|
|
18550
|
-
|
|
18867
|
+
_create_class$2(PBRSpecularMaterial, [
|
|
18551
18868
|
{
|
|
18552
18869
|
key: "specularColor",
|
|
18553
18870
|
get: /**
|
|
@@ -18593,10 +18910,18 @@ PBRMaterial._roughnessMetallicTextureProp = Shader.getPropertyByName("u_roughnes
|
|
|
18593
18910
|
]);
|
|
18594
18911
|
return PBRSpecularMaterial;
|
|
18595
18912
|
}(PBRBaseMaterial);
|
|
18596
|
-
|
|
18597
|
-
PBRSpecularMaterial.
|
|
18598
|
-
|
|
18599
|
-
|
|
18913
|
+
(function() {
|
|
18914
|
+
PBRSpecularMaterial._specularColorProp = Shader.getPropertyByName("u_PBRSpecularColor");
|
|
18915
|
+
})();
|
|
18916
|
+
(function() {
|
|
18917
|
+
PBRSpecularMaterial._glossinessProp = Shader.getPropertyByName("u_glossiness");
|
|
18918
|
+
})();
|
|
18919
|
+
(function() {
|
|
18920
|
+
PBRSpecularMaterial._specularGlossinessTextureProp = Shader.getPropertyByName("u_specularGlossinessTexture");
|
|
18921
|
+
})();
|
|
18922
|
+
(function() {
|
|
18923
|
+
PBRSpecularMaterial._specularGlossinessTextureMacro = Shader.getMacroByName("SPECULARGLOSSINESSTEXTURE");
|
|
18924
|
+
})();
|
|
18600
18925
|
/**
|
|
18601
18926
|
* Unlit Material.
|
|
18602
18927
|
*/ var UnlitMaterial = /*#__PURE__*/ function(BaseMaterial) {
|
|
@@ -18619,7 +18944,7 @@ PBRSpecularMaterial._specularGlossinessTextureMacro = Shader.getMacroByName("SPE
|
|
|
18619
18944
|
this.cloneTo(dest);
|
|
18620
18945
|
return dest;
|
|
18621
18946
|
};
|
|
18622
|
-
|
|
18947
|
+
_create_class$2(UnlitMaterial, [
|
|
18623
18948
|
{
|
|
18624
18949
|
key: "baseColor",
|
|
18625
18950
|
get: /**
|
|
@@ -18749,7 +19074,7 @@ exports.TextVerticalAlignment = void 0;
|
|
|
18749
19074
|
this._sprites = null;
|
|
18750
19075
|
this._spriteNamesToIndex = null;
|
|
18751
19076
|
};
|
|
18752
|
-
|
|
19077
|
+
_create_class$2(SpriteAtlas, [
|
|
18753
19078
|
{
|
|
18754
19079
|
key: "sprites",
|
|
18755
19080
|
get: /**
|
|
@@ -18918,7 +19243,7 @@ exports.TextVerticalAlignment = void 0;
|
|
|
18918
19243
|
}
|
|
18919
19244
|
this._updateFlagManager.dispatch(type);
|
|
18920
19245
|
};
|
|
18921
|
-
|
|
19246
|
+
_create_class$2(Sprite, [
|
|
18922
19247
|
{
|
|
18923
19248
|
key: "texture",
|
|
18924
19249
|
get: /**
|
|
@@ -19206,7 +19531,9 @@ var SlicedSpriteAssembler = (_SlicedSpriteAssembler = /*#__PURE__*/ function() {
|
|
|
19206
19531
|
};
|
|
19207
19532
|
SlicedSpriteAssembler1.updateUVs = function updateUVs(renderer) {};
|
|
19208
19533
|
return SlicedSpriteAssembler1;
|
|
19209
|
-
}(),
|
|
19534
|
+
}(), function() {
|
|
19535
|
+
_SlicedSpriteAssembler._worldMatrix = new miniprogram$7.Matrix();
|
|
19536
|
+
}(), _SlicedSpriteAssembler);
|
|
19210
19537
|
SlicedSpriteAssembler = __decorate$1([
|
|
19211
19538
|
StaticInterfaceImplement$1()
|
|
19212
19539
|
], SlicedSpriteAssembler);
|
|
@@ -19227,7 +19554,7 @@ SlicedSpriteAssembler = __decorate$1([
|
|
|
19227
19554
|
_this._renderData = new RenderData2D(4, [], [], null, _this._color);
|
|
19228
19555
|
_this.drawMode = exports.SpriteDrawMode.Simple;
|
|
19229
19556
|
_this.setMaterial(_this._engine._spriteDefaultMaterial);
|
|
19230
|
-
_this._onSpriteChange = _this._onSpriteChange.bind(
|
|
19557
|
+
_this._onSpriteChange = _this._onSpriteChange.bind(_assert_this_initialized(_this));
|
|
19231
19558
|
return _this;
|
|
19232
19559
|
};
|
|
19233
19560
|
_inherits$2(SpriteRenderer, Renderer);
|
|
@@ -19333,7 +19660,7 @@ SlicedSpriteAssembler = __decorate$1([
|
|
|
19333
19660
|
break;
|
|
19334
19661
|
}
|
|
19335
19662
|
};
|
|
19336
|
-
|
|
19663
|
+
_create_class$2(SpriteRenderer, [
|
|
19337
19664
|
{
|
|
19338
19665
|
key: "drawMode",
|
|
19339
19666
|
get: /**
|
|
@@ -19482,7 +19809,9 @@ SlicedSpriteAssembler = __decorate$1([
|
|
|
19482
19809
|
]);
|
|
19483
19810
|
return SpriteRenderer;
|
|
19484
19811
|
}(exports.Renderer);
|
|
19485
|
-
|
|
19812
|
+
(function() {
|
|
19813
|
+
/** @internal */ SpriteRenderer._textureProperty = Shader.getPropertyByName("u_spriteTexture");
|
|
19814
|
+
})();
|
|
19486
19815
|
__decorate$1([
|
|
19487
19816
|
ignoreClone
|
|
19488
19817
|
], SpriteRenderer.prototype, "_renderData", void 0);
|
|
@@ -19538,14 +19867,16 @@ var /**
|
|
|
19538
19867
|
];
|
|
19539
19868
|
this.renderData = new RenderData2D(4, positions, null, CharRenderData.triangles, null);
|
|
19540
19869
|
};
|
|
19541
|
-
|
|
19542
|
-
|
|
19543
|
-
|
|
19544
|
-
|
|
19545
|
-
|
|
19546
|
-
|
|
19547
|
-
|
|
19548
|
-
|
|
19870
|
+
(function() {
|
|
19871
|
+
CharRenderData.triangles = [
|
|
19872
|
+
0,
|
|
19873
|
+
2,
|
|
19874
|
+
1,
|
|
19875
|
+
2,
|
|
19876
|
+
0,
|
|
19877
|
+
3
|
|
19878
|
+
];
|
|
19879
|
+
})();
|
|
19549
19880
|
/**
|
|
19550
19881
|
* @internal
|
|
19551
19882
|
*/ var CharRenderDataPool = /*#__PURE__*/ function() {
|
|
@@ -19867,23 +20198,37 @@ CharRenderData.triangles = [
|
|
|
19867
20198
|
};
|
|
19868
20199
|
return TextUtils;
|
|
19869
20200
|
}();
|
|
19870
|
-
|
|
19871
|
-
|
|
19872
|
-
|
|
19873
|
-
|
|
19874
|
-
|
|
19875
|
-
|
|
19876
|
-
|
|
19877
|
-
|
|
19878
|
-
|
|
19879
|
-
|
|
19880
|
-
|
|
19881
|
-
|
|
19882
|
-
|
|
19883
|
-
|
|
19884
|
-
TextUtils.
|
|
19885
|
-
|
|
19886
|
-
|
|
20201
|
+
(function() {
|
|
20202
|
+
/** @internal */ TextUtils._genericFontFamilies = [
|
|
20203
|
+
"serif",
|
|
20204
|
+
"sans-serif",
|
|
20205
|
+
"monospace",
|
|
20206
|
+
"cursive",
|
|
20207
|
+
"fantasy",
|
|
20208
|
+
"system-ui",
|
|
20209
|
+
"math",
|
|
20210
|
+
"emoji",
|
|
20211
|
+
"fangsong"
|
|
20212
|
+
];
|
|
20213
|
+
})();
|
|
20214
|
+
(function() {
|
|
20215
|
+
/** These characters are all tall to help calculate the height required for text. */ TextUtils._measureString = "|\xc9q\xc5";
|
|
20216
|
+
})();
|
|
20217
|
+
(function() {
|
|
20218
|
+
TextUtils._measureBaseline = "M";
|
|
20219
|
+
})();
|
|
20220
|
+
(function() {
|
|
20221
|
+
TextUtils._heightMultiplier = 2;
|
|
20222
|
+
})();
|
|
20223
|
+
(function() {
|
|
20224
|
+
TextUtils._baselineMultiplier = 1.4;
|
|
20225
|
+
})();
|
|
20226
|
+
(function() {
|
|
20227
|
+
TextUtils._fontSizeInfoCache = {};
|
|
20228
|
+
})();
|
|
20229
|
+
(function() {
|
|
20230
|
+
TextUtils._textContext = null;
|
|
20231
|
+
})();
|
|
19887
20232
|
/**
|
|
19888
20233
|
* Renders a text for 2D graphics.
|
|
19889
20234
|
*/ var TextRenderer = /*#__PURE__*/ function(Renderer) {
|
|
@@ -19908,7 +20253,7 @@ TextUtils._textContext = null;
|
|
|
19908
20253
|
_this._overflowMode = exports.OverflowMode.Overflow;
|
|
19909
20254
|
_this._maskInteraction = exports.SpriteMaskInteraction.None;
|
|
19910
20255
|
_this._maskLayer = exports.SpriteMaskLayer.Layer0;
|
|
19911
|
-
var engine =
|
|
20256
|
+
var engine = _assert_this_initialized(_this).engine;
|
|
19912
20257
|
_this._font = engine._textDefaultFont;
|
|
19913
20258
|
_this._font._addRefCount(1);
|
|
19914
20259
|
_this.setMaterial(engine._spriteDefaultMaterial);
|
|
@@ -20148,7 +20493,7 @@ TextUtils._textContext = null;
|
|
|
20148
20493
|
Renderer.prototype._onTransformChanged.call(this, bit);
|
|
20149
20494
|
this._setDirtyFlagTrue(0x4 | 0x8);
|
|
20150
20495
|
};
|
|
20151
|
-
|
|
20496
|
+
_create_class$2(TextRenderer, [
|
|
20152
20497
|
{
|
|
20153
20498
|
key: "color",
|
|
20154
20499
|
get: /**
|
|
@@ -20361,9 +20706,15 @@ TextUtils._textContext = null;
|
|
|
20361
20706
|
]);
|
|
20362
20707
|
return TextRenderer;
|
|
20363
20708
|
}(exports.Renderer);
|
|
20364
|
-
|
|
20365
|
-
TextRenderer.
|
|
20366
|
-
|
|
20709
|
+
(function() {
|
|
20710
|
+
TextRenderer._charRenderDataPool = new CharRenderDataPool(CharRenderData, 50);
|
|
20711
|
+
})();
|
|
20712
|
+
(function() {
|
|
20713
|
+
TextRenderer._tempVec30 = new miniprogram$7.Vector3();
|
|
20714
|
+
})();
|
|
20715
|
+
(function() {
|
|
20716
|
+
TextRenderer._tempVec31 = new miniprogram$7.Vector3();
|
|
20717
|
+
})();
|
|
20367
20718
|
__decorate$1([
|
|
20368
20719
|
assignmentClone
|
|
20369
20720
|
], TextRenderer.prototype, "_subFont", void 0);
|
|
@@ -20578,7 +20929,9 @@ var DirtyFlag;
|
|
|
20578
20929
|
};
|
|
20579
20930
|
return AnimationCurveOwner;
|
|
20580
20931
|
}();
|
|
20581
|
-
|
|
20932
|
+
(function() {
|
|
20933
|
+
AnimationCurveOwner._assemblerMap = new Map();
|
|
20934
|
+
})();
|
|
20582
20935
|
/**
|
|
20583
20936
|
* @internal
|
|
20584
20937
|
*/ var PositionAnimationCurveOwnerAssembler = /*#__PURE__*/ function() {
|
|
@@ -20744,7 +21097,7 @@ AnimationCurveOwner.registerAssembler(SkinnedMeshRenderer, "blendShapeWeights",
|
|
|
20744
21097
|
}
|
|
20745
21098
|
}
|
|
20746
21099
|
};
|
|
20747
|
-
|
|
21100
|
+
_create_class$2(AnimationClip, [
|
|
20748
21101
|
{
|
|
20749
21102
|
key: "events",
|
|
20750
21103
|
get: /**
|
|
@@ -20890,7 +21243,7 @@ AnimationCurveOwner.registerAssembler(SkinnedMeshRenderer, "blendShapeWeights",
|
|
|
20890
21243
|
var result = this._evaluate(time, evaluateData);
|
|
20891
21244
|
return this._type._subtractValue(result, this.keys[0].value, evaluateData.value);
|
|
20892
21245
|
};
|
|
20893
|
-
|
|
21246
|
+
_create_class$2(AnimationCurve, [
|
|
20894
21247
|
{
|
|
20895
21248
|
key: "interpolation",
|
|
20896
21249
|
get: /**
|
|
@@ -20999,7 +21352,11 @@ exports.AnimationArrayCurve = (_AnimationArrayCurve = /*#__PURE__*/ function(Ani
|
|
|
20999
21352
|
return out;
|
|
21000
21353
|
};
|
|
21001
21354
|
return AnimationArrayCurve;
|
|
21002
|
-
}(AnimationCurve),
|
|
21355
|
+
}(AnimationCurve), function() {
|
|
21356
|
+
/** @internal */ _AnimationArrayCurve._isReferenceType = true;
|
|
21357
|
+
}(), function() {
|
|
21358
|
+
/** @internal */ _AnimationArrayCurve._isInterpolationType = true;
|
|
21359
|
+
}(), _AnimationArrayCurve);
|
|
21003
21360
|
exports.AnimationArrayCurve = __decorate$1([
|
|
21004
21361
|
StaticInterfaceImplement$1()
|
|
21005
21362
|
], exports.AnimationArrayCurve);
|
|
@@ -21051,7 +21408,11 @@ exports.AnimationBoolCurve = (_AnimationBoolCurve = /*#__PURE__*/ function(Anima
|
|
|
21051
21408
|
return frame.value;
|
|
21052
21409
|
};
|
|
21053
21410
|
return AnimationBoolCurve;
|
|
21054
|
-
}(AnimationCurve),
|
|
21411
|
+
}(AnimationCurve), function() {
|
|
21412
|
+
/** @internal */ _AnimationBoolCurve._isReferenceType = false;
|
|
21413
|
+
}(), function() {
|
|
21414
|
+
/** @internal */ _AnimationBoolCurve._isInterpolationType = false;
|
|
21415
|
+
}(), _AnimationBoolCurve);
|
|
21055
21416
|
exports.AnimationBoolCurve = __decorate$1([
|
|
21056
21417
|
StaticInterfaceImplement$1()
|
|
21057
21418
|
], exports.AnimationBoolCurve);
|
|
@@ -21143,7 +21504,11 @@ exports.AnimationColorCurve = (_AnimationColorCurve = /*#__PURE__*/ function(Ani
|
|
|
21143
21504
|
return out;
|
|
21144
21505
|
};
|
|
21145
21506
|
return AnimationColorCurve;
|
|
21146
|
-
}(AnimationCurve),
|
|
21507
|
+
}(AnimationCurve), function() {
|
|
21508
|
+
/** @internal */ _AnimationColorCurve._isReferenceType = true;
|
|
21509
|
+
}(), function() {
|
|
21510
|
+
/** @internal */ _AnimationColorCurve._isInterpolationType = true;
|
|
21511
|
+
}(), _AnimationColorCurve);
|
|
21147
21512
|
exports.AnimationColorCurve = __decorate$1([
|
|
21148
21513
|
StaticInterfaceImplement$1()
|
|
21149
21514
|
], exports.AnimationColorCurve);
|
|
@@ -21238,7 +21603,11 @@ exports.AnimationFloatArrayCurve = (_AnimationFloatArrayCurve = /*#__PURE__*/ fu
|
|
|
21238
21603
|
return out;
|
|
21239
21604
|
};
|
|
21240
21605
|
return AnimationFloatArrayCurve;
|
|
21241
|
-
}(AnimationCurve),
|
|
21606
|
+
}(AnimationCurve), function() {
|
|
21607
|
+
/** @internal */ _AnimationFloatArrayCurve._isReferenceType = true;
|
|
21608
|
+
}(), function() {
|
|
21609
|
+
/** @internal */ _AnimationFloatArrayCurve._isInterpolationType = true;
|
|
21610
|
+
}(), _AnimationFloatArrayCurve);
|
|
21242
21611
|
exports.AnimationFloatArrayCurve = __decorate$1([
|
|
21243
21612
|
StaticInterfaceImplement$1()
|
|
21244
21613
|
], exports.AnimationFloatArrayCurve);
|
|
@@ -21302,7 +21671,11 @@ exports.AnimationFloatCurve = (_AnimationFloatCurve = /*#__PURE__*/ function(Ani
|
|
|
21302
21671
|
}
|
|
21303
21672
|
};
|
|
21304
21673
|
return AnimationFloatCurve;
|
|
21305
|
-
}(AnimationCurve),
|
|
21674
|
+
}(AnimationCurve), function() {
|
|
21675
|
+
/** @internal */ _AnimationFloatCurve._isReferenceType = false;
|
|
21676
|
+
}(), function() {
|
|
21677
|
+
/** @internal */ _AnimationFloatCurve._isInterpolationType = true;
|
|
21678
|
+
}(), _AnimationFloatCurve);
|
|
21306
21679
|
exports.AnimationFloatCurve = __decorate$1([
|
|
21307
21680
|
StaticInterfaceImplement$1()
|
|
21308
21681
|
], exports.AnimationFloatCurve);
|
|
@@ -21399,7 +21772,13 @@ exports.AnimationQuaternionCurve = (_AnimationQuaternionCurve = /*#__PURE__*/ fu
|
|
|
21399
21772
|
return out;
|
|
21400
21773
|
};
|
|
21401
21774
|
return AnimationQuaternionCurve1;
|
|
21402
|
-
}(AnimationCurve),
|
|
21775
|
+
}(AnimationCurve), function() {
|
|
21776
|
+
/** @internal */ _AnimationQuaternionCurve._isInterpolationType = true;
|
|
21777
|
+
}(), function() {
|
|
21778
|
+
/** @internal */ _AnimationQuaternionCurve._isReferenceType = true;
|
|
21779
|
+
}(), function() {
|
|
21780
|
+
/** @internal */ _AnimationQuaternionCurve._tempConjugateQuat = new miniprogram$7.Quaternion();
|
|
21781
|
+
}(), _AnimationQuaternionCurve);
|
|
21403
21782
|
exports.AnimationQuaternionCurve = __decorate$1([
|
|
21404
21783
|
StaticInterfaceImplement$1()
|
|
21405
21784
|
], exports.AnimationQuaternionCurve);
|
|
@@ -21479,7 +21858,11 @@ exports.AnimationVector2Curve = (_AnimationVector2Curve = /*#__PURE__*/ function
|
|
|
21479
21858
|
return out;
|
|
21480
21859
|
};
|
|
21481
21860
|
return AnimationVector2Curve;
|
|
21482
|
-
}(AnimationCurve),
|
|
21861
|
+
}(AnimationCurve), function() {
|
|
21862
|
+
/** @internal */ _AnimationVector2Curve._isReferenceType = true;
|
|
21863
|
+
}(), function() {
|
|
21864
|
+
/** @internal */ _AnimationVector2Curve._isInterpolationType = true;
|
|
21865
|
+
}(), _AnimationVector2Curve);
|
|
21483
21866
|
exports.AnimationVector2Curve = __decorate$1([
|
|
21484
21867
|
StaticInterfaceImplement$1()
|
|
21485
21868
|
], exports.AnimationVector2Curve);
|
|
@@ -21571,7 +21954,11 @@ exports.AnimationVector3Curve = (_AnimationVector3Curve = /*#__PURE__*/ function
|
|
|
21571
21954
|
return out;
|
|
21572
21955
|
};
|
|
21573
21956
|
return AnimationVector3Curve;
|
|
21574
|
-
}(AnimationCurve),
|
|
21957
|
+
}(AnimationCurve), function() {
|
|
21958
|
+
/** @internal */ _AnimationVector3Curve._isReferenceType = true;
|
|
21959
|
+
}(), function() {
|
|
21960
|
+
/** @internal */ _AnimationVector3Curve._isInterpolationType = true;
|
|
21961
|
+
}(), _AnimationVector3Curve);
|
|
21575
21962
|
exports.AnimationVector3Curve = __decorate$1([
|
|
21576
21963
|
StaticInterfaceImplement$1()
|
|
21577
21964
|
], exports.AnimationVector3Curve);
|
|
@@ -21663,7 +22050,11 @@ exports.AnimationVector4Curve = (_AnimationVector4Curve = /*#__PURE__*/ function
|
|
|
21663
22050
|
return out;
|
|
21664
22051
|
};
|
|
21665
22052
|
return AnimationVector4Curve;
|
|
21666
|
-
}(AnimationCurve),
|
|
22053
|
+
}(AnimationCurve), function() {
|
|
22054
|
+
/** @internal */ _AnimationVector4Curve._isReferenceType = true;
|
|
22055
|
+
}(), function() {
|
|
22056
|
+
/** @internal */ _AnimationVector4Curve._isInterpolationType = true;
|
|
22057
|
+
}(), _AnimationVector4Curve);
|
|
21667
22058
|
exports.AnimationVector4Curve = __decorate$1([
|
|
21668
22059
|
StaticInterfaceImplement$1()
|
|
21669
22060
|
], exports.AnimationVector4Curve);
|
|
@@ -22368,7 +22759,7 @@ exports.AnimatorLayerBlendingMode = void 0;
|
|
|
22368
22759
|
}
|
|
22369
22760
|
}
|
|
22370
22761
|
};
|
|
22371
|
-
|
|
22762
|
+
_create_class$2(Animator, [
|
|
22372
22763
|
{
|
|
22373
22764
|
key: "animatorController",
|
|
22374
22765
|
get: /**
|
|
@@ -22458,7 +22849,7 @@ __decorate$1([
|
|
|
22458
22849
|
*/ _proto._registerChangeFlag = function _registerChangeFlag() {
|
|
22459
22850
|
return this._updateFlagManager.createFlag(BoolUpdateFlag);
|
|
22460
22851
|
};
|
|
22461
|
-
|
|
22852
|
+
_create_class$2(AnimatorController, [
|
|
22462
22853
|
{
|
|
22463
22854
|
key: "layers",
|
|
22464
22855
|
get: /**
|
|
@@ -22589,7 +22980,7 @@ __decorate$1([
|
|
|
22589
22980
|
index2 !== -1 && this._onStateExitScripts.splice(index2, 1);
|
|
22590
22981
|
}
|
|
22591
22982
|
};
|
|
22592
|
-
|
|
22983
|
+
_create_class$2(AnimatorState, [
|
|
22593
22984
|
{
|
|
22594
22985
|
key: "transitions",
|
|
22595
22986
|
get: /**
|
|
@@ -22716,7 +23107,7 @@ exports.AnimatorConditionMode = void 0;
|
|
|
22716
23107
|
return _this;
|
|
22717
23108
|
};
|
|
22718
23109
|
_inherits$2(SkyBoxMaterial, Material);
|
|
22719
|
-
|
|
23110
|
+
_create_class$2(SkyBoxMaterial, [
|
|
22720
23111
|
{
|
|
22721
23112
|
key: "textureDecodeRGBM",
|
|
22722
23113
|
get: /**
|
|
@@ -22813,7 +23204,7 @@ exports.ParticleRendererBlendMode = void 0;
|
|
|
22813
23204
|
_this._isFadeOut = false;
|
|
22814
23205
|
_this._playOnEnable = true;
|
|
22815
23206
|
_this._blendMode = 0;
|
|
22816
|
-
_this._onColorChanged = _this._onColorChanged.bind(
|
|
23207
|
+
_this._onColorChanged = _this._onColorChanged.bind(_assert_this_initialized(_this));
|
|
22817
23208
|
//@ts-ignore
|
|
22818
23209
|
_this._color._onValueChanged = _this._onColorChanged;
|
|
22819
23210
|
_this.setMaterial(_this._createMaterial());
|
|
@@ -23091,7 +23482,7 @@ exports.ParticleRendererBlendMode = void 0;
|
|
|
23091
23482
|
ParticleRenderer._getRandom = function _getRandom() {
|
|
23092
23483
|
return Math.random() - 0.5;
|
|
23093
23484
|
};
|
|
23094
|
-
|
|
23485
|
+
_create_class$2(ParticleRenderer, [
|
|
23095
23486
|
{
|
|
23096
23487
|
key: "texture",
|
|
23097
23488
|
get: /**
|
|
@@ -23522,7 +23913,9 @@ exports.ParticleRendererBlendMode = void 0;
|
|
|
23522
23913
|
]);
|
|
23523
23914
|
return ParticleRenderer;
|
|
23524
23915
|
}(MeshRenderer);
|
|
23525
|
-
|
|
23916
|
+
(function() {
|
|
23917
|
+
/** The max number of indices that Uint16Array can support. */ ParticleRenderer._uint16VertexLimit = 65535;
|
|
23918
|
+
})();
|
|
23526
23919
|
__decorate$1([
|
|
23527
23920
|
ignoreClone
|
|
23528
23921
|
], ParticleRenderer.prototype, "_onColorChanged", null);
|
|
@@ -23787,7 +24180,7 @@ var _tempVector3 = new miniprogram$7.Vector3();
|
|
|
23787
24180
|
this._camera.renderTarget = this._oriCameraRenderTarget;
|
|
23788
24181
|
this._camera.cullingMask = this._oriCameraCullingMask;
|
|
23789
24182
|
};
|
|
23790
|
-
|
|
24183
|
+
_create_class$2(Probe, [
|
|
23791
24184
|
{
|
|
23792
24185
|
key: "_texture",
|
|
23793
24186
|
get: function get() {
|
|
@@ -24002,7 +24395,7 @@ exports.resourceLoader = resourceLoader;
|
|
|
24002
24395
|
exports.shallowClone = shallowClone;
|
|
24003
24396
|
|
|
24004
24397
|
var miniprogram$8 = /*#__PURE__*/Object.freeze({
|
|
24005
|
-
|
|
24398
|
+
__proto__: null
|
|
24006
24399
|
});
|
|
24007
24400
|
|
|
24008
24401
|
Object.defineProperty(exports, "__esModule", {
|
|
@@ -24013,32 +24406,22 @@ var engineMiniprogramAdapter$1 = require("@galacean/engine-miniprogram-adapter")
|
|
|
24013
24406
|
var miniprogram$1$2 = require("@galacean/engine-math/dist/miniprogram");
|
|
24014
24407
|
var miniprogram$2$1 = require("@galacean/engine-draco/dist/miniprogram");
|
|
24015
24408
|
var miniprogram$3$1 = require("@galacean/engine-rhi-webgl/dist/miniprogram");
|
|
24016
|
-
function
|
|
24017
|
-
|
|
24409
|
+
function _extends$1() {
|
|
24410
|
+
_extends$1 = Object.assign || function assign(target) {
|
|
24018
24411
|
for(var i = 1; i < arguments.length; i++){
|
|
24019
24412
|
var source = arguments[i];
|
|
24020
|
-
for(var key in source)
|
|
24021
|
-
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
24022
|
-
target[key] = source[key];
|
|
24023
|
-
}
|
|
24024
|
-
}
|
|
24413
|
+
for(var key in source)if (Object.prototype.hasOwnProperty.call(source, key)) target[key] = source[key];
|
|
24025
24414
|
}
|
|
24026
24415
|
return target;
|
|
24027
24416
|
};
|
|
24028
|
-
return
|
|
24417
|
+
return _extends$1.apply(this, arguments);
|
|
24029
24418
|
}
|
|
24030
|
-
function
|
|
24031
|
-
|
|
24032
|
-
}
|
|
24033
|
-
function setPrototypeOf$1(o, p) {
|
|
24034
|
-
setPrototypeOf$1 = Object.setPrototypeOf || function setPrototypeOf(o, p) {
|
|
24419
|
+
function _set_prototype_of$1(o, p) {
|
|
24420
|
+
_set_prototype_of$1 = Object.setPrototypeOf || function setPrototypeOf(o, p) {
|
|
24035
24421
|
o.__proto__ = p;
|
|
24036
24422
|
return o;
|
|
24037
24423
|
};
|
|
24038
|
-
return
|
|
24039
|
-
}
|
|
24040
|
-
function _setPrototypeOf$1(o, p) {
|
|
24041
|
-
return setPrototypeOf$1(o, p);
|
|
24424
|
+
return _set_prototype_of$1(o, p);
|
|
24042
24425
|
}
|
|
24043
24426
|
function _inherits$1(subClass, superClass) {
|
|
24044
24427
|
if (typeof superClass !== "function" && superClass !== null) {
|
|
@@ -24051,7 +24434,7 @@ function _inherits$1(subClass, superClass) {
|
|
|
24051
24434
|
configurable: true
|
|
24052
24435
|
}
|
|
24053
24436
|
});
|
|
24054
|
-
if (superClass)
|
|
24437
|
+
if (superClass) _set_prototype_of$1(subClass, superClass);
|
|
24055
24438
|
}
|
|
24056
24439
|
/******************************************************************************
|
|
24057
24440
|
Copyright (c) Microsoft Corporation.
|
|
@@ -24334,13 +24717,10 @@ function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
|
|
|
24334
24717
|
reject(error);
|
|
24335
24718
|
return;
|
|
24336
24719
|
}
|
|
24337
|
-
if (info.done)
|
|
24338
|
-
|
|
24339
|
-
} else {
|
|
24340
|
-
Promise.resolve(value).then(_next, _throw);
|
|
24341
|
-
}
|
|
24720
|
+
if (info.done) resolve(value);
|
|
24721
|
+
else Promise.resolve(value).then(_next, _throw);
|
|
24342
24722
|
}
|
|
24343
|
-
function
|
|
24723
|
+
function _async_to_generator(fn) {
|
|
24344
24724
|
return function() {
|
|
24345
24725
|
var self = this, args = arguments;
|
|
24346
24726
|
return new Promise(function(resolve, reject) {
|
|
@@ -24385,7 +24765,7 @@ var FontLoader = /*#__PURE__*/ function(Loader) {
|
|
|
24385
24765
|
});
|
|
24386
24766
|
};
|
|
24387
24767
|
_proto._registerFont = function _registerFont(fontName, fontUrl) {
|
|
24388
|
-
return
|
|
24768
|
+
return _async_to_generator(function() {
|
|
24389
24769
|
var fontFace;
|
|
24390
24770
|
return __generator(this, function(_state) {
|
|
24391
24771
|
switch(_state.label){
|
|
@@ -24993,30 +25373,32 @@ var TextureWrapMode;
|
|
|
24993
25373
|
};
|
|
24994
25374
|
return GLTFUtil;
|
|
24995
25375
|
}();
|
|
24996
|
-
function
|
|
25376
|
+
function _array_like_to_array(arr, len) {
|
|
24997
25377
|
if (len == null || len > arr.length) len = arr.length;
|
|
24998
25378
|
for(var i = 0, arr2 = new Array(len); i < len; i++)arr2[i] = arr[i];
|
|
24999
25379
|
return arr2;
|
|
25000
25380
|
}
|
|
25001
|
-
function
|
|
25002
|
-
if (Array.isArray(arr)) return
|
|
25381
|
+
function _array_without_holes(arr) {
|
|
25382
|
+
if (Array.isArray(arr)) return _array_like_to_array(arr);
|
|
25003
25383
|
}
|
|
25004
|
-
function
|
|
25005
|
-
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null)
|
|
25384
|
+
function _iterable_to_array(iter) {
|
|
25385
|
+
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) {
|
|
25386
|
+
return Array.from(iter);
|
|
25387
|
+
}
|
|
25006
25388
|
}
|
|
25007
|
-
function
|
|
25008
|
-
throw new TypeError("Invalid attempt to spread non-iterable instance
|
|
25389
|
+
function _non_iterable_spread() {
|
|
25390
|
+
throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
25009
25391
|
}
|
|
25010
|
-
function
|
|
25392
|
+
function _unsupported_iterable_to_array(o, minLen) {
|
|
25011
25393
|
if (!o) return;
|
|
25012
|
-
if (typeof o === "string") return
|
|
25394
|
+
if (typeof o === "string") return _array_like_to_array(o, minLen);
|
|
25013
25395
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
25014
25396
|
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
25015
25397
|
if (n === "Map" || n === "Set") return Array.from(n);
|
|
25016
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return
|
|
25398
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
|
|
25017
25399
|
}
|
|
25018
|
-
function
|
|
25019
|
-
return
|
|
25400
|
+
function _to_consumable_array(arr) {
|
|
25401
|
+
return _array_without_holes(arr) || _iterable_to_array(arr) || _unsupported_iterable_to_array(arr) || _non_iterable_spread();
|
|
25020
25402
|
}
|
|
25021
25403
|
var Parser = /*#__PURE__*/ function() {
|
|
25022
25404
|
var Parser = function Parser() {};
|
|
@@ -25032,7 +25414,7 @@ var Parser = /*#__PURE__*/ function() {
|
|
|
25032
25414
|
extensionSchema,
|
|
25033
25415
|
parseResource,
|
|
25034
25416
|
context
|
|
25035
|
-
].concat(
|
|
25417
|
+
].concat(_to_consumable_array(extra)));
|
|
25036
25418
|
}
|
|
25037
25419
|
}
|
|
25038
25420
|
};
|
|
@@ -25046,7 +25428,7 @@ var Parser = /*#__PURE__*/ function() {
|
|
|
25046
25428
|
return (_parsers_ = parsers[0]).createEngineResource.apply(_parsers_, [
|
|
25047
25429
|
extensionSchema,
|
|
25048
25430
|
context
|
|
25049
|
-
].concat(
|
|
25431
|
+
].concat(_to_consumable_array(extra)));
|
|
25050
25432
|
}
|
|
25051
25433
|
};
|
|
25052
25434
|
Parser.hasExtensionParser = function hasExtensionParser(extensionName) {
|
|
@@ -25071,7 +25453,9 @@ var Parser = /*#__PURE__*/ function() {
|
|
|
25071
25453
|
};
|
|
25072
25454
|
return Parser;
|
|
25073
25455
|
}();
|
|
25074
|
-
|
|
25456
|
+
(function() {
|
|
25457
|
+
Parser._extensionParsers = {};
|
|
25458
|
+
})();
|
|
25075
25459
|
/**
|
|
25076
25460
|
* Declare ExtensionParser's decorator.
|
|
25077
25461
|
* @param extensionName - Extension name
|
|
@@ -25145,9 +25529,7 @@ KHR_draco_mesh_compression = __decorate([
|
|
|
25145
25529
|
function _instanceof1$1(left, right) {
|
|
25146
25530
|
if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
|
|
25147
25531
|
return !!right[Symbol.hasInstance](left);
|
|
25148
|
-
} else
|
|
25149
|
-
return _instanceof(left, right);
|
|
25150
|
-
}
|
|
25532
|
+
} else return _instanceof(left, right);
|
|
25151
25533
|
}
|
|
25152
25534
|
var KHR_lights_punctual = /*#__PURE__*/ function(ExtensionParser) {
|
|
25153
25535
|
var KHR_lights_punctual = function KHR_lights_punctual() {
|
|
@@ -25460,11 +25842,11 @@ var GalaceanMaterialsRemap = /*#__PURE__*/ function(ExtensionParser) {
|
|
|
25460
25842
|
GalaceanMaterialsRemap = __decorate([
|
|
25461
25843
|
registerExtension("OASIS_materials_remap")
|
|
25462
25844
|
], GalaceanMaterialsRemap);
|
|
25463
|
-
function
|
|
25845
|
+
function _create_for_of_iterator_helper_loose(o, allowArrayLike) {
|
|
25464
25846
|
var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"];
|
|
25465
25847
|
if (it) return (it = it.call(o)).next.bind(it);
|
|
25466
25848
|
// Fallback for engines without symbol support
|
|
25467
|
-
if (Array.isArray(o) || (it =
|
|
25849
|
+
if (Array.isArray(o) || (it = _unsupported_iterable_to_array(o)) || allowArrayLike && o && typeof o.length === "number") {
|
|
25468
25850
|
if (it) o = it;
|
|
25469
25851
|
var i = 0;
|
|
25470
25852
|
return function() {
|
|
@@ -25477,7 +25859,7 @@ function _createForOfIteratorHelperLoose(o, allowArrayLike) {
|
|
|
25477
25859
|
};
|
|
25478
25860
|
};
|
|
25479
25861
|
}
|
|
25480
|
-
throw new TypeError("Invalid attempt to iterate non-iterable instance
|
|
25862
|
+
throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
25481
25863
|
}
|
|
25482
25864
|
var AnimationParser = /*#__PURE__*/ function(Parser) {
|
|
25483
25865
|
var AnimationParser = function AnimationParser() {
|
|
@@ -25769,7 +26151,9 @@ var EntityParser = /*#__PURE__*/ function(Parser) {
|
|
|
25769
26151
|
};
|
|
25770
26152
|
return EntityParser;
|
|
25771
26153
|
}(Parser);
|
|
25772
|
-
|
|
26154
|
+
(function() {
|
|
26155
|
+
/** @internal */ EntityParser._defaultName = "_GLTF_ENTITY_";
|
|
26156
|
+
})();
|
|
25773
26157
|
var MeshParser = /*#__PURE__*/ function(Parser1) {
|
|
25774
26158
|
var MeshParser = function MeshParser() {
|
|
25775
26159
|
return Parser1.apply(this, arguments);
|
|
@@ -25844,6 +26228,8 @@ var MeshParser = /*#__PURE__*/ function(Parser1) {
|
|
|
25844
26228
|
var vertexElements = new Array();
|
|
25845
26229
|
var vertexCount;
|
|
25846
26230
|
var bufferBindIndex = 0;
|
|
26231
|
+
var positions;
|
|
26232
|
+
keepMeshData && (positions = new Array(vertexCount));
|
|
25847
26233
|
for(var attribute in attributes){
|
|
25848
26234
|
var accessor = accessors[attributes[attribute]];
|
|
25849
26235
|
var accessorBuffer = GLTFUtil.getAccessorBuffer(context, gltf, accessor);
|
|
@@ -25885,16 +26271,24 @@ var MeshParser = /*#__PURE__*/ function(Parser1) {
|
|
|
25885
26271
|
if (accessor.min && accessor.max) {
|
|
25886
26272
|
min.copyFromArray(accessor.min);
|
|
25887
26273
|
max.copyFromArray(accessor.max);
|
|
26274
|
+
if (keepMeshData) {
|
|
26275
|
+
var stride1 = vertices.length / attributeCount;
|
|
26276
|
+
for(var j = 0; j < attributeCount; j++){
|
|
26277
|
+
var offset = j * stride1;
|
|
26278
|
+
positions[j] = new miniprogram$1$2.Vector3(vertices[offset], vertices[offset + 1], vertices[offset + 2]);
|
|
26279
|
+
}
|
|
26280
|
+
}
|
|
25888
26281
|
} else {
|
|
25889
26282
|
var position = MeshParser._tempVector3;
|
|
25890
26283
|
min.set(Number.MAX_VALUE, Number.MAX_VALUE, Number.MAX_VALUE);
|
|
25891
26284
|
max.set(-Number.MAX_VALUE, -Number.MAX_VALUE, -Number.MAX_VALUE);
|
|
25892
|
-
var
|
|
25893
|
-
for(var
|
|
25894
|
-
var
|
|
25895
|
-
position.copyFromArray(vertices,
|
|
26285
|
+
var stride2 = vertices.length / attributeCount;
|
|
26286
|
+
for(var j1 = 0; j1 < attributeCount; j1++){
|
|
26287
|
+
var offset1 = j1 * stride2;
|
|
26288
|
+
position.copyFromArray(vertices, offset1);
|
|
25896
26289
|
miniprogram$1$2.Vector3.min(min, position, min);
|
|
25897
26290
|
miniprogram$1$2.Vector3.max(max, position, max);
|
|
26291
|
+
keepMeshData && (positions[j1] = position.clone());
|
|
25898
26292
|
}
|
|
25899
26293
|
}
|
|
25900
26294
|
if (accessor.normalized) {
|
|
@@ -25917,6 +26311,8 @@ var MeshParser = /*#__PURE__*/ function(Parser1) {
|
|
|
25917
26311
|
// BlendShapes
|
|
25918
26312
|
targets && this._createBlendShape(mesh, gltfMesh, targets, getBlendShapeData);
|
|
25919
26313
|
mesh.uploadData(!keepMeshData);
|
|
26314
|
+
//@ts-ignore
|
|
26315
|
+
mesh._positions = positions;
|
|
25920
26316
|
return Promise.resolve(mesh);
|
|
25921
26317
|
};
|
|
25922
26318
|
_proto._createBlendShape = function _createBlendShape(mesh, glTFMesh, glTFTargets, getBlendShapeData) {
|
|
@@ -26038,7 +26434,9 @@ var MeshParser = /*#__PURE__*/ function(Parser1) {
|
|
|
26038
26434
|
};
|
|
26039
26435
|
return MeshParser;
|
|
26040
26436
|
}(Parser);
|
|
26041
|
-
|
|
26437
|
+
(function() {
|
|
26438
|
+
MeshParser._tempVector3 = new miniprogram$1$2.Vector3();
|
|
26439
|
+
})();
|
|
26042
26440
|
var SceneParser$1 = /*#__PURE__*/ function(Parser1) {
|
|
26043
26441
|
var SceneParser = function SceneParser() {
|
|
26044
26442
|
return Parser1.apply(this, arguments);
|
|
@@ -26246,7 +26644,7 @@ var SkinParser = /*#__PURE__*/ function(Parser) {
|
|
|
26246
26644
|
};
|
|
26247
26645
|
_proto._findSkeletonRootBone = function _findSkeletonRootBone(joints, entities) {
|
|
26248
26646
|
var paths = {};
|
|
26249
|
-
for(var _iterator =
|
|
26647
|
+
for(var _iterator = _create_for_of_iterator_helper_loose(joints), _step; !(_step = _iterator()).done;){
|
|
26250
26648
|
var index = _step.value;
|
|
26251
26649
|
var path = new Array();
|
|
26252
26650
|
var entity = entities[index];
|
|
@@ -26347,8 +26745,10 @@ var TextureParser = /*#__PURE__*/ function(Parser) {
|
|
|
26347
26745
|
};
|
|
26348
26746
|
return TextureParser;
|
|
26349
26747
|
}(Parser);
|
|
26350
|
-
|
|
26351
|
-
|
|
26748
|
+
(function() {
|
|
26749
|
+
var _obj;
|
|
26750
|
+
TextureParser._wrapMap = (_obj = {}, _obj[TextureWrapMode.CLAMP_TO_EDGE] = miniprogram$5.TextureWrapMode.Clamp, _obj[TextureWrapMode.MIRRORED_REPEAT] = miniprogram$5.TextureWrapMode.Mirror, _obj[TextureWrapMode.REPEAT] = miniprogram$5.TextureWrapMode.Repeat, _obj);
|
|
26751
|
+
})();
|
|
26352
26752
|
var Validator = /*#__PURE__*/ function(Parser1) {
|
|
26353
26753
|
var Validator = function Validator() {
|
|
26354
26754
|
return Parser1.apply(this, arguments);
|
|
@@ -26418,17 +26818,19 @@ var GLTFParser = /*#__PURE__*/ function() {
|
|
|
26418
26818
|
};
|
|
26419
26819
|
return GLTFParser;
|
|
26420
26820
|
}();
|
|
26421
|
-
|
|
26422
|
-
|
|
26423
|
-
|
|
26424
|
-
|
|
26425
|
-
|
|
26426
|
-
|
|
26427
|
-
|
|
26428
|
-
|
|
26429
|
-
|
|
26430
|
-
|
|
26431
|
-
|
|
26821
|
+
(function() {
|
|
26822
|
+
GLTFParser.defaultPipeline = new GLTFParser([
|
|
26823
|
+
BufferParser,
|
|
26824
|
+
Validator,
|
|
26825
|
+
TextureParser,
|
|
26826
|
+
MaterialParser,
|
|
26827
|
+
MeshParser,
|
|
26828
|
+
EntityParser,
|
|
26829
|
+
SkinParser,
|
|
26830
|
+
AnimationParser,
|
|
26831
|
+
SceneParser$1
|
|
26832
|
+
]);
|
|
26833
|
+
})();
|
|
26432
26834
|
/**
|
|
26433
26835
|
* Product after GLTF parser, usually, `defaultSceneRoot` is only needed to use.
|
|
26434
26836
|
*/ var GLTFResource = /*#__PURE__*/ function(EngineObject) {
|
|
@@ -26478,7 +26880,7 @@ var GLTFLoader = /*#__PURE__*/ function(Loader) {
|
|
|
26478
26880
|
context.keepMeshData = (_item_params_keepMeshData = (_item_params = item.params) == null ? void 0 : _item_params.keepMeshData) != null ? _item_params_keepMeshData : false;
|
|
26479
26881
|
masterPromiseInfo.onCancel(function() {
|
|
26480
26882
|
var chainPromises = context.chainPromises;
|
|
26481
|
-
for(var _iterator =
|
|
26883
|
+
for(var _iterator = _create_for_of_iterator_helper_loose(chainPromises), _step; !(_step = _iterator()).done;){
|
|
26482
26884
|
var promise = _step.value;
|
|
26483
26885
|
promise.cancel();
|
|
26484
26886
|
}
|
|
@@ -26738,37 +27140,75 @@ var HDRLoader = (_HDRLoader = /*#__PURE__*/ function(Loader) {
|
|
|
26738
27140
|
color.a *= M;
|
|
26739
27141
|
};
|
|
26740
27142
|
return HDRLoader1;
|
|
26741
|
-
}(miniprogram$5.Loader),
|
|
26742
|
-
_HDRLoader._rightBottomBack,
|
|
26743
|
-
|
|
26744
|
-
_HDRLoader.
|
|
26745
|
-
|
|
26746
|
-
|
|
26747
|
-
|
|
26748
|
-
_HDRLoader.
|
|
26749
|
-
|
|
26750
|
-
_HDRLoader.
|
|
26751
|
-
|
|
26752
|
-
_HDRLoader._leftBottomFront,
|
|
26753
|
-
|
|
26754
|
-
_HDRLoader.
|
|
26755
|
-
|
|
26756
|
-
|
|
26757
|
-
|
|
26758
|
-
_HDRLoader.
|
|
26759
|
-
|
|
26760
|
-
|
|
26761
|
-
|
|
26762
|
-
|
|
26763
|
-
|
|
26764
|
-
|
|
26765
|
-
_HDRLoader.
|
|
26766
|
-
|
|
26767
|
-
|
|
26768
|
-
|
|
26769
|
-
|
|
26770
|
-
|
|
26771
|
-
|
|
27143
|
+
}(miniprogram$5.Loader), function() {
|
|
27144
|
+
_HDRLoader._rightBottomBack = new miniprogram$1$2.Vector3(1.0, -1.0, -1.0);
|
|
27145
|
+
}(), function() {
|
|
27146
|
+
_HDRLoader._rightBottomFront = new miniprogram$1$2.Vector3(1.0, -1.0, 1.0);
|
|
27147
|
+
}(), function() {
|
|
27148
|
+
_HDRLoader._rightUpBack = new miniprogram$1$2.Vector3(1.0, 1.0, -1.0);
|
|
27149
|
+
}(), function() {
|
|
27150
|
+
_HDRLoader._rightUpFront = new miniprogram$1$2.Vector3(1.0, 1.0, 1.0);
|
|
27151
|
+
}(), function() {
|
|
27152
|
+
_HDRLoader._leftBottomBack = new miniprogram$1$2.Vector3(-1.0, -1.0, -1.0);
|
|
27153
|
+
}(), function() {
|
|
27154
|
+
_HDRLoader._leftBottomFront = new miniprogram$1$2.Vector3(-1.0, -1.0, 1.0);
|
|
27155
|
+
}(), function() {
|
|
27156
|
+
_HDRLoader._leftUpBack = new miniprogram$1$2.Vector3(-1.0, 1.0, -1.0);
|
|
27157
|
+
}(), function() {
|
|
27158
|
+
_HDRLoader._leftUpFront = new miniprogram$1$2.Vector3(-1.0, 1.0, 1.0);
|
|
27159
|
+
}(), function() {
|
|
27160
|
+
_HDRLoader._faceRight = [
|
|
27161
|
+
_HDRLoader._rightBottomBack,
|
|
27162
|
+
_HDRLoader._rightBottomFront,
|
|
27163
|
+
_HDRLoader._rightUpBack,
|
|
27164
|
+
_HDRLoader._rightUpFront
|
|
27165
|
+
];
|
|
27166
|
+
}(), function() {
|
|
27167
|
+
_HDRLoader._faceLeft = [
|
|
27168
|
+
_HDRLoader._leftBottomFront,
|
|
27169
|
+
_HDRLoader._leftBottomBack,
|
|
27170
|
+
_HDRLoader._leftUpFront,
|
|
27171
|
+
_HDRLoader._leftUpBack
|
|
27172
|
+
];
|
|
27173
|
+
}(), function() {
|
|
27174
|
+
_HDRLoader._faceUp = [
|
|
27175
|
+
_HDRLoader._leftBottomFront,
|
|
27176
|
+
_HDRLoader._rightBottomFront,
|
|
27177
|
+
_HDRLoader._leftBottomBack,
|
|
27178
|
+
_HDRLoader._rightBottomBack
|
|
27179
|
+
];
|
|
27180
|
+
}(), function() {
|
|
27181
|
+
_HDRLoader._faceBottom = [
|
|
27182
|
+
_HDRLoader._leftUpBack,
|
|
27183
|
+
_HDRLoader._rightUpBack,
|
|
27184
|
+
_HDRLoader._leftUpFront,
|
|
27185
|
+
_HDRLoader._rightUpFront
|
|
27186
|
+
];
|
|
27187
|
+
}(), function() {
|
|
27188
|
+
_HDRLoader._faceFront = [
|
|
27189
|
+
_HDRLoader._leftBottomBack,
|
|
27190
|
+
_HDRLoader._rightBottomBack,
|
|
27191
|
+
_HDRLoader._leftUpBack,
|
|
27192
|
+
_HDRLoader._rightUpBack
|
|
27193
|
+
];
|
|
27194
|
+
}(), function() {
|
|
27195
|
+
_HDRLoader._faceBack = [
|
|
27196
|
+
_HDRLoader._rightBottomFront,
|
|
27197
|
+
_HDRLoader._leftBottomFront,
|
|
27198
|
+
_HDRLoader._rightUpFront,
|
|
27199
|
+
_HDRLoader._leftUpFront
|
|
27200
|
+
];
|
|
27201
|
+
}(), function() {
|
|
27202
|
+
_HDRLoader._tempVector3 = new miniprogram$1$2.Vector3();
|
|
27203
|
+
}(), function() {
|
|
27204
|
+
_HDRLoader._temp2Vector3 = new miniprogram$1$2.Vector3();
|
|
27205
|
+
}(), function() {
|
|
27206
|
+
_HDRLoader._temp3Vector3 = new miniprogram$1$2.Vector3();
|
|
27207
|
+
}(), function() {
|
|
27208
|
+
_HDRLoader._temp4Vector3 = new miniprogram$1$2.Vector3();
|
|
27209
|
+
}(), function() {
|
|
27210
|
+
_HDRLoader._temp5Vector3 = new miniprogram$1$2.Vector3();
|
|
27211
|
+
}(), _HDRLoader);
|
|
26772
27212
|
HDRLoader = __decorate([
|
|
26773
27213
|
miniprogram$5.resourceLoader(miniprogram$5.AssetType.HDR, [
|
|
26774
27214
|
"hdr"
|
|
@@ -27138,7 +27578,7 @@ function _defineProperties$1(target, props) {
|
|
|
27138
27578
|
Object.defineProperty(target, descriptor.key, descriptor);
|
|
27139
27579
|
}
|
|
27140
27580
|
}
|
|
27141
|
-
function
|
|
27581
|
+
function _create_class$1(Constructor, protoProps, staticProps) {
|
|
27142
27582
|
if (protoProps) _defineProperties$1(Constructor.prototype, protoProps);
|
|
27143
27583
|
if (staticProps) _defineProperties$1(Constructor, staticProps);
|
|
27144
27584
|
return Constructor;
|
|
@@ -27249,7 +27689,7 @@ var BufferReader = /*#__PURE__*/ function() {
|
|
|
27249
27689
|
if (byteLength < maxByteLength) this._offset++;
|
|
27250
27690
|
return new Uint8Array(this._dataView.buffer, this._dataView.byteOffset + byteOffset, byteLength);
|
|
27251
27691
|
};
|
|
27252
|
-
|
|
27692
|
+
_create_class$1(BufferReader, [
|
|
27253
27693
|
{
|
|
27254
27694
|
key: "offset",
|
|
27255
27695
|
get: function get() {
|
|
@@ -27259,12 +27699,14 @@ var BufferReader = /*#__PURE__*/ function() {
|
|
|
27259
27699
|
]);
|
|
27260
27700
|
return BufferReader;
|
|
27261
27701
|
}();
|
|
27262
|
-
|
|
27263
|
-
|
|
27264
|
-
|
|
27265
|
-
|
|
27266
|
-
|
|
27267
|
-
|
|
27702
|
+
(function() {
|
|
27703
|
+
BufferReader.imageMapping = {
|
|
27704
|
+
0: "image/png",
|
|
27705
|
+
1: "image/jpg",
|
|
27706
|
+
2: "image/webp",
|
|
27707
|
+
3: "ktx"
|
|
27708
|
+
};
|
|
27709
|
+
})();
|
|
27268
27710
|
var decoderMap = {};
|
|
27269
27711
|
/**
|
|
27270
27712
|
* Decoder decorator generator.
|
|
@@ -27301,7 +27743,7 @@ var FileHeader = /*#__PURE__*/ function() {
|
|
|
27301
27743
|
header.headerLength = nameUint8Array.byteLength + typeUint8Array.byteLength + 9;
|
|
27302
27744
|
return header;
|
|
27303
27745
|
};
|
|
27304
|
-
|
|
27746
|
+
_create_class$1(FileHeader, [
|
|
27305
27747
|
{
|
|
27306
27748
|
key: "dataLength",
|
|
27307
27749
|
get: function get() {
|
|
@@ -27517,36 +27959,32 @@ exports.Texture2DDecoder = /*#__PURE__*/ function() {
|
|
|
27517
27959
|
exports.Texture2DDecoder = __decorate([
|
|
27518
27960
|
decoder("Texture2D")
|
|
27519
27961
|
], exports.Texture2DDecoder);
|
|
27520
|
-
function
|
|
27962
|
+
function _is_native_reflect_construct() {
|
|
27521
27963
|
if (typeof Reflect === "undefined" || !Reflect.construct) return false;
|
|
27522
27964
|
if (Reflect.construct.sham) return false;
|
|
27523
27965
|
if (typeof Proxy === "function") return true;
|
|
27524
27966
|
try {
|
|
27525
|
-
|
|
27967
|
+
Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
27526
27968
|
return true;
|
|
27527
27969
|
} catch (e) {
|
|
27528
27970
|
return false;
|
|
27529
27971
|
}
|
|
27530
27972
|
}
|
|
27531
|
-
function
|
|
27532
|
-
if (
|
|
27533
|
-
|
|
27534
|
-
|
|
27535
|
-
construct = function construct(Parent, args, Class) {
|
|
27973
|
+
function _construct(Parent, args, Class) {
|
|
27974
|
+
if (_is_native_reflect_construct()) _construct = Reflect.construct;
|
|
27975
|
+
else {
|
|
27976
|
+
_construct = function construct(Parent, args, Class) {
|
|
27536
27977
|
var a = [
|
|
27537
27978
|
null
|
|
27538
27979
|
];
|
|
27539
27980
|
a.push.apply(a, args);
|
|
27540
27981
|
var Constructor = Function.bind.apply(Parent, a);
|
|
27541
27982
|
var instance = new Constructor();
|
|
27542
|
-
if (Class)
|
|
27983
|
+
if (Class) _set_prototype_of$1(instance, Class.prototype);
|
|
27543
27984
|
return instance;
|
|
27544
27985
|
};
|
|
27545
27986
|
}
|
|
27546
|
-
return
|
|
27547
|
-
}
|
|
27548
|
-
function _construct(Parent, args, Class) {
|
|
27549
|
-
return construct.apply(null, arguments);
|
|
27987
|
+
return _construct.apply(null, arguments);
|
|
27550
27988
|
}
|
|
27551
27989
|
var ReflectionParser = /*#__PURE__*/ function() {
|
|
27552
27990
|
var ReflectionParser = function ReflectionParser() {};
|
|
@@ -27660,7 +28098,9 @@ var ReflectionParser = /*#__PURE__*/ function() {
|
|
|
27660
28098
|
};
|
|
27661
28099
|
return ReflectionParser;
|
|
27662
28100
|
}();
|
|
27663
|
-
|
|
28101
|
+
(function() {
|
|
28102
|
+
ReflectionParser.customParseComponentHandles = new Map();
|
|
28103
|
+
})();
|
|
27664
28104
|
var PrefabParser = /*#__PURE__*/ function() {
|
|
27665
28105
|
var PrefabParser = function PrefabParser() {};
|
|
27666
28106
|
PrefabParser.parseChildren = function parseChildren(entitiesConfig, entities, parentId) {
|
|
@@ -27909,7 +28349,7 @@ var SceneParserContext = /*#__PURE__*/ function() {
|
|
|
27909
28349
|
};
|
|
27910
28350
|
_proto._organizeEntities = function _organizeEntities() {
|
|
27911
28351
|
var _this_context = this.context, entityConfigMap = _this_context.entityConfigMap, entityMap = _this_context.entityMap, scene = _this_context.scene, rootIds = _this_context.rootIds;
|
|
27912
|
-
for(var _iterator =
|
|
28352
|
+
for(var _iterator = _create_for_of_iterator_helper_loose(rootIds), _step; !(_step = _iterator()).done;){
|
|
27913
28353
|
var rootId = _step.value;
|
|
27914
28354
|
PrefabParser.parseChildren(entityConfigMap, entityMap, rootId);
|
|
27915
28355
|
}
|
|
@@ -28068,7 +28508,7 @@ var SourceFontLoader = /*#__PURE__*/ function(Loader) {
|
|
|
28068
28508
|
});
|
|
28069
28509
|
};
|
|
28070
28510
|
_proto._registerFont = function _registerFont(fontName, fontUrl) {
|
|
28071
|
-
return
|
|
28511
|
+
return _async_to_generator(function() {
|
|
28072
28512
|
var fontFace;
|
|
28073
28513
|
return __generator(this, function(_state) {
|
|
28074
28514
|
switch(_state.label){
|
|
@@ -28384,7 +28824,7 @@ SceneLoader = __decorate([
|
|
|
28384
28824
|
"prefab"
|
|
28385
28825
|
], true)
|
|
28386
28826
|
], SceneLoader);
|
|
28387
|
-
ReflectionParser.registerCustomParseComponent("TextRenderer", /*#__PURE__*/
|
|
28827
|
+
ReflectionParser.registerCustomParseComponent("TextRenderer", /*#__PURE__*/ _async_to_generator(function(instance, item, engine) {
|
|
28388
28828
|
var props;
|
|
28389
28829
|
return __generator(this, function(_state) {
|
|
28390
28830
|
props = item.props;
|
|
@@ -28407,7 +28847,7 @@ exports.decode = decode;
|
|
|
28407
28847
|
exports.parseSingleKTX = parseSingleKTX;
|
|
28408
28848
|
|
|
28409
28849
|
var miniprogram$6 = /*#__PURE__*/Object.freeze({
|
|
28410
|
-
|
|
28850
|
+
__proto__: null
|
|
28411
28851
|
});
|
|
28412
28852
|
|
|
28413
28853
|
var miniprogram$4 = createCommonjsModule(function (module, exports) {
|
|
@@ -28450,7 +28890,7 @@ function _defineProperties(target, props) {
|
|
|
28450
28890
|
Object.defineProperty(target, descriptor.key, descriptor);
|
|
28451
28891
|
}
|
|
28452
28892
|
}
|
|
28453
|
-
function
|
|
28893
|
+
function _create_class(Constructor, protoProps, staticProps) {
|
|
28454
28894
|
if (protoProps) _defineProperties(Constructor.prototype, protoProps);
|
|
28455
28895
|
if (staticProps) _defineProperties(Constructor, staticProps);
|
|
28456
28896
|
return Constructor;
|
|
@@ -28500,9 +28940,15 @@ function _createClass(Constructor, protoProps, staticProps) {
|
|
|
28500
28940
|
};
|
|
28501
28941
|
return MathUtil;
|
|
28502
28942
|
}();
|
|
28503
|
-
|
|
28504
|
-
/** The
|
|
28505
|
-
|
|
28943
|
+
(function() {
|
|
28944
|
+
/** The value for which all absolute numbers smaller than are considered equal to zero. */ MathUtil.zeroTolerance = 1e-6;
|
|
28945
|
+
})();
|
|
28946
|
+
(function() {
|
|
28947
|
+
/** The conversion factor that radian to degree. */ MathUtil.radToDegreeFactor = 180 / Math.PI;
|
|
28948
|
+
})();
|
|
28949
|
+
(function() {
|
|
28950
|
+
/** The conversion factor that degree to radian. */ MathUtil.degreeToRadFactor = Math.PI / 180;
|
|
28951
|
+
})();
|
|
28506
28952
|
/**
|
|
28507
28953
|
* Describes a 3D-vector.
|
|
28508
28954
|
*/ var Vector3 = /*#__PURE__*/ function() {
|
|
@@ -28960,7 +29406,7 @@ function _createClass(Constructor, protoProps, staticProps) {
|
|
|
28960
29406
|
out._z = iz * qw - iw * qz - ix * qy + iy * qx;
|
|
28961
29407
|
out._onValueChanged && out._onValueChanged();
|
|
28962
29408
|
};
|
|
28963
|
-
|
|
29409
|
+
_create_class(Vector3, [
|
|
28964
29410
|
{
|
|
28965
29411
|
key: "x",
|
|
28966
29412
|
get: /**
|
|
@@ -29000,8 +29446,12 @@ function _createClass(Constructor, protoProps, staticProps) {
|
|
|
29000
29446
|
]);
|
|
29001
29447
|
return Vector3;
|
|
29002
29448
|
}();
|
|
29003
|
-
|
|
29004
|
-
/** @internal */ Vector3.
|
|
29449
|
+
(function() {
|
|
29450
|
+
/** @internal */ Vector3._zero = new Vector3(0.0, 0.0, 0.0);
|
|
29451
|
+
})();
|
|
29452
|
+
(function() {
|
|
29453
|
+
/** @internal */ Vector3._one = new Vector3(1.0, 1.0, 1.0);
|
|
29454
|
+
})();
|
|
29005
29455
|
/**
|
|
29006
29456
|
* A bounding sphere.
|
|
29007
29457
|
* */ var BoundingSphere = /*#__PURE__*/ function() {
|
|
@@ -29069,7 +29519,9 @@ function _createClass(Constructor, protoProps, staticProps) {
|
|
|
29069
29519
|
};
|
|
29070
29520
|
return BoundingSphere;
|
|
29071
29521
|
}();
|
|
29072
|
-
|
|
29522
|
+
(function() {
|
|
29523
|
+
BoundingSphere._tempVec30 = new Vector3();
|
|
29524
|
+
})();
|
|
29073
29525
|
/**
|
|
29074
29526
|
* Axis Aligned Bound Box (AABB).
|
|
29075
29527
|
*/ var BoundingBox = /*#__PURE__*/ function() {
|
|
@@ -29227,8 +29679,12 @@ BoundingSphere._tempVec30 = new Vector3();
|
|
|
29227
29679
|
};
|
|
29228
29680
|
return BoundingBox;
|
|
29229
29681
|
}();
|
|
29230
|
-
|
|
29231
|
-
BoundingBox.
|
|
29682
|
+
(function() {
|
|
29683
|
+
BoundingBox._tempVec30 = new Vector3();
|
|
29684
|
+
})();
|
|
29685
|
+
(function() {
|
|
29686
|
+
BoundingBox._tempVec31 = new Vector3();
|
|
29687
|
+
})();
|
|
29232
29688
|
/**
|
|
29233
29689
|
* Contains static methods to help in determining intersections, containment, etc.
|
|
29234
29690
|
*/ var CollisionUtil = /*#__PURE__*/ function() {
|
|
@@ -29576,9 +30032,15 @@ BoundingBox._tempVec31 = new Vector3();
|
|
|
29576
30032
|
};
|
|
29577
30033
|
return CollisionUtil;
|
|
29578
30034
|
}();
|
|
29579
|
-
|
|
29580
|
-
CollisionUtil.
|
|
29581
|
-
|
|
30035
|
+
(function() {
|
|
30036
|
+
CollisionUtil._tempVec30 = new Vector3();
|
|
30037
|
+
})();
|
|
30038
|
+
(function() {
|
|
30039
|
+
CollisionUtil._tempVec31 = new Vector3();
|
|
30040
|
+
})();
|
|
30041
|
+
(function() {
|
|
30042
|
+
CollisionUtil._tempVec32 = new Vector3();
|
|
30043
|
+
})();
|
|
29582
30044
|
/**
|
|
29583
30045
|
* Represents a plane in three-dimensional space.
|
|
29584
30046
|
*/ var Plane = /*#__PURE__*/ function() {
|
|
@@ -30898,7 +31360,7 @@ CollisionUtil._tempVec32 = new Vector3();
|
|
|
30898
31360
|
out._w = a._w * s;
|
|
30899
31361
|
out._onValueChanged && out._onValueChanged();
|
|
30900
31362
|
};
|
|
30901
|
-
|
|
31363
|
+
_create_class(Quaternion, [
|
|
30902
31364
|
{
|
|
30903
31365
|
key: "x",
|
|
30904
31366
|
get: /**
|
|
@@ -30958,8 +31420,12 @@ CollisionUtil._tempVec32 = new Vector3();
|
|
|
30958
31420
|
]);
|
|
30959
31421
|
return Quaternion;
|
|
30960
31422
|
}();
|
|
30961
|
-
|
|
30962
|
-
/** @internal */ Quaternion.
|
|
31423
|
+
(function() {
|
|
31424
|
+
/** @internal */ Quaternion._tempVector3 = new Vector3();
|
|
31425
|
+
})();
|
|
31426
|
+
(function() {
|
|
31427
|
+
/** @internal */ Quaternion._tempQuat1 = new Quaternion();
|
|
31428
|
+
})();
|
|
30963
31429
|
/**
|
|
30964
31430
|
* Represents a 4x4 mathematical matrix.
|
|
30965
31431
|
*/ var Matrix = /*#__PURE__*/ function() {
|
|
@@ -31904,11 +32370,21 @@ CollisionUtil._tempVec32 = new Vector3();
|
|
|
31904
32370
|
};
|
|
31905
32371
|
return Matrix;
|
|
31906
32372
|
}();
|
|
31907
|
-
|
|
31908
|
-
Matrix.
|
|
31909
|
-
|
|
31910
|
-
|
|
31911
|
-
|
|
32373
|
+
(function() {
|
|
32374
|
+
Matrix._tempVec30 = new Vector3();
|
|
32375
|
+
})();
|
|
32376
|
+
(function() {
|
|
32377
|
+
Matrix._tempVec31 = new Vector3();
|
|
32378
|
+
})();
|
|
32379
|
+
(function() {
|
|
32380
|
+
Matrix._tempVec32 = new Vector3();
|
|
32381
|
+
})();
|
|
32382
|
+
(function() {
|
|
32383
|
+
Matrix._tempMat30 = new Matrix3x3();
|
|
32384
|
+
})();
|
|
32385
|
+
(function() {
|
|
32386
|
+
/** @internal Identity matrix. */ Matrix._identity = new Matrix(1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0);
|
|
32387
|
+
})();
|
|
31912
32388
|
/**
|
|
31913
32389
|
* Represents a ray with an origin and a direction in 3D space.
|
|
31914
32390
|
*/ var Ray = /*#__PURE__*/ function() {
|
|
@@ -32242,7 +32718,7 @@ Matrix._tempMat30 = new Matrix3x3();
|
|
|
32242
32718
|
out._y = left._y * s;
|
|
32243
32719
|
out._onValueChanged && out._onValueChanged();
|
|
32244
32720
|
};
|
|
32245
|
-
|
|
32721
|
+
_create_class(Vector2, [
|
|
32246
32722
|
{
|
|
32247
32723
|
key: "x",
|
|
32248
32724
|
get: /**
|
|
@@ -32270,8 +32746,12 @@ Matrix._tempMat30 = new Matrix3x3();
|
|
|
32270
32746
|
]);
|
|
32271
32747
|
return Vector2;
|
|
32272
32748
|
}();
|
|
32273
|
-
|
|
32274
|
-
/** @internal */ Vector2.
|
|
32749
|
+
(function() {
|
|
32750
|
+
/** @internal */ Vector2._zero = new Vector2(0.0, 0.0);
|
|
32751
|
+
})();
|
|
32752
|
+
(function() {
|
|
32753
|
+
/** @internal */ Vector2._one = new Vector2(1.0, 1.0);
|
|
32754
|
+
})();
|
|
32275
32755
|
/**
|
|
32276
32756
|
* Describes a 4D-vector.
|
|
32277
32757
|
*/ var Vector4 = /*#__PURE__*/ function() {
|
|
@@ -32651,7 +33131,7 @@ Matrix._tempMat30 = new Matrix3x3();
|
|
|
32651
33131
|
out._w = w;
|
|
32652
33132
|
out._onValueChanged && out._onValueChanged();
|
|
32653
33133
|
};
|
|
32654
|
-
|
|
33134
|
+
_create_class(Vector4, [
|
|
32655
33135
|
{
|
|
32656
33136
|
key: "x",
|
|
32657
33137
|
get: /**
|
|
@@ -32703,8 +33183,12 @@ Matrix._tempMat30 = new Matrix3x3();
|
|
|
32703
33183
|
]);
|
|
32704
33184
|
return Vector4;
|
|
32705
33185
|
}();
|
|
32706
|
-
|
|
32707
|
-
/** @internal */ Vector4.
|
|
33186
|
+
(function() {
|
|
33187
|
+
/** @internal */ Vector4._zero = new Vector4(0.0, 0.0, 0.0, 0.0);
|
|
33188
|
+
})();
|
|
33189
|
+
(function() {
|
|
33190
|
+
/** @internal */ Vector4._one = new Vector4(1.0, 1.0, 1.0, 1.0);
|
|
33191
|
+
})();
|
|
32708
33192
|
/**
|
|
32709
33193
|
* Describes a color in the from of RGBA (in order: R, G, B, A).
|
|
32710
33194
|
*/ var Color = /*#__PURE__*/ function() {
|
|
@@ -32913,7 +33397,7 @@ Matrix._tempMat30 = new Matrix3x3();
|
|
|
32913
33397
|
out._onValueChanged && out._onValueChanged();
|
|
32914
33398
|
return out;
|
|
32915
33399
|
};
|
|
32916
|
-
|
|
33400
|
+
_create_class(Color, [
|
|
32917
33401
|
{
|
|
32918
33402
|
key: "r",
|
|
32919
33403
|
get: /**
|
|
@@ -33271,7 +33755,7 @@ function _defineProperties(target, props) {
|
|
|
33271
33755
|
Object.defineProperty(target, descriptor.key, descriptor);
|
|
33272
33756
|
}
|
|
33273
33757
|
}
|
|
33274
|
-
function
|
|
33758
|
+
function _create_class(Constructor, protoProps, staticProps) {
|
|
33275
33759
|
if (protoProps) _defineProperties(Constructor.prototype, protoProps);
|
|
33276
33760
|
if (staticProps) _defineProperties(Constructor, staticProps);
|
|
33277
33761
|
return Constructor;
|
|
@@ -33279,9 +33763,7 @@ function _createClass(Constructor, protoProps, staticProps) {
|
|
|
33279
33763
|
function _instanceof1(left, right) {
|
|
33280
33764
|
if (right != null && typeof Symbol !== "undefined" && right[Symbol.hasInstance]) {
|
|
33281
33765
|
return !!right[Symbol.hasInstance](left);
|
|
33282
|
-
} else
|
|
33283
|
-
return _instanceof(left, right);
|
|
33284
|
-
}
|
|
33766
|
+
} else return _instanceof(left, right);
|
|
33285
33767
|
}
|
|
33286
33768
|
/**
|
|
33287
33769
|
* The canvas used on the web, which can support HTMLCanvasElement and OffscreenCanvas.
|
|
@@ -33314,7 +33796,7 @@ function _instanceof1(left, right) {
|
|
|
33314
33796
|
this._scale.set(x, y);
|
|
33315
33797
|
this.scale = this._scale;
|
|
33316
33798
|
};
|
|
33317
|
-
|
|
33799
|
+
_create_class(WebCanvas, [
|
|
33318
33800
|
{
|
|
33319
33801
|
key: "width",
|
|
33320
33802
|
get: /**
|
|
@@ -33366,15 +33848,12 @@ function _instanceof1(left, right) {
|
|
|
33366
33848
|
]);
|
|
33367
33849
|
return WebCanvas;
|
|
33368
33850
|
}();
|
|
33369
|
-
function
|
|
33370
|
-
|
|
33851
|
+
function _set_prototype_of(o, p) {
|
|
33852
|
+
_set_prototype_of = Object.setPrototypeOf || function setPrototypeOf(o, p) {
|
|
33371
33853
|
o.__proto__ = p;
|
|
33372
33854
|
return o;
|
|
33373
33855
|
};
|
|
33374
|
-
return
|
|
33375
|
-
}
|
|
33376
|
-
function _setPrototypeOf(o, p) {
|
|
33377
|
-
return setPrototypeOf(o, p);
|
|
33856
|
+
return _set_prototype_of(o, p);
|
|
33378
33857
|
}
|
|
33379
33858
|
function _inherits(subClass, superClass) {
|
|
33380
33859
|
if (typeof superClass !== "function" && superClass !== null) {
|
|
@@ -33387,24 +33866,17 @@ function _inherits(subClass, superClass) {
|
|
|
33387
33866
|
configurable: true
|
|
33388
33867
|
}
|
|
33389
33868
|
});
|
|
33390
|
-
if (superClass)
|
|
33869
|
+
if (superClass) _set_prototype_of(subClass, superClass);
|
|
33391
33870
|
}
|
|
33392
|
-
function
|
|
33393
|
-
|
|
33871
|
+
function _extends() {
|
|
33872
|
+
_extends = Object.assign || function assign(target) {
|
|
33394
33873
|
for(var i = 1; i < arguments.length; i++){
|
|
33395
33874
|
var source = arguments[i];
|
|
33396
|
-
for(var key in source)
|
|
33397
|
-
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
33398
|
-
target[key] = source[key];
|
|
33399
|
-
}
|
|
33400
|
-
}
|
|
33875
|
+
for(var key in source)if (Object.prototype.hasOwnProperty.call(source, key)) target[key] = source[key];
|
|
33401
33876
|
}
|
|
33402
33877
|
return target;
|
|
33403
33878
|
};
|
|
33404
|
-
return
|
|
33405
|
-
}
|
|
33406
|
-
function _extends() {
|
|
33407
|
-
return extends_.apply(this, arguments);
|
|
33879
|
+
return _extends.apply(this, arguments);
|
|
33408
33880
|
}
|
|
33409
33881
|
/**
|
|
33410
33882
|
* GL capability.
|
|
@@ -33537,7 +34009,7 @@ function _extends() {
|
|
|
33537
34009
|
TEXTURE_MAX_ANISOTROPY_EXT: "TEXTURE_MAX_ANISOTROPY_EXT"
|
|
33538
34010
|
});
|
|
33539
34011
|
};
|
|
33540
|
-
|
|
34012
|
+
_create_class(GLCapability, [
|
|
33541
34013
|
{
|
|
33542
34014
|
key: "maxTextureSize",
|
|
33543
34015
|
get: function get() {
|
|
@@ -34287,7 +34759,7 @@ function _extends() {
|
|
|
34287
34759
|
}
|
|
34288
34760
|
return true;
|
|
34289
34761
|
};
|
|
34290
|
-
|
|
34762
|
+
_create_class(GLTexture, [
|
|
34291
34763
|
{
|
|
34292
34764
|
key: "wrapModeU",
|
|
34293
34765
|
set: /**
|
|
@@ -35025,7 +35497,7 @@ exports.WebGLMode = void 0;
|
|
|
35025
35497
|
this._gl.flush();
|
|
35026
35498
|
};
|
|
35027
35499
|
_proto.destroy = function destroy() {};
|
|
35028
|
-
|
|
35500
|
+
_create_class(WebGLRenderer, [
|
|
35029
35501
|
{
|
|
35030
35502
|
key: "isWebGL2",
|
|
35031
35503
|
get: function get() {
|
|
@@ -35077,7 +35549,7 @@ exports.WebGLMode = void 0;
|
|
|
35077
35549
|
return Engine.call(this, webCanvas, hardwareRenderer);
|
|
35078
35550
|
};
|
|
35079
35551
|
_inherits(WebGLEngine, Engine);
|
|
35080
|
-
|
|
35552
|
+
_create_class(WebGLEngine, [
|
|
35081
35553
|
{
|
|
35082
35554
|
key: "canvas",
|
|
35083
35555
|
get: /**
|
|
@@ -35094,7 +35566,7 @@ exports.WebGLEngine = WebGLEngine;
|
|
|
35094
35566
|
exports.WebGLRenderer = WebGLRenderer;
|
|
35095
35567
|
|
|
35096
35568
|
var miniprogram$3 = /*#__PURE__*/Object.freeze({
|
|
35097
|
-
|
|
35569
|
+
__proto__: null
|
|
35098
35570
|
});
|
|
35099
35571
|
|
|
35100
35572
|
var CoreObjects = /*@__PURE__*/getAugmentedNamespace(miniprogram$8);
|
|
@@ -35132,7 +35604,7 @@ function _interopNamespace(e) {
|
|
|
35132
35604
|
}
|
|
35133
35605
|
var CoreObjects__namespace = /*#__PURE__*/ _interopNamespace(CoreObjects);
|
|
35134
35606
|
//@ts-ignore
|
|
35135
|
-
var version = "0.9.0
|
|
35607
|
+
var version = "0.9.0";
|
|
35136
35608
|
console.log("Galacean engine version: " + version);
|
|
35137
35609
|
for(var key in CoreObjects__namespace){
|
|
35138
35610
|
CoreObjects.Loader.registerClass(key, CoreObjects__namespace[key]);
|
|
@@ -35235,9 +35707,15 @@ Object.keys(miniprogram$2).forEach(function(k) {
|
|
|
35235
35707
|
};
|
|
35236
35708
|
return PhysXJoint;
|
|
35237
35709
|
}();
|
|
35238
|
-
|
|
35239
|
-
PhysXJoint.
|
|
35240
|
-
|
|
35710
|
+
(function() {
|
|
35711
|
+
PhysXJoint._xAxis = new miniprogram_1.Vector3(1, 0, 0);
|
|
35712
|
+
})();
|
|
35713
|
+
(function() {
|
|
35714
|
+
PhysXJoint._defaultVec = new miniprogram_1.Vector3();
|
|
35715
|
+
})();
|
|
35716
|
+
(function() {
|
|
35717
|
+
PhysXJoint._defaultQuat = new miniprogram_1.Quaternion();
|
|
35718
|
+
})();
|
|
35241
35719
|
|
|
35242
35720
|
/**
|
|
35243
35721
|
* A fixed joint permits no relative movement between two colliders. ie the bodies are glued together.
|
|
@@ -35515,11 +35993,15 @@ var ShapeFlag;
|
|
|
35515
35993
|
};
|
|
35516
35994
|
return PhysXColliderShape;
|
|
35517
35995
|
}();
|
|
35518
|
-
|
|
35519
|
-
PhysXColliderShape.
|
|
35520
|
-
|
|
35521
|
-
|
|
35522
|
-
|
|
35996
|
+
(function() {
|
|
35997
|
+
PhysXColliderShape.halfSqrt = 0.70710678118655;
|
|
35998
|
+
})();
|
|
35999
|
+
(function() {
|
|
36000
|
+
PhysXColliderShape.transform = {
|
|
36001
|
+
translation: new miniprogram_1.Vector3(),
|
|
36002
|
+
rotation: null
|
|
36003
|
+
};
|
|
36004
|
+
})();
|
|
35523
36005
|
|
|
35524
36006
|
/**
|
|
35525
36007
|
* Box collider shape in PhysX.
|
|
@@ -35562,7 +36044,9 @@ PhysXColliderShape.transform = {
|
|
|
35562
36044
|
};
|
|
35563
36045
|
return PhysXBoxColliderShape;
|
|
35564
36046
|
}(PhysXColliderShape);
|
|
35565
|
-
|
|
36047
|
+
(function() {
|
|
36048
|
+
PhysXBoxColliderShape._tempHalfExtents = new miniprogram_1.Vector3();
|
|
36049
|
+
})();
|
|
35566
36050
|
|
|
35567
36051
|
/**
|
|
35568
36052
|
* Capsule collider shape in PhysX.
|
|
@@ -35813,10 +36297,12 @@ var /**
|
|
|
35813
36297
|
};
|
|
35814
36298
|
return PhysXCollider;
|
|
35815
36299
|
}();
|
|
35816
|
-
|
|
35817
|
-
|
|
35818
|
-
|
|
35819
|
-
|
|
36300
|
+
(function() {
|
|
36301
|
+
PhysXCollider._tempTransform = {
|
|
36302
|
+
translation: null,
|
|
36303
|
+
rotation: null
|
|
36304
|
+
};
|
|
36305
|
+
})();
|
|
35820
36306
|
|
|
35821
36307
|
var CollisionDetectionMode;
|
|
35822
36308
|
(function(CollisionDetectionMode) {
|
|
@@ -35973,8 +36459,12 @@ var CollisionDetectionMode;
|
|
|
35973
36459
|
};
|
|
35974
36460
|
return PhysXDynamicCollider;
|
|
35975
36461
|
}(PhysXCollider);
|
|
35976
|
-
|
|
35977
|
-
PhysXDynamicCollider.
|
|
36462
|
+
(function() {
|
|
36463
|
+
PhysXDynamicCollider._tempTranslation = new miniprogram_1.Vector3();
|
|
36464
|
+
})();
|
|
36465
|
+
(function() {
|
|
36466
|
+
PhysXDynamicCollider._tempRotation = new miniprogram_1.Quaternion();
|
|
36467
|
+
})();
|
|
35978
36468
|
|
|
35979
36469
|
/**
|
|
35980
36470
|
* A manager is a collection of colliders and constraints which can interact.
|
|
@@ -36175,8 +36665,12 @@ PhysXDynamicCollider._tempRotation = new miniprogram_1.Quaternion();
|
|
|
36175
36665
|
};
|
|
36176
36666
|
return PhysXPhysicsManager;
|
|
36177
36667
|
}();
|
|
36178
|
-
|
|
36179
|
-
PhysXPhysicsManager.
|
|
36668
|
+
(function() {
|
|
36669
|
+
PhysXPhysicsManager._tempPosition = new miniprogram_1.Vector3();
|
|
36670
|
+
})();
|
|
36671
|
+
(function() {
|
|
36672
|
+
PhysXPhysicsManager._tempNormal = new miniprogram_1.Vector3();
|
|
36673
|
+
})();
|
|
36180
36674
|
var /**
|
|
36181
36675
|
* Filtering flags for scene queries.
|
|
36182
36676
|
*/ QueryFlag;
|