@galacean/effects-core 2.1.5 → 2.2.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/index.js +457 -505
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +457 -506
- package/dist/index.mjs.map +1 -1
- package/dist/math/value-getters/value-getter.d.ts +4 -0
- package/dist/plugins/cal/animation-stream.d.ts +1 -2
- package/dist/plugins/cal/playable-graph.d.ts +1 -30
- package/dist/plugins/text/text-layout.d.ts +1 -1
- package/dist/plugins/timeline/playables/activation-mixer-playable.d.ts +3 -3
- package/dist/plugins/timeline/playables/color-property-mixer-playable.d.ts +3 -3
- package/dist/plugins/timeline/playables/float-property-mixer-playable.d.ts +3 -3
- package/dist/plugins/timeline/playables/index.d.ts +6 -2
- package/dist/plugins/timeline/playables/particle-mixer-playable.d.ts +5 -0
- package/dist/plugins/timeline/playables/sprite-color-mixer-playable.d.ts +5 -0
- package/dist/plugins/timeline/playables/sub-composition-mixer-playable.d.ts +3 -3
- package/dist/plugins/timeline/playables/track-mixer-playable.d.ts +12 -0
- package/dist/plugins/timeline/playables/transform-mixer-playable.d.ts +5 -0
- package/dist/plugins/timeline/playables/vector4-property-mixer-playable.d.ts +3 -3
- package/dist/plugins/timeline/track.d.ts +7 -6
- package/dist/plugins/timeline/tracks/activation-track.d.ts +3 -2
- package/dist/plugins/timeline/tracks/color-property-track.d.ts +3 -2
- package/dist/plugins/timeline/tracks/float-property-track.d.ts +3 -2
- package/dist/plugins/timeline/tracks/index.d.ts +1 -0
- package/dist/plugins/timeline/tracks/particle-track.d.ts +6 -0
- package/dist/plugins/timeline/tracks/property-track.d.ts +1 -1
- package/dist/plugins/timeline/tracks/sprite-color-track.d.ts +3 -0
- package/dist/plugins/timeline/tracks/sub-composition-track.d.ts +3 -2
- package/dist/plugins/timeline/tracks/transform-track.d.ts +3 -0
- package/dist/plugins/timeline/tracks/vector4-property-track.d.ts +3 -2
- package/dist/scene.d.ts +12 -0
- package/dist/vfx-item.d.ts +1 -2
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Description: Galacean Effects runtime core for the web
|
|
4
4
|
* Author: Ant Group CO., Ltd.
|
|
5
5
|
* Contributors: 燃然,飂兮,十弦,云垣,茂安,意绮
|
|
6
|
-
* Version: v2.
|
|
6
|
+
* Version: v2.2.0
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
|
|
@@ -59,12 +59,8 @@ function __generator(thisArg, body) {
|
|
|
59
59
|
},
|
|
60
60
|
trys: [],
|
|
61
61
|
ops: []
|
|
62
|
-
}, f, y, t, g;
|
|
63
|
-
return g = {
|
|
64
|
-
next: verb(0),
|
|
65
|
-
"throw": verb(1),
|
|
66
|
-
"return": verb(2)
|
|
67
|
-
}, typeof Symbol === "function" && (g[Symbol.iterator] = function() {
|
|
62
|
+
}, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
|
|
63
|
+
return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() {
|
|
68
64
|
return this;
|
|
69
65
|
}), g;
|
|
70
66
|
function verb(n) {
|
|
@@ -12752,8 +12748,8 @@ var BezierCurve = /*#__PURE__*/ function(ValueGetter) {
|
|
|
12752
12748
|
return data;
|
|
12753
12749
|
};
|
|
12754
12750
|
_proto.getMaxTime = function getMaxTime() {
|
|
12755
|
-
var keyTimeData =
|
|
12756
|
-
return
|
|
12751
|
+
var keyTimeData = this.keyTimeData;
|
|
12752
|
+
return this.curveMap[keyTimeData[keyTimeData.length - 1]].timeEnd;
|
|
12757
12753
|
};
|
|
12758
12754
|
return BezierCurve;
|
|
12759
12755
|
}(ValueGetter);
|
|
@@ -12831,19 +12827,22 @@ var BezierCurvePath = /*#__PURE__*/ function(ValueGetter) {
|
|
|
12831
12827
|
timeInterval: timeInterval,
|
|
12832
12828
|
valueInterval: valueInterval,
|
|
12833
12829
|
easingCurve: easingCurve,
|
|
12834
|
-
pathCurve: pathCurve
|
|
12830
|
+
pathCurve: pathCurve,
|
|
12831
|
+
timeStart: Number(s.x),
|
|
12832
|
+
timeEnd: Number(e.x)
|
|
12835
12833
|
};
|
|
12836
12834
|
}
|
|
12835
|
+
this.keyTimeData = Object.keys(this.curveSegments);
|
|
12837
12836
|
};
|
|
12838
12837
|
_proto.getValue = function getValue(time) {
|
|
12839
12838
|
var t = numberToFix(time, 5);
|
|
12840
12839
|
var perc = 0, point = new Vector3();
|
|
12841
|
-
var keyTimeData =
|
|
12840
|
+
var keyTimeData = this.keyTimeData;
|
|
12842
12841
|
if (!keyTimeData.length) {
|
|
12843
12842
|
return point;
|
|
12844
12843
|
}
|
|
12845
|
-
var keyTimeStart =
|
|
12846
|
-
var keyTimeEnd =
|
|
12844
|
+
var keyTimeStart = this.curveSegments[keyTimeData[0]].timeStart;
|
|
12845
|
+
var keyTimeEnd = this.curveSegments[keyTimeData[keyTimeData.length - 1]].timeEnd;
|
|
12847
12846
|
if (t <= keyTimeStart) {
|
|
12848
12847
|
var pathCurve = this.curveSegments[keyTimeData[0]].pathCurve;
|
|
12849
12848
|
point = pathCurve.getPointInPercent(0);
|
|
@@ -12855,7 +12854,8 @@ var BezierCurvePath = /*#__PURE__*/ function(ValueGetter) {
|
|
|
12855
12854
|
return point;
|
|
12856
12855
|
}
|
|
12857
12856
|
for(var i = 0; i < keyTimeData.length; i++){
|
|
12858
|
-
var
|
|
12857
|
+
var xMin = this.curveSegments[keyTimeData[i]].timeStart;
|
|
12858
|
+
var xMax = this.curveSegments[keyTimeData[i]].timeEnd;
|
|
12859
12859
|
if (t >= Number(xMin) && t < Number(xMax)) {
|
|
12860
12860
|
var bezierPath = this.curveSegments[keyTimeData[i]].pathCurve;
|
|
12861
12861
|
perc = this.getPercValue(keyTimeData[i], t);
|
|
@@ -12874,8 +12874,8 @@ var BezierCurvePath = /*#__PURE__*/ function(ValueGetter) {
|
|
|
12874
12874
|
return clamp$1(value, 0, 1);
|
|
12875
12875
|
};
|
|
12876
12876
|
_proto.getMaxTime = function getMaxTime() {
|
|
12877
|
-
var keyTimeData =
|
|
12878
|
-
return
|
|
12877
|
+
var keyTimeData = this.keyTimeData;
|
|
12878
|
+
return this.curveSegments[keyTimeData[keyTimeData.length - 1]].timeEnd;
|
|
12879
12879
|
};
|
|
12880
12880
|
return BezierCurvePath;
|
|
12881
12881
|
}(ValueGetter);
|
|
@@ -13028,15 +13028,18 @@ function createKeyFrameMeta() {
|
|
|
13028
13028
|
}
|
|
13029
13029
|
|
|
13030
13030
|
function _is_native_reflect_construct() {
|
|
13031
|
-
|
|
13032
|
-
|
|
13033
|
-
|
|
13031
|
+
// Since Reflect.construct can't be properly polyfilled, some
|
|
13032
|
+
// implementations (e.g. core-js@2) don't set the correct internal slots.
|
|
13033
|
+
// Those polyfills don't allow us to subclass built-ins, so we need to
|
|
13034
|
+
// use our fallback implementation.
|
|
13034
13035
|
try {
|
|
13035
|
-
|
|
13036
|
-
|
|
13037
|
-
|
|
13038
|
-
|
|
13039
|
-
|
|
13036
|
+
// If the internal slots aren't set, this throws an error similar to
|
|
13037
|
+
// TypeError: this is not a Boolean object.
|
|
13038
|
+
var result = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {}));
|
|
13039
|
+
} catch (_) {}
|
|
13040
|
+
return (_is_native_reflect_construct = function _is_native_reflect_construct() {
|
|
13041
|
+
return !!result;
|
|
13042
|
+
})();
|
|
13040
13043
|
}
|
|
13041
13044
|
|
|
13042
13045
|
function _construct(Parent, args, Class) {
|
|
@@ -15900,6 +15903,7 @@ var ShapeComponent = /*#__PURE__*/ function(MeshComponent) {
|
|
|
15900
15903
|
if (this.animated) {
|
|
15901
15904
|
this.buildPath(this.data);
|
|
15902
15905
|
this.buildGeometryFromPath(this.path.shapePath);
|
|
15906
|
+
this.animated = false;
|
|
15903
15907
|
}
|
|
15904
15908
|
};
|
|
15905
15909
|
_proto.buildGeometryFromPath = function buildGeometryFromPath(shapePath) {
|
|
@@ -17007,14 +17011,10 @@ var SpriteLoader = /*#__PURE__*/ function(AbstractPlugin) {
|
|
|
17007
17011
|
var playableOutput2 = _step2.value;
|
|
17008
17012
|
this.processFrameWithRoot(playableOutput2);
|
|
17009
17013
|
}
|
|
17010
|
-
|
|
17011
|
-
|
|
17012
|
-
|
|
17013
|
-
|
|
17014
|
-
}
|
|
17015
|
-
};
|
|
17016
|
-
_proto.connect = function connect(source, sourceOutputPort, destination, destinationInputPort) {
|
|
17017
|
-
destination.connectInput(destinationInputPort, source, sourceOutputPort);
|
|
17014
|
+
// 更新节点时间
|
|
17015
|
+
// for (const playable of this.playables) {
|
|
17016
|
+
// this.updatePlayableTime(playable, dt / 1000);
|
|
17017
|
+
// }
|
|
17018
17018
|
};
|
|
17019
17019
|
_proto.addOutput = function addOutput(output) {
|
|
17020
17020
|
this.playableOutputs.push(output);
|
|
@@ -17023,12 +17023,12 @@ var SpriteLoader = /*#__PURE__*/ function(AbstractPlugin) {
|
|
|
17023
17023
|
this.playables.push(playable);
|
|
17024
17024
|
};
|
|
17025
17025
|
_proto.processFrameWithRoot = function processFrameWithRoot(output) {
|
|
17026
|
-
output.sourcePlayable.
|
|
17026
|
+
output.sourcePlayable.processFrame(output.context);
|
|
17027
17027
|
output.processFrame();
|
|
17028
17028
|
};
|
|
17029
17029
|
_proto.prepareFrameWithRoot = function prepareFrameWithRoot(output) {
|
|
17030
|
-
output.sourcePlayable.prepareFrameRecursive(output.context, output.getSourceOutputPort());
|
|
17031
17030
|
output.prepareFrame();
|
|
17031
|
+
output.sourcePlayable.prepareFrame(output.context);
|
|
17032
17032
|
};
|
|
17033
17033
|
_proto.updatePlayableTime = function updatePlayableTime(playable, deltaTime) {
|
|
17034
17034
|
if (playable.getPlayState() !== 0) {
|
|
@@ -17043,24 +17043,15 @@ var SpriteLoader = /*#__PURE__*/ function(AbstractPlugin) {
|
|
|
17043
17043
|
* @since 2.0.0
|
|
17044
17044
|
*/ var Playable = /*#__PURE__*/ function() {
|
|
17045
17045
|
function Playable(graph, inputCount) {
|
|
17046
|
-
if (inputCount === void 0) inputCount = 0;
|
|
17047
17046
|
this.onPlayablePlayFlag = true;
|
|
17048
17047
|
this.onPlayablePauseFlag = false;
|
|
17049
17048
|
this.duration = 0;
|
|
17050
17049
|
this.destroyed = false;
|
|
17051
|
-
this.inputs = [];
|
|
17052
|
-
this.inputOuputPorts = [];
|
|
17053
|
-
this.inputWeight = [];
|
|
17054
|
-
this.outputs = [];
|
|
17055
17050
|
this.playState = 0;
|
|
17056
|
-
this.traversalMode = 0;
|
|
17057
17051
|
/**
|
|
17058
17052
|
* 当前本地播放的时间
|
|
17059
17053
|
*/ this.time = 0;
|
|
17060
17054
|
graph.addPlayable(this);
|
|
17061
|
-
this.inputs = new Array(inputCount);
|
|
17062
|
-
this.inputOuputPorts = new Array(inputCount);
|
|
17063
|
-
this.inputWeight = new Array(inputCount);
|
|
17064
17055
|
}
|
|
17065
17056
|
var _proto = Playable.prototype;
|
|
17066
17057
|
_proto.play = function play() {
|
|
@@ -17083,56 +17074,6 @@ var SpriteLoader = /*#__PURE__*/ function(AbstractPlugin) {
|
|
|
17083
17074
|
break;
|
|
17084
17075
|
}
|
|
17085
17076
|
};
|
|
17086
|
-
_proto.connectInput = function connectInput(inputPort, sourcePlayable, sourceOutputPort, weight) {
|
|
17087
|
-
if (weight === void 0) weight = 1.0;
|
|
17088
|
-
this.setInput(sourcePlayable, inputPort);
|
|
17089
|
-
this.setInputWeight(inputPort, weight);
|
|
17090
|
-
sourcePlayable.setOutput(this, sourceOutputPort);
|
|
17091
|
-
if (this.inputOuputPorts.length < inputPort + 1) {
|
|
17092
|
-
this.inputOuputPorts.length = inputPort + 1;
|
|
17093
|
-
}
|
|
17094
|
-
this.inputOuputPorts[inputPort] = sourceOutputPort;
|
|
17095
|
-
};
|
|
17096
|
-
_proto.addInput = function addInput(sourcePlayable, sourceOutputPort, weight) {
|
|
17097
|
-
if (weight === void 0) weight = 1.0;
|
|
17098
|
-
this.connectInput(this.getInputCount(), sourcePlayable, sourceOutputPort, weight);
|
|
17099
|
-
};
|
|
17100
|
-
_proto.getInputCount = function getInputCount() {
|
|
17101
|
-
return this.inputs.length;
|
|
17102
|
-
};
|
|
17103
|
-
_proto.getInputs = function getInputs() {
|
|
17104
|
-
return this.inputs;
|
|
17105
|
-
};
|
|
17106
|
-
_proto.getInput = function getInput(index) {
|
|
17107
|
-
return this.inputs[index];
|
|
17108
|
-
};
|
|
17109
|
-
_proto.getOutputCount = function getOutputCount() {
|
|
17110
|
-
return this.outputs.length;
|
|
17111
|
-
};
|
|
17112
|
-
_proto.getOutputs = function getOutputs() {
|
|
17113
|
-
return this.outputs;
|
|
17114
|
-
};
|
|
17115
|
-
_proto.getOutput = function getOutput(index) {
|
|
17116
|
-
return this.outputs[index];
|
|
17117
|
-
};
|
|
17118
|
-
_proto.getInputWeight = function getInputWeight(inputIndex) {
|
|
17119
|
-
return this.inputWeight[inputIndex];
|
|
17120
|
-
};
|
|
17121
|
-
_proto.setInputWeight = function setInputWeight(playableOrIndex, weight) {
|
|
17122
|
-
if (_instanceof1(playableOrIndex, Playable)) {
|
|
17123
|
-
for(var i = 0; i < this.inputs.length; i++){
|
|
17124
|
-
if (this.inputs[i] === playableOrIndex) {
|
|
17125
|
-
this.inputWeight[i] = weight;
|
|
17126
|
-
return;
|
|
17127
|
-
}
|
|
17128
|
-
}
|
|
17129
|
-
} else {
|
|
17130
|
-
if (this.inputWeight.length < playableOrIndex + 1) {
|
|
17131
|
-
this.inputWeight.length = playableOrIndex + 1;
|
|
17132
|
-
}
|
|
17133
|
-
this.inputWeight[playableOrIndex] = weight;
|
|
17134
|
-
}
|
|
17135
|
-
};
|
|
17136
17077
|
_proto.setTime = function setTime(time) {
|
|
17137
17078
|
this.time = time;
|
|
17138
17079
|
};
|
|
@@ -17148,18 +17089,14 @@ var SpriteLoader = /*#__PURE__*/ function(AbstractPlugin) {
|
|
|
17148
17089
|
_proto.getPlayState = function getPlayState() {
|
|
17149
17090
|
return this.playState;
|
|
17150
17091
|
};
|
|
17151
|
-
_proto.setTraversalMode = function setTraversalMode(mode) {
|
|
17152
|
-
this.traversalMode = mode;
|
|
17153
|
-
};
|
|
17154
|
-
_proto.getTraversalMode = function getTraversalMode() {
|
|
17155
|
-
return this.traversalMode;
|
|
17156
|
-
};
|
|
17157
17092
|
// onGraphStart () {
|
|
17158
17093
|
// }
|
|
17159
17094
|
// onGraphStop () {
|
|
17160
17095
|
// }
|
|
17161
|
-
|
|
17162
|
-
|
|
17096
|
+
// onPlayablePlay (context: FrameContext) {
|
|
17097
|
+
// }
|
|
17098
|
+
// onPlayablePause (context: FrameContext) {
|
|
17099
|
+
// }
|
|
17163
17100
|
_proto.prepareFrame = function prepareFrame(context) {};
|
|
17164
17101
|
_proto.processFrame = function processFrame(context) {};
|
|
17165
17102
|
_proto.onPlayableDestroy = function onPlayableDestroy() {};
|
|
@@ -17171,76 +17108,6 @@ var SpriteLoader = /*#__PURE__*/ function(AbstractPlugin) {
|
|
|
17171
17108
|
// TODO 将节点从动画图中移除
|
|
17172
17109
|
this.destroyed = true;
|
|
17173
17110
|
};
|
|
17174
|
-
/**
|
|
17175
|
-
* @internal
|
|
17176
|
-
*/ _proto.prepareFrameRecursive = function prepareFrameRecursive(context, passthroughPort) {
|
|
17177
|
-
if (this.destroyed || this.playState !== 0) {
|
|
17178
|
-
return;
|
|
17179
|
-
}
|
|
17180
|
-
if (this.onPlayablePlayFlag) {
|
|
17181
|
-
this.onPlayablePlay(context);
|
|
17182
|
-
this.onPlayablePlayFlag = false;
|
|
17183
|
-
}
|
|
17184
|
-
if (this.onPlayablePauseFlag) {
|
|
17185
|
-
this.onPlayablePause(context);
|
|
17186
|
-
this.onPlayablePauseFlag = false;
|
|
17187
|
-
}
|
|
17188
|
-
if (passthroughPort === 0) {
|
|
17189
|
-
this.prepareFrame(context);
|
|
17190
|
-
}
|
|
17191
|
-
// 前序遍历,用于设置节点的初始状态,weight etc.
|
|
17192
|
-
switch(this.getTraversalMode()){
|
|
17193
|
-
case 0:
|
|
17194
|
-
for(var i = 0; i < this.getInputCount(); i++){
|
|
17195
|
-
var input = this.getInput(i);
|
|
17196
|
-
input.prepareFrameRecursive(context, this.inputOuputPorts[i]);
|
|
17197
|
-
}
|
|
17198
|
-
break;
|
|
17199
|
-
case 1:
|
|
17200
|
-
{
|
|
17201
|
-
var input1 = this.getInput(passthroughPort);
|
|
17202
|
-
input1.prepareFrameRecursive(context, this.inputOuputPorts[passthroughPort]);
|
|
17203
|
-
break;
|
|
17204
|
-
}
|
|
17205
|
-
}
|
|
17206
|
-
};
|
|
17207
|
-
/**
|
|
17208
|
-
* @internal
|
|
17209
|
-
*/ _proto.processFrameRecursive = function processFrameRecursive(context, passthroughPort) {
|
|
17210
|
-
if (this.destroyed || this.playState !== 0) {
|
|
17211
|
-
return;
|
|
17212
|
-
}
|
|
17213
|
-
// 后序遍历,保证 playable 拿到的 input 节点的估计数据是最新的
|
|
17214
|
-
switch(this.getTraversalMode()){
|
|
17215
|
-
case 0:
|
|
17216
|
-
{
|
|
17217
|
-
for(var i = 0; i < this.getInputCount(); i++){
|
|
17218
|
-
var input = this.getInput(i);
|
|
17219
|
-
input.processFrameRecursive(context, this.inputOuputPorts[i]);
|
|
17220
|
-
}
|
|
17221
|
-
break;
|
|
17222
|
-
}
|
|
17223
|
-
case 1:
|
|
17224
|
-
{
|
|
17225
|
-
var input1 = this.getInput(passthroughPort);
|
|
17226
|
-
input1.processFrameRecursive(context, this.inputOuputPorts[passthroughPort]);
|
|
17227
|
-
break;
|
|
17228
|
-
}
|
|
17229
|
-
}
|
|
17230
|
-
this.processFrame(context);
|
|
17231
|
-
};
|
|
17232
|
-
_proto.setOutput = function setOutput(outputPlayable, outputPort) {
|
|
17233
|
-
if (this.outputs.length < outputPort + 1) {
|
|
17234
|
-
this.outputs.length = outputPort + 1;
|
|
17235
|
-
}
|
|
17236
|
-
this.outputs[outputPort] = outputPlayable;
|
|
17237
|
-
};
|
|
17238
|
-
_proto.setInput = function setInput(inputPlayable, inputPort) {
|
|
17239
|
-
if (this.inputs.length < inputPort + 1) {
|
|
17240
|
-
this.inputs.length = inputPort + 1;
|
|
17241
|
-
}
|
|
17242
|
-
this.inputs[inputPort] = inputPlayable;
|
|
17243
|
-
};
|
|
17244
17111
|
return Playable;
|
|
17245
17112
|
}();
|
|
17246
17113
|
/**
|
|
@@ -17248,20 +17115,14 @@ var SpriteLoader = /*#__PURE__*/ function(AbstractPlugin) {
|
|
|
17248
17115
|
* @since 2.0.0
|
|
17249
17116
|
*/ var PlayableOutput = /*#__PURE__*/ function() {
|
|
17250
17117
|
function PlayableOutput() {
|
|
17251
|
-
this.sourceOutputPort = 0;
|
|
17252
17118
|
this.context = {
|
|
17253
17119
|
deltaTime: 0,
|
|
17254
17120
|
output: this
|
|
17255
17121
|
};
|
|
17256
17122
|
}
|
|
17257
17123
|
var _proto = PlayableOutput.prototype;
|
|
17258
|
-
_proto.setSourcePlayable = function setSourcePlayable(playable
|
|
17259
|
-
if (port === void 0) port = 0;
|
|
17124
|
+
_proto.setSourcePlayable = function setSourcePlayable(playable) {
|
|
17260
17125
|
this.sourcePlayable = playable;
|
|
17261
|
-
this.sourceOutputPort = port;
|
|
17262
|
-
};
|
|
17263
|
-
_proto.getSourceOutputPort = function getSourceOutputPort() {
|
|
17264
|
-
return this.sourceOutputPort;
|
|
17265
17126
|
};
|
|
17266
17127
|
_proto.setUserData = function setUserData(value) {
|
|
17267
17128
|
this.userData = value;
|
|
@@ -17287,11 +17148,6 @@ var PlayState;
|
|
|
17287
17148
|
PlayState[PlayState["Playing"] = 0] = "Playing";
|
|
17288
17149
|
PlayState[PlayState["Paused"] = 1] = "Paused";
|
|
17289
17150
|
})(PlayState || (PlayState = {}));
|
|
17290
|
-
var PlayableTraversalMode;
|
|
17291
|
-
(function(PlayableTraversalMode) {
|
|
17292
|
-
PlayableTraversalMode[PlayableTraversalMode["Mix"] = 0] = "Mix";
|
|
17293
|
-
PlayableTraversalMode[PlayableTraversalMode["Passthrough"] = 1] = "Passthrough";
|
|
17294
|
-
})(PlayableTraversalMode || (PlayableTraversalMode = {}));
|
|
17295
17151
|
|
|
17296
17152
|
var tempQuat$1 = new Quaternion();
|
|
17297
17153
|
var seed$3 = 1;
|
|
@@ -17944,7 +17800,7 @@ var VFXItem = /*#__PURE__*/ function(EffectsObject) {
|
|
|
17944
17800
|
};
|
|
17945
17801
|
/**
|
|
17946
17802
|
* 添加组件
|
|
17947
|
-
* @param classConstructor -
|
|
17803
|
+
* @param classConstructor - 要添加的组件
|
|
17948
17804
|
*/ _proto.addComponent = function addComponent(classConstructor) {
|
|
17949
17805
|
var newComponent = new classConstructor(this.engine);
|
|
17950
17806
|
this.components.push(newComponent);
|
|
@@ -18187,7 +18043,7 @@ var VFXItem = /*#__PURE__*/ function(EffectsObject) {
|
|
|
18187
18043
|
};
|
|
18188
18044
|
_proto.fromData = function fromData(data) {
|
|
18189
18045
|
EffectsObject.prototype.fromData.call(this, data);
|
|
18190
|
-
var id = data.id, name = data.name, delay = data.delay, parentId = data.parentId, endBehavior = data.endBehavior, transform = data.transform,
|
|
18046
|
+
var id = data.id, name = data.name, delay = data.delay, parentId = data.parentId, endBehavior = data.endBehavior, transform = data.transform, _data_duration = data.duration, duration = _data_duration === void 0 ? 0 : _data_duration;
|
|
18191
18047
|
this.props = data;
|
|
18192
18048
|
//@ts-expect-error
|
|
18193
18049
|
this.type = data.type;
|
|
@@ -18249,8 +18105,6 @@ var VFXItem = /*#__PURE__*/ function(EffectsObject) {
|
|
|
18249
18105
|
this.rendererComponents.push(component.renderer);
|
|
18250
18106
|
}
|
|
18251
18107
|
}
|
|
18252
|
-
// renderOrder 在 component 初始化后设置。确保能拿到 rendererComponent。
|
|
18253
|
-
this.renderOrder = listIndex;
|
|
18254
18108
|
};
|
|
18255
18109
|
_proto.toData = function toData() {
|
|
18256
18110
|
var _this_parent;
|
|
@@ -22796,12 +22650,6 @@ var AnimationStream = /*#__PURE__*/ function() {
|
|
|
22796
22650
|
_proto.findCurveValue = function findCurveValue(componentType, propertyName) {
|
|
22797
22651
|
return this.curveValues[componentType + propertyName];
|
|
22798
22652
|
};
|
|
22799
|
-
_proto.getInputStream = function getInputStream(index) {
|
|
22800
|
-
var inputPlayable = this.playable.getInput(index);
|
|
22801
|
-
if (_instanceof1(inputPlayable, AnimationPlayable)) {
|
|
22802
|
-
return inputPlayable.animationStream;
|
|
22803
|
-
}
|
|
22804
|
-
};
|
|
22805
22653
|
return AnimationStream;
|
|
22806
22654
|
}();
|
|
22807
22655
|
|
|
@@ -23136,266 +22984,147 @@ var AnimationClipPlayable = /*#__PURE__*/ function(Playable) {
|
|
|
23136
22984
|
return AnimationClipPlayable;
|
|
23137
22985
|
}(Playable);
|
|
23138
22986
|
|
|
23139
|
-
|
|
23140
|
-
|
|
23141
|
-
|
|
23142
|
-
function TimelineClip() {
|
|
23143
|
-
this.start = 0;
|
|
23144
|
-
this.duration = 0;
|
|
23145
|
-
}
|
|
23146
|
-
var _proto = TimelineClip.prototype;
|
|
23147
|
-
_proto.toLocalTime = function toLocalTime(time) {
|
|
23148
|
-
var localTime = time - this.start;
|
|
23149
|
-
var duration = this.duration;
|
|
23150
|
-
if (localTime - duration > 0) {
|
|
23151
|
-
if (this.endBehavior === EndBehavior.restart) {
|
|
23152
|
-
localTime = localTime % duration;
|
|
23153
|
-
} else if (this.endBehavior === EndBehavior.freeze) {
|
|
23154
|
-
localTime = Math.min(duration, localTime);
|
|
23155
|
-
}
|
|
23156
|
-
}
|
|
23157
|
-
return localTime;
|
|
23158
|
-
};
|
|
23159
|
-
return TimelineClip;
|
|
23160
|
-
}();
|
|
23161
|
-
var TrackAsset = /*#__PURE__*/ function(PlayableAsset) {
|
|
23162
|
-
_inherits(TrackAsset, PlayableAsset);
|
|
23163
|
-
function TrackAsset() {
|
|
22987
|
+
var TrackMixerPlayable = /*#__PURE__*/ function(Playable1) {
|
|
22988
|
+
_inherits(TrackMixerPlayable, Playable1);
|
|
22989
|
+
function TrackMixerPlayable() {
|
|
23164
22990
|
var _this;
|
|
23165
|
-
_this =
|
|
23166
|
-
_this.
|
|
23167
|
-
_this.
|
|
23168
|
-
_this.clips = [];
|
|
23169
|
-
_this.children = [];
|
|
22991
|
+
_this = Playable1.apply(this, arguments) || this;
|
|
22992
|
+
_this.clipPlayables = [];
|
|
22993
|
+
_this.clipWeights = [];
|
|
23170
22994
|
return _this;
|
|
23171
22995
|
}
|
|
23172
|
-
var _proto =
|
|
23173
|
-
|
|
23174
|
-
|
|
23175
|
-
|
|
23176
|
-
|
|
23177
|
-
this.boundObject = this.parent.boundObject;
|
|
23178
|
-
}
|
|
23179
|
-
};
|
|
23180
|
-
/**
|
|
23181
|
-
* 重写该方法以创建自定义混合器
|
|
23182
|
-
*/ _proto.createTrackMixer = function createTrackMixer(graph) {
|
|
23183
|
-
return new Playable(graph);
|
|
23184
|
-
};
|
|
23185
|
-
_proto.createOutput = function createOutput() {
|
|
23186
|
-
var output = new PlayableOutput();
|
|
23187
|
-
return output;
|
|
23188
|
-
};
|
|
23189
|
-
_proto.createPlayableGraph = function createPlayableGraph(graph, runtimeClips) {
|
|
23190
|
-
var mixerPlayable = this.createMixerPlayableGraph(graph, runtimeClips);
|
|
23191
|
-
return mixerPlayable;
|
|
23192
|
-
};
|
|
23193
|
-
_proto.createMixerPlayableGraph = function createMixerPlayableGraph(graph, runtimeClips) {
|
|
23194
|
-
var clips = [];
|
|
23195
|
-
for(var _iterator = _create_for_of_iterator_helper_loose(this.clips), _step; !(_step = _iterator()).done;){
|
|
23196
|
-
var clip = _step.value;
|
|
23197
|
-
clips.push(clip);
|
|
22996
|
+
var _proto = TrackMixerPlayable.prototype;
|
|
22997
|
+
_proto.processFrame = function processFrame(context) {
|
|
22998
|
+
for(var _iterator = _create_for_of_iterator_helper_loose(this.clipPlayables), _step; !(_step = _iterator()).done;){
|
|
22999
|
+
var clipPlayable = _step.value;
|
|
23000
|
+
clipPlayable.processFrame(context);
|
|
23198
23001
|
}
|
|
23199
|
-
|
|
23200
|
-
return mixerPlayable;
|
|
23002
|
+
this.evaluate(context);
|
|
23201
23003
|
};
|
|
23202
|
-
_proto.
|
|
23203
|
-
|
|
23204
|
-
|
|
23205
|
-
|
|
23206
|
-
|
|
23207
|
-
|
|
23208
|
-
|
|
23209
|
-
|
|
23210
|
-
|
|
23211
|
-
|
|
23004
|
+
_proto.setClipWeight = function setClipWeight(playableOrIndex, weight) {
|
|
23005
|
+
if (_instanceof1(playableOrIndex, Playable)) {
|
|
23006
|
+
for(var i = 0; i < this.clipPlayables.length; i++){
|
|
23007
|
+
if (this.clipPlayables[i] === playableOrIndex) {
|
|
23008
|
+
this.clipWeights[i] = weight;
|
|
23009
|
+
return;
|
|
23010
|
+
}
|
|
23011
|
+
}
|
|
23012
|
+
} else {
|
|
23013
|
+
if (this.clipWeights.length < playableOrIndex + 1) {
|
|
23014
|
+
this.clipWeights.length = playableOrIndex + 1;
|
|
23015
|
+
}
|
|
23016
|
+
this.clipWeights[playableOrIndex] = weight;
|
|
23212
23017
|
}
|
|
23213
|
-
return mixer;
|
|
23214
|
-
};
|
|
23215
|
-
_proto.createPlayable = function createPlayable(graph) {
|
|
23216
|
-
return new Playable(graph);
|
|
23217
|
-
};
|
|
23218
|
-
_proto.getChildTracks = function getChildTracks() {
|
|
23219
|
-
return this.children;
|
|
23220
23018
|
};
|
|
23221
|
-
_proto.
|
|
23222
|
-
this.
|
|
23223
|
-
child.parent = this;
|
|
23019
|
+
_proto.getClipWeight = function getClipWeight(inputIndex) {
|
|
23020
|
+
return this.clipWeights[inputIndex];
|
|
23224
23021
|
};
|
|
23225
|
-
_proto.
|
|
23226
|
-
|
|
23227
|
-
newClip.asset = new classConstructor(this.engine);
|
|
23228
|
-
newClip.name = name ? name : "TimelineClip" + newClip.id;
|
|
23229
|
-
this.addClip(newClip);
|
|
23230
|
-
return newClip;
|
|
23022
|
+
_proto.getClipPlayable = function getClipPlayable(index) {
|
|
23023
|
+
return this.clipPlayables[index];
|
|
23231
23024
|
};
|
|
23232
|
-
_proto.
|
|
23233
|
-
|
|
23025
|
+
_proto.evaluate = function evaluate(context) {
|
|
23026
|
+
// Override
|
|
23234
23027
|
};
|
|
23235
|
-
|
|
23236
|
-
|
|
23237
|
-
|
|
23238
|
-
|
|
23239
|
-
|
|
23028
|
+
return TrackMixerPlayable;
|
|
23029
|
+
}(Playable);
|
|
23030
|
+
|
|
23031
|
+
var ActivationMixerPlayable = /*#__PURE__*/ function(TrackMixerPlayable) {
|
|
23032
|
+
_inherits(ActivationMixerPlayable, TrackMixerPlayable);
|
|
23033
|
+
function ActivationMixerPlayable() {
|
|
23034
|
+
return TrackMixerPlayable.apply(this, arguments);
|
|
23035
|
+
}
|
|
23036
|
+
var _proto = ActivationMixerPlayable.prototype;
|
|
23037
|
+
_proto.evaluate = function evaluate(context) {
|
|
23038
|
+
var boundObject = context.output.getUserData();
|
|
23039
|
+
if (!_instanceof1(boundObject, VFXItem)) {
|
|
23040
|
+
return;
|
|
23041
|
+
}
|
|
23042
|
+
var boundItem = boundObject;
|
|
23043
|
+
var hasInput = false;
|
|
23044
|
+
for(var i = 0; i < this.clipPlayables.length; i++){
|
|
23045
|
+
if (this.getClipWeight(i) > 0) {
|
|
23046
|
+
hasInput = true;
|
|
23047
|
+
break;
|
|
23240
23048
|
}
|
|
23241
23049
|
}
|
|
23050
|
+
if (hasInput) {
|
|
23051
|
+
boundItem.transform.setValid(true);
|
|
23052
|
+
boundItem.setActive(true);
|
|
23053
|
+
} else {
|
|
23054
|
+
boundItem.transform.setValid(false);
|
|
23055
|
+
boundItem.setActive(false);
|
|
23056
|
+
}
|
|
23242
23057
|
};
|
|
23243
|
-
|
|
23244
|
-
|
|
23245
|
-
|
|
23246
|
-
|
|
23247
|
-
|
|
23248
|
-
|
|
23058
|
+
return ActivationMixerPlayable;
|
|
23059
|
+
}(TrackMixerPlayable);
|
|
23060
|
+
|
|
23061
|
+
var PropertyClipPlayable = /*#__PURE__*/ function(Playable) {
|
|
23062
|
+
_inherits(PropertyClipPlayable, Playable);
|
|
23063
|
+
function PropertyClipPlayable() {
|
|
23064
|
+
return Playable.apply(this, arguments);
|
|
23065
|
+
}
|
|
23066
|
+
var _proto = PropertyClipPlayable.prototype;
|
|
23067
|
+
_proto.processFrame = function processFrame(context) {
|
|
23068
|
+
this.value = this.curve.getValue(this.time / this.getDuration());
|
|
23249
23069
|
};
|
|
23250
|
-
|
|
23251
|
-
|
|
23252
|
-
|
|
23253
|
-
|
|
23254
|
-
|
|
23070
|
+
return PropertyClipPlayable;
|
|
23071
|
+
}(Playable);
|
|
23072
|
+
|
|
23073
|
+
var ColorPropertyMixerPlayable = /*#__PURE__*/ function(TrackMixerPlayable) {
|
|
23074
|
+
_inherits(ColorPropertyMixerPlayable, TrackMixerPlayable);
|
|
23075
|
+
function ColorPropertyMixerPlayable() {
|
|
23076
|
+
var _this;
|
|
23077
|
+
_this = TrackMixerPlayable.apply(this, arguments) || this;
|
|
23078
|
+
_this.propertyName = "";
|
|
23079
|
+
return _this;
|
|
23080
|
+
}
|
|
23081
|
+
var _proto = ColorPropertyMixerPlayable.prototype;
|
|
23082
|
+
_proto.evaluate = function evaluate(context) {
|
|
23083
|
+
var boundObject = context.output.getUserData();
|
|
23084
|
+
if (!boundObject) {
|
|
23085
|
+
return;
|
|
23086
|
+
}
|
|
23087
|
+
var hasInput = false;
|
|
23088
|
+
var value = boundObject[this.propertyName];
|
|
23089
|
+
if (!_instanceof1(value, Color)) {
|
|
23090
|
+
return;
|
|
23091
|
+
}
|
|
23092
|
+
value.setZero();
|
|
23093
|
+
// evaluate the curve
|
|
23094
|
+
for(var i = 0; i < this.clipPlayables.length; i++){
|
|
23095
|
+
var weight = this.getClipWeight(i);
|
|
23096
|
+
if (weight > 0) {
|
|
23097
|
+
var propertyClipPlayable = this.getClipPlayable(i);
|
|
23098
|
+
if (!_instanceof1(propertyClipPlayable, PropertyClipPlayable)) {
|
|
23099
|
+
console.error("ColorPropertyMixerPlayable received incompatible input");
|
|
23100
|
+
continue;
|
|
23101
|
+
}
|
|
23102
|
+
var curveValue = propertyClipPlayable.value;
|
|
23103
|
+
value.r += curveValue.r * weight;
|
|
23104
|
+
value.g += curveValue.g * weight;
|
|
23105
|
+
value.b += curveValue.b * weight;
|
|
23106
|
+
value.a += curveValue.a * weight;
|
|
23107
|
+
hasInput = true;
|
|
23108
|
+
}
|
|
23109
|
+
}
|
|
23110
|
+
// set value
|
|
23111
|
+
if (hasInput) {
|
|
23112
|
+
boundObject[this.propertyName] = value;
|
|
23255
23113
|
}
|
|
23256
23114
|
};
|
|
23257
|
-
return
|
|
23258
|
-
}(
|
|
23259
|
-
__decorate([
|
|
23260
|
-
serialize(TimelineClip)
|
|
23261
|
-
], TrackAsset.prototype, "clips", void 0);
|
|
23262
|
-
__decorate([
|
|
23263
|
-
serialize()
|
|
23264
|
-
], TrackAsset.prototype, "children", void 0);
|
|
23265
|
-
TrackAsset = __decorate([
|
|
23266
|
-
effectsClass(DataType.TrackAsset)
|
|
23267
|
-
], TrackAsset);
|
|
23268
|
-
var TrackType;
|
|
23269
|
-
(function(TrackType) {
|
|
23270
|
-
TrackType[TrackType["MasterTrack"] = 0] = "MasterTrack";
|
|
23271
|
-
TrackType[TrackType["ObjectTrack"] = 1] = "ObjectTrack";
|
|
23272
|
-
})(TrackType || (TrackType = {}));
|
|
23273
|
-
var RuntimeClip = /*#__PURE__*/ function() {
|
|
23274
|
-
function RuntimeClip(clip, clipPlayable, parentMixer, track) {
|
|
23275
|
-
this.clip = clip;
|
|
23276
|
-
this.playable = clipPlayable;
|
|
23277
|
-
this.parentMixer = parentMixer;
|
|
23278
|
-
this.track = track;
|
|
23279
|
-
if (_instanceof1(this.track.boundObject, VFXItem)) {
|
|
23280
|
-
this.particleSystem = this.track.boundObject.getComponent(ParticleSystem);
|
|
23281
|
-
}
|
|
23282
|
-
}
|
|
23283
|
-
var _proto = RuntimeClip.prototype;
|
|
23284
|
-
_proto.evaluateAt = function evaluateAt(localTime) {
|
|
23285
|
-
var clip = this.clip;
|
|
23286
|
-
var weight = 1.0;
|
|
23287
|
-
var ended = false;
|
|
23288
|
-
var started = false;
|
|
23289
|
-
var boundObject = this.track.boundObject;
|
|
23290
|
-
if (localTime >= clip.start + clip.duration && clip.endBehavior === EndBehavior.destroy) {
|
|
23291
|
-
if (_instanceof1(boundObject, VFXItem) && VFXItem.isParticle(boundObject) && this.particleSystem && !this.particleSystem.destroyed) {
|
|
23292
|
-
weight = 1.0;
|
|
23293
|
-
} else {
|
|
23294
|
-
weight = 0.0;
|
|
23295
|
-
ended = true;
|
|
23296
|
-
}
|
|
23297
|
-
} else if (localTime - this.clip.start >= 0) {
|
|
23298
|
-
weight = 1.0;
|
|
23299
|
-
started = true;
|
|
23300
|
-
} else if (localTime < clip.start) {
|
|
23301
|
-
weight = 0.0;
|
|
23302
|
-
}
|
|
23303
|
-
if (started && this.playable.getPlayState() !== PlayState.Playing) {
|
|
23304
|
-
this.playable.play();
|
|
23305
|
-
}
|
|
23306
|
-
this.parentMixer.setInputWeight(this.playable, weight);
|
|
23307
|
-
var clipTime = parseFloat(clip.toLocalTime(localTime).toFixed(3));
|
|
23308
|
-
this.playable.setTime(clipTime);
|
|
23309
|
-
// 判断动画是否结束
|
|
23310
|
-
if (ended) {
|
|
23311
|
-
if (this.playable.getPlayState() === PlayState.Playing) {
|
|
23312
|
-
this.playable.pause();
|
|
23313
|
-
}
|
|
23314
|
-
}
|
|
23315
|
-
};
|
|
23316
|
-
_create_class(RuntimeClip, [
|
|
23317
|
-
{
|
|
23318
|
-
key: "enable",
|
|
23319
|
-
set: function set(value) {
|
|
23320
|
-
if (value) {
|
|
23321
|
-
this.playable.play();
|
|
23322
|
-
} else {
|
|
23323
|
-
this.parentMixer.setInputWeight(this.playable, 0);
|
|
23324
|
-
this.playable.pause();
|
|
23325
|
-
}
|
|
23326
|
-
}
|
|
23327
|
-
}
|
|
23328
|
-
]);
|
|
23329
|
-
return RuntimeClip;
|
|
23330
|
-
}();
|
|
23331
|
-
|
|
23332
|
-
var ActivationMixerPlayable = /*#__PURE__*/ function(Playable) {
|
|
23333
|
-
_inherits(ActivationMixerPlayable, Playable);
|
|
23334
|
-
function ActivationMixerPlayable() {
|
|
23335
|
-
return Playable.apply(this, arguments);
|
|
23336
|
-
}
|
|
23337
|
-
var _proto = ActivationMixerPlayable.prototype;
|
|
23338
|
-
_proto.processFrame = function processFrame(context) {
|
|
23339
|
-
var boundObject = context.output.getUserData();
|
|
23340
|
-
if (!_instanceof1(boundObject, VFXItem)) {
|
|
23341
|
-
return;
|
|
23342
|
-
}
|
|
23343
|
-
var boundItem = boundObject;
|
|
23344
|
-
var hasInput = false;
|
|
23345
|
-
for(var i = 0; i < this.getInputCount(); i++){
|
|
23346
|
-
if (this.getInputWeight(i) > 0) {
|
|
23347
|
-
hasInput = true;
|
|
23348
|
-
break;
|
|
23349
|
-
}
|
|
23350
|
-
}
|
|
23351
|
-
if (hasInput) {
|
|
23352
|
-
boundItem.transform.setValid(true);
|
|
23353
|
-
boundItem.setActive(true);
|
|
23354
|
-
} else {
|
|
23355
|
-
boundItem.transform.setValid(false);
|
|
23356
|
-
boundItem.setActive(false);
|
|
23357
|
-
}
|
|
23358
|
-
};
|
|
23359
|
-
return ActivationMixerPlayable;
|
|
23360
|
-
}(Playable);
|
|
23361
|
-
|
|
23362
|
-
var ActivationTrack = /*#__PURE__*/ function(TrackAsset) {
|
|
23363
|
-
_inherits(ActivationTrack, TrackAsset);
|
|
23364
|
-
function ActivationTrack() {
|
|
23365
|
-
return TrackAsset.apply(this, arguments);
|
|
23366
|
-
}
|
|
23367
|
-
var _proto = ActivationTrack.prototype;
|
|
23368
|
-
_proto.createTrackMixer = function createTrackMixer(graph) {
|
|
23369
|
-
return new ActivationMixerPlayable(graph);
|
|
23370
|
-
};
|
|
23371
|
-
return ActivationTrack;
|
|
23372
|
-
}(TrackAsset);
|
|
23373
|
-
ActivationTrack = __decorate([
|
|
23374
|
-
effectsClass(DataType.ActivationTrack)
|
|
23375
|
-
], ActivationTrack);
|
|
23376
|
-
|
|
23377
|
-
var PropertyClipPlayable = /*#__PURE__*/ function(Playable) {
|
|
23378
|
-
_inherits(PropertyClipPlayable, Playable);
|
|
23379
|
-
function PropertyClipPlayable() {
|
|
23380
|
-
return Playable.apply(this, arguments);
|
|
23381
|
-
}
|
|
23382
|
-
var _proto = PropertyClipPlayable.prototype;
|
|
23383
|
-
_proto.processFrame = function processFrame(context) {
|
|
23384
|
-
this.value = this.curve.getValue(this.time / this.getDuration());
|
|
23385
|
-
};
|
|
23386
|
-
return PropertyClipPlayable;
|
|
23387
|
-
}(Playable);
|
|
23115
|
+
return ColorPropertyMixerPlayable;
|
|
23116
|
+
}(TrackMixerPlayable);
|
|
23388
23117
|
|
|
23389
|
-
var FloatPropertyMixerPlayable = /*#__PURE__*/ function(
|
|
23390
|
-
_inherits(FloatPropertyMixerPlayable,
|
|
23118
|
+
var FloatPropertyMixerPlayable = /*#__PURE__*/ function(TrackMixerPlayable) {
|
|
23119
|
+
_inherits(FloatPropertyMixerPlayable, TrackMixerPlayable);
|
|
23391
23120
|
function FloatPropertyMixerPlayable() {
|
|
23392
23121
|
var _this;
|
|
23393
|
-
_this =
|
|
23122
|
+
_this = TrackMixerPlayable.apply(this, arguments) || this;
|
|
23394
23123
|
_this.propertyName = "";
|
|
23395
23124
|
return _this;
|
|
23396
23125
|
}
|
|
23397
23126
|
var _proto = FloatPropertyMixerPlayable.prototype;
|
|
23398
|
-
_proto.
|
|
23127
|
+
_proto.evaluate = function evaluate(context) {
|
|
23399
23128
|
var boundObject = context.output.getUserData();
|
|
23400
23129
|
if (!boundObject) {
|
|
23401
23130
|
return;
|
|
@@ -23403,10 +23132,10 @@ var FloatPropertyMixerPlayable = /*#__PURE__*/ function(Playable) {
|
|
|
23403
23132
|
var hasInput = false;
|
|
23404
23133
|
var value = 0;
|
|
23405
23134
|
// evaluate the curve
|
|
23406
|
-
for(var i = 0; i < this.
|
|
23407
|
-
var weight = this.
|
|
23135
|
+
for(var i = 0; i < this.clipPlayables.length; i++){
|
|
23136
|
+
var weight = this.getClipWeight(i);
|
|
23408
23137
|
if (weight > 0) {
|
|
23409
|
-
var propertyClipPlayable = this.
|
|
23138
|
+
var propertyClipPlayable = this.getClipPlayable(i);
|
|
23410
23139
|
if (!_instanceof1(propertyClipPlayable, PropertyClipPlayable)) {
|
|
23411
23140
|
console.error("FloatPropertyTrack added non-FloatPropertyPlayableAsset");
|
|
23412
23141
|
continue;
|
|
@@ -23422,7 +23151,27 @@ var FloatPropertyMixerPlayable = /*#__PURE__*/ function(Playable) {
|
|
|
23422
23151
|
}
|
|
23423
23152
|
};
|
|
23424
23153
|
return FloatPropertyMixerPlayable;
|
|
23425
|
-
}(
|
|
23154
|
+
}(TrackMixerPlayable);
|
|
23155
|
+
|
|
23156
|
+
var ParticleMixerPlayable = /*#__PURE__*/ function(TrackMixerPlayable) {
|
|
23157
|
+
_inherits(ParticleMixerPlayable, TrackMixerPlayable);
|
|
23158
|
+
function ParticleMixerPlayable() {
|
|
23159
|
+
return TrackMixerPlayable.apply(this, arguments);
|
|
23160
|
+
}
|
|
23161
|
+
var _proto = ParticleMixerPlayable.prototype;
|
|
23162
|
+
_proto.evaluate = function evaluate(context) {};
|
|
23163
|
+
return ParticleMixerPlayable;
|
|
23164
|
+
}(TrackMixerPlayable);
|
|
23165
|
+
|
|
23166
|
+
var SpriteColorMixerPlayable = /*#__PURE__*/ function(TrackMixerPlayable) {
|
|
23167
|
+
_inherits(SpriteColorMixerPlayable, TrackMixerPlayable);
|
|
23168
|
+
function SpriteColorMixerPlayable() {
|
|
23169
|
+
return TrackMixerPlayable.apply(this, arguments);
|
|
23170
|
+
}
|
|
23171
|
+
var _proto = SpriteColorMixerPlayable.prototype;
|
|
23172
|
+
_proto.evaluate = function evaluate(context) {};
|
|
23173
|
+
return SpriteColorMixerPlayable;
|
|
23174
|
+
}(TrackMixerPlayable);
|
|
23426
23175
|
|
|
23427
23176
|
var SerializationHelper = /*#__PURE__*/ function() {
|
|
23428
23177
|
function SerializationHelper() {}
|
|
@@ -23914,7 +23663,8 @@ var SerializationHelper = /*#__PURE__*/ function() {
|
|
|
23914
23663
|
this.timelinePlayable.setTime(time);
|
|
23915
23664
|
// The properties of the object may change dynamically,
|
|
23916
23665
|
// so reset the track binding to avoid invalidation of the previously obtained binding object.
|
|
23917
|
-
this.resolveBindings();
|
|
23666
|
+
// this.resolveBindings();
|
|
23667
|
+
this.timelinePlayable.evaluate();
|
|
23918
23668
|
this.graph.evaluate(dt);
|
|
23919
23669
|
};
|
|
23920
23670
|
_proto.createContent = function createContent() {
|
|
@@ -24047,6 +23797,20 @@ var SerializationHelper = /*#__PURE__*/ function() {
|
|
|
24047
23797
|
}
|
|
24048
23798
|
return regions;
|
|
24049
23799
|
};
|
|
23800
|
+
/**
|
|
23801
|
+
* 设置当前合成子元素的渲染顺序
|
|
23802
|
+
* @internal
|
|
23803
|
+
*/ _proto.setChildrenRenderOrder = function setChildrenRenderOrder(startOrder) {
|
|
23804
|
+
for(var _iterator = _create_for_of_iterator_helper_loose(this.items), _step; !(_step = _iterator()).done;){
|
|
23805
|
+
var item = _step.value;
|
|
23806
|
+
item.renderOrder = startOrder++;
|
|
23807
|
+
var subCompositionComponent = item.getComponent(CompositionComponent);
|
|
23808
|
+
if (subCompositionComponent) {
|
|
23809
|
+
startOrder = subCompositionComponent.setChildrenRenderOrder(startOrder);
|
|
23810
|
+
}
|
|
23811
|
+
}
|
|
23812
|
+
return startOrder;
|
|
23813
|
+
};
|
|
24050
23814
|
_proto.fromData = function fromData(data) {
|
|
24051
23815
|
Behaviour.prototype.fromData.call(this, data);
|
|
24052
23816
|
this.items = data.items;
|
|
@@ -24093,21 +23857,21 @@ var SubCompositionClipPlayable = /*#__PURE__*/ function(Playable) {
|
|
|
24093
23857
|
return SubCompositionClipPlayable;
|
|
24094
23858
|
}(Playable);
|
|
24095
23859
|
|
|
24096
|
-
var SubCompositionMixerPlayable = /*#__PURE__*/ function(
|
|
24097
|
-
_inherits(SubCompositionMixerPlayable,
|
|
23860
|
+
var SubCompositionMixerPlayable = /*#__PURE__*/ function(TrackMixerPlayable) {
|
|
23861
|
+
_inherits(SubCompositionMixerPlayable, TrackMixerPlayable);
|
|
24098
23862
|
function SubCompositionMixerPlayable() {
|
|
24099
|
-
return
|
|
23863
|
+
return TrackMixerPlayable.apply(this, arguments);
|
|
24100
23864
|
}
|
|
24101
23865
|
var _proto = SubCompositionMixerPlayable.prototype;
|
|
24102
|
-
_proto.
|
|
23866
|
+
_proto.evaluate = function evaluate(context) {
|
|
24103
23867
|
var boundObject = context.output.getUserData();
|
|
24104
23868
|
if (!_instanceof1(boundObject, CompositionComponent)) {
|
|
24105
23869
|
return;
|
|
24106
23870
|
}
|
|
24107
23871
|
var compositionComponent = boundObject;
|
|
24108
23872
|
var hasInput = false;
|
|
24109
|
-
for(var i = 0; i < this.
|
|
24110
|
-
if (this.
|
|
23873
|
+
for(var i = 0; i < this.clipPlayables.length; i++){
|
|
23874
|
+
if (this.getClipWeight(i) > 0) {
|
|
24111
23875
|
hasInput = true;
|
|
24112
23876
|
break;
|
|
24113
23877
|
}
|
|
@@ -24119,18 +23883,28 @@ var SubCompositionMixerPlayable = /*#__PURE__*/ function(Playable) {
|
|
|
24119
23883
|
}
|
|
24120
23884
|
};
|
|
24121
23885
|
return SubCompositionMixerPlayable;
|
|
24122
|
-
}(
|
|
23886
|
+
}(TrackMixerPlayable);
|
|
23887
|
+
|
|
23888
|
+
var TransformMixerPlayable = /*#__PURE__*/ function(TrackMixerPlayable) {
|
|
23889
|
+
_inherits(TransformMixerPlayable, TrackMixerPlayable);
|
|
23890
|
+
function TransformMixerPlayable() {
|
|
23891
|
+
return TrackMixerPlayable.apply(this, arguments);
|
|
23892
|
+
}
|
|
23893
|
+
var _proto = TransformMixerPlayable.prototype;
|
|
23894
|
+
_proto.evaluate = function evaluate(context) {};
|
|
23895
|
+
return TransformMixerPlayable;
|
|
23896
|
+
}(TrackMixerPlayable);
|
|
24123
23897
|
|
|
24124
|
-
var Vector4PropertyMixerPlayable = /*#__PURE__*/ function(
|
|
24125
|
-
_inherits(Vector4PropertyMixerPlayable,
|
|
23898
|
+
var Vector4PropertyMixerPlayable = /*#__PURE__*/ function(TrackMixerPlayable) {
|
|
23899
|
+
_inherits(Vector4PropertyMixerPlayable, TrackMixerPlayable);
|
|
24126
23900
|
function Vector4PropertyMixerPlayable() {
|
|
24127
23901
|
var _this;
|
|
24128
|
-
_this =
|
|
23902
|
+
_this = TrackMixerPlayable.apply(this, arguments) || this;
|
|
24129
23903
|
_this.propertyName = "";
|
|
24130
23904
|
return _this;
|
|
24131
23905
|
}
|
|
24132
23906
|
var _proto = Vector4PropertyMixerPlayable.prototype;
|
|
24133
|
-
_proto.
|
|
23907
|
+
_proto.evaluate = function evaluate(context) {
|
|
24134
23908
|
var boundObject = context.output.getUserData();
|
|
24135
23909
|
if (!boundObject) {
|
|
24136
23910
|
return;
|
|
@@ -24142,10 +23916,10 @@ var Vector4PropertyMixerPlayable = /*#__PURE__*/ function(Playable) {
|
|
|
24142
23916
|
}
|
|
24143
23917
|
value.setZero();
|
|
24144
23918
|
// evaluate the curve
|
|
24145
|
-
for(var i = 0; i < this.
|
|
24146
|
-
var weight = this.
|
|
23919
|
+
for(var i = 0; i < this.clipPlayables.length; i++){
|
|
23920
|
+
var weight = this.getClipWeight(i);
|
|
24147
23921
|
if (weight > 0) {
|
|
24148
|
-
var propertyClipPlayable = this.
|
|
23922
|
+
var propertyClipPlayable = this.getClipPlayable(i);
|
|
24149
23923
|
if (!_instanceof1(propertyClipPlayable, PropertyClipPlayable)) {
|
|
24150
23924
|
console.error("Vector4PropertyTrack added non-Vector4PropertyPlayableAsset");
|
|
24151
23925
|
continue;
|
|
@@ -24164,52 +23938,215 @@ var Vector4PropertyMixerPlayable = /*#__PURE__*/ function(Playable) {
|
|
|
24164
23938
|
}
|
|
24165
23939
|
};
|
|
24166
23940
|
return Vector4PropertyMixerPlayable;
|
|
24167
|
-
}(
|
|
23941
|
+
}(TrackMixerPlayable);
|
|
24168
23942
|
|
|
24169
|
-
|
|
24170
|
-
|
|
24171
|
-
|
|
23943
|
+
/**
|
|
23944
|
+
* @since 2.0.0
|
|
23945
|
+
*/ var TimelineClip = /*#__PURE__*/ function() {
|
|
23946
|
+
function TimelineClip() {
|
|
23947
|
+
this.start = 0;
|
|
23948
|
+
this.duration = 0;
|
|
23949
|
+
}
|
|
23950
|
+
var _proto = TimelineClip.prototype;
|
|
23951
|
+
_proto.toLocalTime = function toLocalTime(time) {
|
|
23952
|
+
var localTime = time - this.start;
|
|
23953
|
+
var duration = this.duration;
|
|
23954
|
+
if (localTime - duration > 0) {
|
|
23955
|
+
if (this.endBehavior === EndBehavior.restart) {
|
|
23956
|
+
localTime = localTime % duration;
|
|
23957
|
+
} else if (this.endBehavior === EndBehavior.freeze) {
|
|
23958
|
+
localTime = Math.min(duration, localTime);
|
|
23959
|
+
}
|
|
23960
|
+
}
|
|
23961
|
+
return localTime;
|
|
23962
|
+
};
|
|
23963
|
+
return TimelineClip;
|
|
23964
|
+
}();
|
|
23965
|
+
var TrackAsset = /*#__PURE__*/ function(PlayableAsset) {
|
|
23966
|
+
_inherits(TrackAsset, PlayableAsset);
|
|
23967
|
+
function TrackAsset() {
|
|
24172
23968
|
var _this;
|
|
24173
|
-
_this =
|
|
24174
|
-
_this.
|
|
23969
|
+
_this = PlayableAsset.apply(this, arguments) || this;
|
|
23970
|
+
_this.trackType = 0;
|
|
23971
|
+
_this.clipSeed = 0;
|
|
23972
|
+
_this.clips = [];
|
|
23973
|
+
_this.children = [];
|
|
24175
23974
|
return _this;
|
|
24176
23975
|
}
|
|
24177
|
-
var _proto =
|
|
24178
|
-
|
|
24179
|
-
|
|
24180
|
-
|
|
24181
|
-
|
|
23976
|
+
var _proto = TrackAsset.prototype;
|
|
23977
|
+
/**
|
|
23978
|
+
* 重写该方法以获取自定义对象绑定
|
|
23979
|
+
*/ _proto.updateAnimatedObject = function updateAnimatedObject() {
|
|
23980
|
+
if (this.parent) {
|
|
23981
|
+
this.boundObject = this.parent.boundObject;
|
|
24182
23982
|
}
|
|
24183
|
-
|
|
24184
|
-
|
|
24185
|
-
|
|
24186
|
-
|
|
23983
|
+
};
|
|
23984
|
+
/**
|
|
23985
|
+
* 重写该方法以创建自定义混合器
|
|
23986
|
+
*/ _proto.createTrackMixer = function createTrackMixer(graph) {
|
|
23987
|
+
return new TrackMixerPlayable(graph);
|
|
23988
|
+
};
|
|
23989
|
+
_proto.createOutput = function createOutput() {
|
|
23990
|
+
var output = new PlayableOutput();
|
|
23991
|
+
return output;
|
|
23992
|
+
};
|
|
23993
|
+
_proto.createPlayableGraph = function createPlayableGraph(graph, runtimeClips) {
|
|
23994
|
+
var mixerPlayable = this.createMixerPlayableGraph(graph, runtimeClips);
|
|
23995
|
+
return mixerPlayable;
|
|
23996
|
+
};
|
|
23997
|
+
_proto.createMixerPlayableGraph = function createMixerPlayableGraph(graph, runtimeClips) {
|
|
23998
|
+
var clips = [];
|
|
23999
|
+
for(var _iterator = _create_for_of_iterator_helper_loose(this.clips), _step; !(_step = _iterator()).done;){
|
|
24000
|
+
var clip = _step.value;
|
|
24001
|
+
clips.push(clip);
|
|
24187
24002
|
}
|
|
24188
|
-
|
|
24189
|
-
|
|
24190
|
-
|
|
24191
|
-
|
|
24192
|
-
|
|
24193
|
-
|
|
24194
|
-
|
|
24195
|
-
|
|
24196
|
-
|
|
24197
|
-
|
|
24198
|
-
|
|
24199
|
-
|
|
24200
|
-
|
|
24201
|
-
|
|
24202
|
-
|
|
24203
|
-
|
|
24003
|
+
var mixerPlayable = this.compileClips(graph, clips, runtimeClips);
|
|
24004
|
+
return mixerPlayable;
|
|
24005
|
+
};
|
|
24006
|
+
_proto.compileClips = function compileClips(graph, timelineClips, runtimeClips) {
|
|
24007
|
+
var mixer = this.createTrackMixer(graph);
|
|
24008
|
+
for(var _iterator = _create_for_of_iterator_helper_loose(timelineClips), _step; !(_step = _iterator()).done;){
|
|
24009
|
+
var timelineClip = _step.value;
|
|
24010
|
+
var clipPlayable = this.createClipPlayable(graph, timelineClip);
|
|
24011
|
+
clipPlayable.setDuration(timelineClip.duration);
|
|
24012
|
+
var clip = new RuntimeClip(timelineClip, clipPlayable, mixer, this);
|
|
24013
|
+
runtimeClips.push(clip);
|
|
24014
|
+
mixer.clipPlayables.push(clipPlayable);
|
|
24015
|
+
mixer.setClipWeight(clipPlayable, 0.0);
|
|
24016
|
+
}
|
|
24017
|
+
return mixer;
|
|
24018
|
+
};
|
|
24019
|
+
_proto.createPlayable = function createPlayable(graph) {
|
|
24020
|
+
return new Playable(graph);
|
|
24021
|
+
};
|
|
24022
|
+
_proto.getChildTracks = function getChildTracks() {
|
|
24023
|
+
return this.children;
|
|
24024
|
+
};
|
|
24025
|
+
_proto.addChild = function addChild(child) {
|
|
24026
|
+
this.children.push(child);
|
|
24027
|
+
child.parent = this;
|
|
24028
|
+
};
|
|
24029
|
+
_proto.createClip = function createClip(classConstructor, name) {
|
|
24030
|
+
var newClip = new TimelineClip();
|
|
24031
|
+
newClip.asset = new classConstructor(this.engine);
|
|
24032
|
+
newClip.name = name ? name : "TimelineClip" + newClip.id;
|
|
24033
|
+
this.addClip(newClip);
|
|
24034
|
+
return newClip;
|
|
24035
|
+
};
|
|
24036
|
+
_proto.getClips = function getClips() {
|
|
24037
|
+
return this.clips;
|
|
24038
|
+
};
|
|
24039
|
+
_proto.findClip = function findClip(name) {
|
|
24040
|
+
for(var _iterator = _create_for_of_iterator_helper_loose(this.clips), _step; !(_step = _iterator()).done;){
|
|
24041
|
+
var clip = _step.value;
|
|
24042
|
+
if (clip.name === name) {
|
|
24043
|
+
return clip;
|
|
24204
24044
|
}
|
|
24205
24045
|
}
|
|
24206
|
-
|
|
24207
|
-
|
|
24208
|
-
|
|
24046
|
+
};
|
|
24047
|
+
_proto.addClip = function addClip(clip) {
|
|
24048
|
+
clip.id = (this.clipSeed++).toString();
|
|
24049
|
+
this.clips.push(clip);
|
|
24050
|
+
};
|
|
24051
|
+
_proto.createClipPlayable = function createClipPlayable(graph, clip) {
|
|
24052
|
+
return clip.asset.createPlayable(graph);
|
|
24053
|
+
};
|
|
24054
|
+
_proto.fromData = function fromData(data) {
|
|
24055
|
+
PlayableAsset.prototype.fromData.call(this, data);
|
|
24056
|
+
for(var _iterator = _create_for_of_iterator_helper_loose(this.children), _step; !(_step = _iterator()).done;){
|
|
24057
|
+
var child = _step.value;
|
|
24058
|
+
child.parent = this;
|
|
24209
24059
|
}
|
|
24210
24060
|
};
|
|
24211
|
-
return
|
|
24212
|
-
}(
|
|
24061
|
+
return TrackAsset;
|
|
24062
|
+
}(PlayableAsset);
|
|
24063
|
+
__decorate([
|
|
24064
|
+
serialize(TimelineClip)
|
|
24065
|
+
], TrackAsset.prototype, "clips", void 0);
|
|
24066
|
+
__decorate([
|
|
24067
|
+
serialize()
|
|
24068
|
+
], TrackAsset.prototype, "children", void 0);
|
|
24069
|
+
TrackAsset = __decorate([
|
|
24070
|
+
effectsClass(DataType.TrackAsset)
|
|
24071
|
+
], TrackAsset);
|
|
24072
|
+
var TrackType;
|
|
24073
|
+
(function(TrackType) {
|
|
24074
|
+
TrackType[TrackType["MasterTrack"] = 0] = "MasterTrack";
|
|
24075
|
+
TrackType[TrackType["ObjectTrack"] = 1] = "ObjectTrack";
|
|
24076
|
+
})(TrackType || (TrackType = {}));
|
|
24077
|
+
var RuntimeClip = /*#__PURE__*/ function() {
|
|
24078
|
+
function RuntimeClip(clip, clipPlayable, parentMixer, track) {
|
|
24079
|
+
this.clip = clip;
|
|
24080
|
+
this.playable = clipPlayable;
|
|
24081
|
+
this.parentMixer = parentMixer;
|
|
24082
|
+
this.track = track;
|
|
24083
|
+
if (_instanceof1(this.track.boundObject, VFXItem)) {
|
|
24084
|
+
this.particleSystem = this.track.boundObject.getComponent(ParticleSystem);
|
|
24085
|
+
}
|
|
24086
|
+
}
|
|
24087
|
+
var _proto = RuntimeClip.prototype;
|
|
24088
|
+
_proto.evaluateAt = function evaluateAt(localTime) {
|
|
24089
|
+
var clip = this.clip;
|
|
24090
|
+
var weight = 1.0;
|
|
24091
|
+
var ended = false;
|
|
24092
|
+
var started = false;
|
|
24093
|
+
var boundObject = this.track.boundObject;
|
|
24094
|
+
if (localTime >= clip.start + clip.duration && clip.endBehavior === EndBehavior.destroy) {
|
|
24095
|
+
if (_instanceof1(boundObject, VFXItem) && VFXItem.isParticle(boundObject) && this.particleSystem && !this.particleSystem.destroyed) {
|
|
24096
|
+
weight = 1.0;
|
|
24097
|
+
} else {
|
|
24098
|
+
weight = 0.0;
|
|
24099
|
+
ended = true;
|
|
24100
|
+
}
|
|
24101
|
+
} else if (localTime - this.clip.start >= 0) {
|
|
24102
|
+
weight = 1.0;
|
|
24103
|
+
started = true;
|
|
24104
|
+
} else if (localTime < clip.start) {
|
|
24105
|
+
weight = 0.0;
|
|
24106
|
+
}
|
|
24107
|
+
if (started && this.playable.getPlayState() !== PlayState.Playing) {
|
|
24108
|
+
this.playable.play();
|
|
24109
|
+
}
|
|
24110
|
+
this.parentMixer.setClipWeight(this.playable, weight);
|
|
24111
|
+
var clipTime = parseFloat(clip.toLocalTime(localTime).toFixed(3));
|
|
24112
|
+
this.playable.setTime(clipTime);
|
|
24113
|
+
// 判断动画是否结束
|
|
24114
|
+
if (ended) {
|
|
24115
|
+
if (this.playable.getPlayState() === PlayState.Playing) {
|
|
24116
|
+
this.playable.pause();
|
|
24117
|
+
}
|
|
24118
|
+
}
|
|
24119
|
+
};
|
|
24120
|
+
_create_class(RuntimeClip, [
|
|
24121
|
+
{
|
|
24122
|
+
key: "enable",
|
|
24123
|
+
set: function set(value) {
|
|
24124
|
+
if (value) {
|
|
24125
|
+
this.playable.play();
|
|
24126
|
+
} else {
|
|
24127
|
+
this.parentMixer.setClipWeight(this.playable, 0);
|
|
24128
|
+
this.playable.pause();
|
|
24129
|
+
}
|
|
24130
|
+
}
|
|
24131
|
+
}
|
|
24132
|
+
]);
|
|
24133
|
+
return RuntimeClip;
|
|
24134
|
+
}();
|
|
24135
|
+
|
|
24136
|
+
var ActivationTrack = /*#__PURE__*/ function(TrackAsset) {
|
|
24137
|
+
_inherits(ActivationTrack, TrackAsset);
|
|
24138
|
+
function ActivationTrack() {
|
|
24139
|
+
return TrackAsset.apply(this, arguments);
|
|
24140
|
+
}
|
|
24141
|
+
var _proto = ActivationTrack.prototype;
|
|
24142
|
+
_proto.createTrackMixer = function createTrackMixer(graph) {
|
|
24143
|
+
return new ActivationMixerPlayable(graph);
|
|
24144
|
+
};
|
|
24145
|
+
return ActivationTrack;
|
|
24146
|
+
}(TrackAsset);
|
|
24147
|
+
ActivationTrack = __decorate([
|
|
24148
|
+
effectsClass(DataType.ActivationTrack)
|
|
24149
|
+
], ActivationTrack);
|
|
24213
24150
|
|
|
24214
24151
|
var PropertyTrack = /*#__PURE__*/ function(TrackAsset) {
|
|
24215
24152
|
_inherits(PropertyTrack, TrackAsset);
|
|
@@ -24282,6 +24219,10 @@ var SpriteColorTrack = /*#__PURE__*/ function(TrackAsset) {
|
|
|
24282
24219
|
function SpriteColorTrack() {
|
|
24283
24220
|
return TrackAsset.apply(this, arguments);
|
|
24284
24221
|
}
|
|
24222
|
+
var _proto = SpriteColorTrack.prototype;
|
|
24223
|
+
_proto.createTrackMixer = function createTrackMixer(graph) {
|
|
24224
|
+
return new SpriteColorMixerPlayable(graph);
|
|
24225
|
+
};
|
|
24285
24226
|
return SpriteColorTrack;
|
|
24286
24227
|
}(TrackAsset);
|
|
24287
24228
|
SpriteColorTrack = __decorate([
|
|
@@ -24314,6 +24255,10 @@ var TransformTrack = /*#__PURE__*/ function(TrackAsset) {
|
|
|
24314
24255
|
function TransformTrack() {
|
|
24315
24256
|
return TrackAsset.apply(this, arguments);
|
|
24316
24257
|
}
|
|
24258
|
+
var _proto = TransformTrack.prototype;
|
|
24259
|
+
_proto.createTrackMixer = function createTrackMixer(graph) {
|
|
24260
|
+
return new TransformMixerPlayable(graph);
|
|
24261
|
+
};
|
|
24317
24262
|
return TransformTrack;
|
|
24318
24263
|
}(TrackAsset);
|
|
24319
24264
|
TransformTrack = __decorate([
|
|
@@ -24342,6 +24287,18 @@ MaterialTrack = __decorate([
|
|
|
24342
24287
|
effectsClass("MaterialTrack")
|
|
24343
24288
|
], MaterialTrack);
|
|
24344
24289
|
|
|
24290
|
+
var ParticleTrack = /*#__PURE__*/ function(TrackAsset) {
|
|
24291
|
+
_inherits(ParticleTrack, TrackAsset);
|
|
24292
|
+
function ParticleTrack() {
|
|
24293
|
+
return TrackAsset.apply(this, arguments);
|
|
24294
|
+
}
|
|
24295
|
+
var _proto = ParticleTrack.prototype;
|
|
24296
|
+
_proto.createTrackMixer = function createTrackMixer(graph) {
|
|
24297
|
+
return new ParticleMixerPlayable(graph);
|
|
24298
|
+
};
|
|
24299
|
+
return ParticleTrack;
|
|
24300
|
+
}(TrackAsset);
|
|
24301
|
+
|
|
24345
24302
|
var Vector4PropertyTrack = /*#__PURE__*/ function(PropertyTrack) {
|
|
24346
24303
|
_inherits(Vector4PropertyTrack, PropertyTrack);
|
|
24347
24304
|
function Vector4PropertyTrack() {
|
|
@@ -24470,7 +24427,6 @@ var TimelineAsset = /*#__PURE__*/ function(PlayableAsset) {
|
|
|
24470
24427
|
var _proto = TimelineAsset.prototype;
|
|
24471
24428
|
_proto.createPlayable = function createPlayable(graph) {
|
|
24472
24429
|
var timelinePlayable = new TimelinePlayable(graph);
|
|
24473
|
-
timelinePlayable.setTraversalMode(PlayableTraversalMode.Passthrough);
|
|
24474
24430
|
for(var _iterator = _create_for_of_iterator_helper_loose(this.tracks), _step; !(_step = _iterator()).done;){
|
|
24475
24431
|
var track = _step.value;
|
|
24476
24432
|
if (_instanceof1(track, ObjectBindingTrack)) {
|
|
@@ -24551,9 +24507,7 @@ var TimelinePlayable = /*#__PURE__*/ function(Playable) {
|
|
|
24551
24507
|
return _this;
|
|
24552
24508
|
}
|
|
24553
24509
|
var _proto = TimelinePlayable.prototype;
|
|
24554
|
-
_proto.prepareFrame = function prepareFrame(context) {
|
|
24555
|
-
this.evaluate();
|
|
24556
|
-
};
|
|
24510
|
+
_proto.prepareFrame = function prepareFrame(context) {};
|
|
24557
24511
|
_proto.evaluate = function evaluate() {
|
|
24558
24512
|
var time = this.getTime();
|
|
24559
24513
|
// TODO search active clips
|
|
@@ -24570,11 +24524,10 @@ var TimelinePlayable = /*#__PURE__*/ function(Playable) {
|
|
|
24570
24524
|
var track = _step.value;
|
|
24571
24525
|
// create track mixer and track output
|
|
24572
24526
|
var trackMixPlayable = track.createPlayableGraph(graph, this.clips);
|
|
24573
|
-
this.addInput(trackMixPlayable, 0);
|
|
24574
24527
|
var trackOutput = track.createOutput();
|
|
24575
24528
|
trackOutput.setUserData(track.boundObject);
|
|
24576
24529
|
graph.addOutput(trackOutput);
|
|
24577
|
-
trackOutput.setSourcePlayable(
|
|
24530
|
+
trackOutput.setSourcePlayable(trackMixPlayable);
|
|
24578
24531
|
// create track instance
|
|
24579
24532
|
var trackInstance = new TrackInstance(track, trackMixPlayable, trackOutput);
|
|
24580
24533
|
trackInstanceMap[track.getInstanceId()] = trackInstance;
|
|
@@ -24635,10 +24588,10 @@ Vector4PropertyPlayableAsset = __decorate([
|
|
|
24635
24588
|
effectsClass("Vector4PropertyPlayableAsset")
|
|
24636
24589
|
], Vector4PropertyPlayableAsset);
|
|
24637
24590
|
|
|
24638
|
-
var ObjectBindingTrack = /*#__PURE__*/ function(
|
|
24639
|
-
_inherits(ObjectBindingTrack,
|
|
24591
|
+
var ObjectBindingTrack = /*#__PURE__*/ function(TrackAsset) {
|
|
24592
|
+
_inherits(ObjectBindingTrack, TrackAsset);
|
|
24640
24593
|
function ObjectBindingTrack() {
|
|
24641
|
-
return
|
|
24594
|
+
return TrackAsset.apply(this, arguments);
|
|
24642
24595
|
}
|
|
24643
24596
|
var _proto = ObjectBindingTrack.prototype;
|
|
24644
24597
|
_proto.updateAnimatedObject = function updateAnimatedObject() {};
|
|
@@ -24649,7 +24602,7 @@ var ObjectBindingTrack = /*#__PURE__*/ function(TrackAsset1) {
|
|
|
24649
24602
|
var boundItem = this.boundObject;
|
|
24650
24603
|
// 添加粒子动画 clip // TODO 待移除
|
|
24651
24604
|
if (boundItem.getComponent(ParticleSystem)) {
|
|
24652
|
-
var particleTrack = timelineAsset.createTrack(
|
|
24605
|
+
var particleTrack = timelineAsset.createTrack(ParticleTrack, this, "ParticleTrack");
|
|
24653
24606
|
particleTrack.boundObject = this.boundObject;
|
|
24654
24607
|
var particleClip = particleTrack.createClip(ParticleBehaviourPlayableAsset);
|
|
24655
24608
|
particleClip.start = boundItem.start;
|
|
@@ -24672,14 +24625,14 @@ var TextLayout = /*#__PURE__*/ function() {
|
|
|
24672
24625
|
function TextLayout(options) {
|
|
24673
24626
|
this.width = 0;
|
|
24674
24627
|
this.height = 0;
|
|
24675
|
-
var _options_textHeight = options.textHeight, textHeight = _options_textHeight === void 0 ? 100 : _options_textHeight, _options_textWidth = options.textWidth, textWidth = _options_textWidth === void 0 ? 100 : _options_textWidth, _options_textOverflow = options.textOverflow, textOverflow = _options_textOverflow === void 0 ? TextOverflow.
|
|
24628
|
+
var _options_textHeight = options.textHeight, textHeight = _options_textHeight === void 0 ? 100 : _options_textHeight, _options_textWidth = options.textWidth, textWidth = _options_textWidth === void 0 ? 100 : _options_textWidth, _options_textOverflow = options.textOverflow, textOverflow = _options_textOverflow === void 0 ? TextOverflow.clip : _options_textOverflow, _options_textBaseline = options.textBaseline, textBaseline = _options_textBaseline === void 0 ? TextBaseline.top : _options_textBaseline, _options_textAlign = options.textAlign, textAlign = _options_textAlign === void 0 ? TextAlignment.left : _options_textAlign, _options_text = options.text, text = _options_text === void 0 ? " " : _options_text, _options_letterSpace = options.letterSpace, letterSpace = _options_letterSpace === void 0 ? 0 : _options_letterSpace, _options_autoWidth = options.autoWidth, autoWidth = _options_autoWidth === void 0 ? false : _options_autoWidth, fontSize = options.fontSize, _options_lineHeight = options.lineHeight, lineHeight = _options_lineHeight === void 0 ? fontSize : _options_lineHeight;
|
|
24676
24629
|
var tempWidth = fontSize + letterSpace;
|
|
24677
24630
|
this.autoWidth = autoWidth;
|
|
24678
24631
|
this.maxTextWidth = text.length * tempWidth;
|
|
24679
24632
|
this.width = textWidth;
|
|
24680
24633
|
this.height = textHeight;
|
|
24681
24634
|
this.letterSpace = letterSpace;
|
|
24682
|
-
this.
|
|
24635
|
+
this.overflow = textOverflow;
|
|
24683
24636
|
this.textBaseline = textBaseline;
|
|
24684
24637
|
this.textAlign = textAlign;
|
|
24685
24638
|
this.lineHeight = lineHeight;
|
|
@@ -27669,11 +27622,11 @@ var seed = 1;
|
|
|
27669
27622
|
if (compressedTexture === void 0) compressedTexture = 0;
|
|
27670
27623
|
var _this = this;
|
|
27671
27624
|
return _async_to_generator(function() {
|
|
27672
|
-
var _this_options, useCompressedTexture, variables, baseUrl, jobs, loadedImages;
|
|
27625
|
+
var _this_options, useCompressedTexture, variables, disableWebP, disableAVIF, baseUrl, jobs, loadedImages;
|
|
27673
27626
|
return __generator(this, function(_state) {
|
|
27674
27627
|
switch(_state.label){
|
|
27675
27628
|
case 0:
|
|
27676
|
-
_this_options = _this.options, useCompressedTexture = _this_options.useCompressedTexture, variables = _this_options.variables;
|
|
27629
|
+
_this_options = _this.options, useCompressedTexture = _this_options.useCompressedTexture, variables = _this_options.variables, disableWebP = _this_options.disableWebP, disableAVIF = _this_options.disableAVIF;
|
|
27677
27630
|
baseUrl = _this.baseUrl;
|
|
27678
27631
|
jobs = images.map(/*#__PURE__*/ _async_to_generator(function(img, idx) {
|
|
27679
27632
|
var png, webp, avif, imageURL, webpURL, avifURL, id, template, background, url, isVideo, loadFn, resultImage, e, compressed, src, bufferURL, _ref, url1, image, _tmp;
|
|
@@ -27684,9 +27637,9 @@ var seed = 1;
|
|
|
27684
27637
|
// eslint-disable-next-line compat/compat
|
|
27685
27638
|
imageURL = new URL(png, baseUrl).href;
|
|
27686
27639
|
// eslint-disable-next-line compat/compat
|
|
27687
|
-
webpURL =
|
|
27640
|
+
webpURL = !disableWebP && webp ? new URL(webp, baseUrl).href : undefined;
|
|
27688
27641
|
// eslint-disable-next-line compat/compat
|
|
27689
|
-
avifURL =
|
|
27642
|
+
avifURL = !disableAVIF && avif ? new URL(avif, baseUrl).href : undefined;
|
|
27690
27643
|
id = img.id;
|
|
27691
27644
|
if (!("template" in img)) return [
|
|
27692
27645
|
3,
|
|
@@ -28375,7 +28328,6 @@ var tmpScale = new Vector3(1, 1, 1);
|
|
|
28375
28328
|
return Camera;
|
|
28376
28329
|
}();
|
|
28377
28330
|
|
|
28378
|
-
var listOrder = 0;
|
|
28379
28331
|
/**
|
|
28380
28332
|
* 合成资源管理
|
|
28381
28333
|
*/ var CompositionSourceManager = /*#__PURE__*/ function() {
|
|
@@ -28408,7 +28360,6 @@ var listOrder = 0;
|
|
|
28408
28360
|
this.pluginSystem = pluginSystem;
|
|
28409
28361
|
this.totalTime = totalTime != null ? totalTime : 0;
|
|
28410
28362
|
this.textures = cachedTextures;
|
|
28411
|
-
listOrder = 0;
|
|
28412
28363
|
this.sourceContent = this.getContent(this.composition);
|
|
28413
28364
|
}
|
|
28414
28365
|
var _proto = CompositionSourceManager.prototype;
|
|
@@ -28439,7 +28390,6 @@ var listOrder = 0;
|
|
|
28439
28390
|
var sourceItemData = this.engine.jsonSceneData[itemDataPath.id];
|
|
28440
28391
|
var itemProps = sourceItemData;
|
|
28441
28392
|
if (passRenderLevel(sourceItemData.renderLevel, this.renderLevel)) {
|
|
28442
|
-
itemProps.listIndex = listOrder++;
|
|
28443
28393
|
if (itemProps.type === ItemType.sprite || itemProps.type === ItemType.particle || itemProps.type === ItemType.spine || //@ts-expect-error
|
|
28444
28394
|
itemProps.type === ItemType.shape) {
|
|
28445
28395
|
for(var _iterator2 = _create_for_of_iterator_helper_loose(itemProps.components), _step2; !(_step2 = _iterator2()).done;){
|
|
@@ -28742,6 +28692,7 @@ var LateUpdateTickData = /*#__PURE__*/ function(TickData) {
|
|
|
28742
28692
|
SerializationHelper.deserialize(sourceContent, _this.rootComposition);
|
|
28743
28693
|
_this.rootComposition.createContent();
|
|
28744
28694
|
_this.buildItemTree(_this.rootItem);
|
|
28695
|
+
_this.rootComposition.setChildrenRenderOrder(0);
|
|
28745
28696
|
_this.pluginSystem.resetComposition(_assert_this_initialized(_this), _this.renderFrame);
|
|
28746
28697
|
return _this;
|
|
28747
28698
|
}
|
|
@@ -31381,8 +31332,8 @@ registerPlugin("sprite", SpriteLoader, VFXItem, true);
|
|
|
31381
31332
|
registerPlugin("particle", ParticleLoader, VFXItem, true);
|
|
31382
31333
|
registerPlugin("cal", CalculateLoader, VFXItem, true);
|
|
31383
31334
|
registerPlugin("interact", InteractLoader, VFXItem, true);
|
|
31384
|
-
var version = "2.
|
|
31335
|
+
var version = "2.2.0";
|
|
31385
31336
|
logger.info("Core version: " + version + ".");
|
|
31386
31337
|
|
|
31387
|
-
export { AbstractPlugin, ActivationPlayable, ActivationPlayableAsset, ActivationTrack, AnimationClip, AnimationClipPlayable, Asset, AssetLoader, AssetManager, BYTES_TYPE_MAP, BaseRenderComponent, Behaviour, BezierCurve, BezierCurvePath, BezierCurveQuat, BinaryAsset, COMPRESSED_TEXTURE, COPY_FRAGMENT_SHADER, COPY_MESH_SHADER_ID, COPY_VERTEX_SHADER, CalculateLoader, Camera, CameraController, CameraVFXItemLoader, ColorCurve, ColorPropertyPlayableAsset, ColorPropertyTrack, Component, Composition, CompositionComponent, CompositionSourceManager, DEFAULT_FONTS, DEFAULT_FPS, Database, DestroyOptions, Downloader, EFFECTS_COPY_MESH_NAME, EVENT_TYPE_CLICK, EVENT_TYPE_TOUCH_END, EVENT_TYPE_TOUCH_MOVE, EVENT_TYPE_TOUCH_START, EffectComponent, EffectsObject, EffectsPackage, Engine, EventEmitter, EventSystem, Fake3DAnimationMode, Fake3DComponent, FilterMode, Float16ArrayWrapper, FloatPropertyPlayableAsset, FloatPropertyTrack, Framebuffer, GLSLVersion, GPUCapability, Geometry, GlobalUniforms, GradientValue, HELP_LINK, HitTestType, InteractComponent, InteractLoader, InteractMesh, Item, KTXTexture, LineSegments, LinearValue, Material, MaterialDataBlock, MaterialRenderType, MaterialTrack, Mesh, MeshCollider, ObjectBindingTrack, OrderType, PLAYER_OPTIONS_ENV_EDITOR, POST_PROCESS_SETTINGS, ParticleBehaviourPlayable, ParticleBehaviourPlayableAsset, ParticleLoader, ParticleMesh, ParticleSystem, ParticleSystemRenderer, PassTextureCache, PathSegments, PluginSystem, PostProcessVolume, PropertyTrack, RENDER_PASS_NAME_PREFIX, RENDER_PREFER_LOOKUP_TEXTURE, RUNTIME_ENV, RandomSetValue, RandomValue, RandomVectorValue, RenderFrame, RenderPass, RenderPassAttachmentStorageType, RenderPassDestroyAttachmentType, RenderPassPriorityNormal, RenderPassPriorityPostprocess, RenderPassPriorityPrepare, RenderTargetHandle, RenderTextureFormat, Renderbuffer, Renderer, RendererComponent, RuntimeClip, SEMANTIC_MAIN_PRE_COLOR_ATTACHMENT_0, SEMANTIC_MAIN_PRE_COLOR_ATTACHMENT_SIZE_0, SEMANTIC_PRE_COLOR_ATTACHMENT_0, SEMANTIC_PRE_COLOR_ATTACHMENT_SIZE_0, SPRITE_VERTEX_STRIDE, Scene, SemanticMap, SerializationHelper, Shader, ShaderCompileResultStatus, ShaderFactory, ShaderType, ShaderVariant, ShapeComponent, SpriteColorPlayableAsset, SpriteColorTrack, SpriteComponent, SpriteLoader, StaticValue, SubCompositionPlayableAsset, SubCompositionTrack, TEMPLATE_USE_OFFSCREEN_CANVAS, TextComponent, TextComponentBase, TextLayout, TextLoader, TextStyle, Texture, TextureFactory, TextureLoadAction, TextureSourceType, TextureStoreAction, Ticker, TimelineAsset, TimelineClip, TimelinePlayable, TrackAsset, TrackSortWrapper, TrackType, Transform, TransformAnimationPlayable, TransformPlayableAsset, TransformTrack, VFXItem, ValueGetter, Vector4Curve, Vector4PropertyPlayableAsset, Vector4PropertyTrack, addByOrder, addItem, addItemWithOrder, applyMixins, assertExist, asserts, base64ToFile, blend, calculateTranslation, canvasPool, colorGradingFrag, colorStopsFromGradient, colorToArr$1 as colorToArr, combineImageTemplate, createCopyShader, createGLContext, createKeyFrameMeta, createShape, createValueGetter, decimalEqual, defaultPlugins, deserializeMipmapTexture, earcut, effectsClass, effectsClassStore, enlargeBuffer, ensureFixedNumber, ensureVec3, findPreviousRenderPass, gaussianDown_frag as gaussianDownFrag, gaussianDownHFrag, gaussianDownVFrag, gaussianUpFrag, generateEmptyTypedArray, generateGUID, generateHalfFloatTexture, generateTransparentTexture, generateWhiteTexture, getBackgroundImage, getColorFromGradientStops, getConfig, getDefaultTextureFactory, getGeometryByShape, getGeometryTriangles, getImageItemRenderInfo, getKTXTextureOptions, getKeyFrameMetaByRawValue, getMergedStore, getParticleMeshShader, getPixelRatio, getPreMultiAlpha, getStandardComposition, getStandardImage, getStandardItem, getStandardJSON, getTextureSize, glContext, glType2VertexFormatType, gpuTimer, imageDataFromColor, imageDataFromGradient, initErrors, initGLContext, integrate, interpolateColor, isAlipayMiniApp, isAndroid, isArray, isCanvas, isFunction, isIOS, isIOSByUA, isMiniProgram, isObject, isSimulatorCellPhone, isString, isUniformStruct, isUniformStructArray, isValidFontFamily, isWebGL2, isWechatMiniApp, itemFrag, itemFrameFrag, itemVert, loadAVIFOptional, loadBinary, loadBlob, loadImage, loadMedia, loadVideo, loadWebPOptional, logger, index as math, maxSpriteMeshItemCount, modifyMaxKeyframeShader, nearestPowerOfTwo, noop, normalizeColor, numberToFix, parsePercent$1 as parsePercent, particleFrag, particleOriginTranslateMap$1 as particleOriginTranslateMap, particleUniformTypeMap, particleVert, passRenderLevel, pluginLoaderMap, randomInRange, registerPlugin, removeItem, rotateVec2, screenMeshVert, serialize, setBlendMode, setConfig, setDefaultTextureFactory, setMaskMode, setMaxSpriteMeshItemCount, setRayFromCamera, setSideMode, setSpriteMeshMaxItemCountByGPU, sortByOrder, index$1 as spec, spriteMeshShaderFromFilter, spriteMeshShaderFromRenderInfo, spriteMeshShaderIdFromRenderInfo, thresholdFrag, throwDestroyedError, trailVert, translatePoint, trianglesFromRect, unregisterPlugin, valIfUndefined, value, valueDefine, vecFill, vecMulCombine, version, vertexFormatType2GLType };
|
|
31338
|
+
export { AbstractPlugin, ActivationPlayable, ActivationPlayableAsset, ActivationTrack, AnimationClip, AnimationClipPlayable, Asset, AssetLoader, AssetManager, BYTES_TYPE_MAP, BaseRenderComponent, Behaviour, BezierCurve, BezierCurvePath, BezierCurveQuat, BinaryAsset, COMPRESSED_TEXTURE, COPY_FRAGMENT_SHADER, COPY_MESH_SHADER_ID, COPY_VERTEX_SHADER, CalculateLoader, Camera, CameraController, CameraVFXItemLoader, ColorCurve, ColorPropertyPlayableAsset, ColorPropertyTrack, Component, Composition, CompositionComponent, CompositionSourceManager, DEFAULT_FONTS, DEFAULT_FPS, Database, DestroyOptions, Downloader, EFFECTS_COPY_MESH_NAME, EVENT_TYPE_CLICK, EVENT_TYPE_TOUCH_END, EVENT_TYPE_TOUCH_MOVE, EVENT_TYPE_TOUCH_START, EffectComponent, EffectsObject, EffectsPackage, Engine, EventEmitter, EventSystem, Fake3DAnimationMode, Fake3DComponent, FilterMode, Float16ArrayWrapper, FloatPropertyPlayableAsset, FloatPropertyTrack, Framebuffer, GLSLVersion, GPUCapability, Geometry, GlobalUniforms, GradientValue, HELP_LINK, HitTestType, InteractComponent, InteractLoader, InteractMesh, Item, KTXTexture, LineSegments, LinearValue, Material, MaterialDataBlock, MaterialRenderType, MaterialTrack, Mesh, MeshCollider, ObjectBindingTrack, OrderType, PLAYER_OPTIONS_ENV_EDITOR, POST_PROCESS_SETTINGS, ParticleBehaviourPlayable, ParticleBehaviourPlayableAsset, ParticleLoader, ParticleMesh, ParticleSystem, ParticleSystemRenderer, ParticleTrack, PassTextureCache, PathSegments, PluginSystem, PostProcessVolume, PropertyTrack, RENDER_PASS_NAME_PREFIX, RENDER_PREFER_LOOKUP_TEXTURE, RUNTIME_ENV, RandomSetValue, RandomValue, RandomVectorValue, RenderFrame, RenderPass, RenderPassAttachmentStorageType, RenderPassDestroyAttachmentType, RenderPassPriorityNormal, RenderPassPriorityPostprocess, RenderPassPriorityPrepare, RenderTargetHandle, RenderTextureFormat, Renderbuffer, Renderer, RendererComponent, RuntimeClip, SEMANTIC_MAIN_PRE_COLOR_ATTACHMENT_0, SEMANTIC_MAIN_PRE_COLOR_ATTACHMENT_SIZE_0, SEMANTIC_PRE_COLOR_ATTACHMENT_0, SEMANTIC_PRE_COLOR_ATTACHMENT_SIZE_0, SPRITE_VERTEX_STRIDE, Scene, SemanticMap, SerializationHelper, Shader, ShaderCompileResultStatus, ShaderFactory, ShaderType, ShaderVariant, ShapeComponent, SpriteColorPlayableAsset, SpriteColorTrack, SpriteComponent, SpriteLoader, StaticValue, SubCompositionPlayableAsset, SubCompositionTrack, TEMPLATE_USE_OFFSCREEN_CANVAS, TextComponent, TextComponentBase, TextLayout, TextLoader, TextStyle, Texture, TextureFactory, TextureLoadAction, TextureSourceType, TextureStoreAction, Ticker, TimelineAsset, TimelineClip, TimelinePlayable, TrackAsset, TrackSortWrapper, TrackType, Transform, TransformAnimationPlayable, TransformPlayableAsset, TransformTrack, VFXItem, ValueGetter, Vector4Curve, Vector4PropertyPlayableAsset, Vector4PropertyTrack, addByOrder, addItem, addItemWithOrder, applyMixins, assertExist, asserts, base64ToFile, blend, calculateTranslation, canvasPool, colorGradingFrag, colorStopsFromGradient, colorToArr$1 as colorToArr, combineImageTemplate, createCopyShader, createGLContext, createKeyFrameMeta, createShape, createValueGetter, decimalEqual, defaultPlugins, deserializeMipmapTexture, earcut, effectsClass, effectsClassStore, enlargeBuffer, ensureFixedNumber, ensureVec3, findPreviousRenderPass, gaussianDown_frag as gaussianDownFrag, gaussianDownHFrag, gaussianDownVFrag, gaussianUpFrag, generateEmptyTypedArray, generateGUID, generateHalfFloatTexture, generateTransparentTexture, generateWhiteTexture, getBackgroundImage, getColorFromGradientStops, getConfig, getDefaultTextureFactory, getGeometryByShape, getGeometryTriangles, getImageItemRenderInfo, getKTXTextureOptions, getKeyFrameMetaByRawValue, getMergedStore, getParticleMeshShader, getPixelRatio, getPreMultiAlpha, getStandardComposition, getStandardImage, getStandardItem, getStandardJSON, getTextureSize, glContext, glType2VertexFormatType, gpuTimer, imageDataFromColor, imageDataFromGradient, initErrors, initGLContext, integrate, interpolateColor, isAlipayMiniApp, isAndroid, isArray, isCanvas, isFunction, isIOS, isIOSByUA, isMiniProgram, isObject, isSimulatorCellPhone, isString, isUniformStruct, isUniformStructArray, isValidFontFamily, isWebGL2, isWechatMiniApp, itemFrag, itemFrameFrag, itemVert, loadAVIFOptional, loadBinary, loadBlob, loadImage, loadMedia, loadVideo, loadWebPOptional, logger, index as math, maxSpriteMeshItemCount, modifyMaxKeyframeShader, nearestPowerOfTwo, noop, normalizeColor, numberToFix, parsePercent$1 as parsePercent, particleFrag, particleOriginTranslateMap$1 as particleOriginTranslateMap, particleUniformTypeMap, particleVert, passRenderLevel, pluginLoaderMap, randomInRange, registerPlugin, removeItem, rotateVec2, screenMeshVert, serialize, setBlendMode, setConfig, setDefaultTextureFactory, setMaskMode, setMaxSpriteMeshItemCount, setRayFromCamera, setSideMode, setSpriteMeshMaxItemCountByGPU, sortByOrder, index$1 as spec, spriteMeshShaderFromFilter, spriteMeshShaderFromRenderInfo, spriteMeshShaderIdFromRenderInfo, thresholdFrag, throwDestroyedError, trailVert, translatePoint, trianglesFromRect, unregisterPlugin, valIfUndefined, value, valueDefine, vecFill, vecMulCombine, version, vertexFormatType2GLType };
|
|
31388
31339
|
//# sourceMappingURL=index.mjs.map
|