@galacean/effects-core 2.0.0-alpha.31 → 2.0.0-alpha.33
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/composition.d.ts +17 -40
- package/dist/effects-object.d.ts +3 -1
- package/dist/events/event-emitter.d.ts +46 -0
- package/dist/events/index.d.ts +2 -0
- package/dist/events/types.d.ts +37 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.js +246 -157
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +246 -158
- package/dist/index.mjs.map +1 -1
- package/dist/material/material.d.ts +3 -1
- package/dist/plugins/particle/link.d.ts +1 -0
- package/dist/plugins/particle/particle-mesh.d.ts +0 -5
- package/dist/plugins/particle/particle-system.d.ts +8 -2
- package/dist/render/render-frame.d.ts +1 -0
- package/dist/render/renderer.d.ts +2 -1
- package/dist/vfx-item.d.ts +0 -1
- 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.0.0-alpha.
|
|
6
|
+
* Version: v2.0.0-alpha.33
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
|
|
@@ -4563,15 +4563,97 @@ function getDirectStore(target) {
|
|
|
4563
4563
|
return decoratorInitialStore.get(classKey);
|
|
4564
4564
|
}
|
|
4565
4565
|
|
|
4566
|
+
function _assert_this_initialized(self) {
|
|
4567
|
+
if (self === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
4568
|
+
return self;
|
|
4569
|
+
}
|
|
4570
|
+
|
|
4571
|
+
var EventEmitter = function EventEmitter() {
|
|
4572
|
+
var _this = this;
|
|
4573
|
+
var _this1 = this;
|
|
4574
|
+
this.listeners = {};
|
|
4575
|
+
/**
|
|
4576
|
+
* 移除事件监听器
|
|
4577
|
+
* @param eventName - 事件名称
|
|
4578
|
+
* @param listener - 事件监听器
|
|
4579
|
+
* @returns
|
|
4580
|
+
*/ this.off = function(eventName, listener) {
|
|
4581
|
+
if (!_this.listeners[eventName]) {
|
|
4582
|
+
return;
|
|
4583
|
+
}
|
|
4584
|
+
_this.listeners[eventName] = _this.listeners[eventName].filter(function(param) {
|
|
4585
|
+
var l = param.listener;
|
|
4586
|
+
return l !== listener;
|
|
4587
|
+
});
|
|
4588
|
+
};
|
|
4589
|
+
/**
|
|
4590
|
+
* 监听事件
|
|
4591
|
+
* @param eventName - 事件名称
|
|
4592
|
+
* @param listener - 事件监听器
|
|
4593
|
+
* @param options - 事件监听器选项
|
|
4594
|
+
* @returns
|
|
4595
|
+
*/ this.on = function(eventName, listener, options) {
|
|
4596
|
+
_this.listeners[eventName] = _this.listeners[eventName] || [];
|
|
4597
|
+
_this.listeners[eventName].push({
|
|
4598
|
+
listener: listener,
|
|
4599
|
+
options: options
|
|
4600
|
+
});
|
|
4601
|
+
return function() {
|
|
4602
|
+
return _this.off(eventName, listener);
|
|
4603
|
+
};
|
|
4604
|
+
};
|
|
4605
|
+
/**
|
|
4606
|
+
* 一次性监听事件
|
|
4607
|
+
* @param eventName - 事件名称
|
|
4608
|
+
* @param listener - 事件监听器
|
|
4609
|
+
*/ this.once = function(eventName, listener) {
|
|
4610
|
+
_this.on(eventName, listener, {
|
|
4611
|
+
once: true
|
|
4612
|
+
});
|
|
4613
|
+
};
|
|
4614
|
+
/**
|
|
4615
|
+
* 触发事件
|
|
4616
|
+
* @param eventName - 事件名称
|
|
4617
|
+
* @param args - 事件参数
|
|
4618
|
+
*/ this.emit = function(eventName) {
|
|
4619
|
+
for(var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++){
|
|
4620
|
+
args[_key - 1] = arguments[_key];
|
|
4621
|
+
}
|
|
4622
|
+
var _this_listeners_eventName;
|
|
4623
|
+
(_this_listeners_eventName = _this1.listeners[eventName]) == null ? void 0 : _this_listeners_eventName.forEach(function(param) {
|
|
4624
|
+
var listener = param.listener, options = param.options;
|
|
4625
|
+
listener.apply(void 0, [].concat(args));
|
|
4626
|
+
if (options == null ? void 0 : options.once) {
|
|
4627
|
+
_this1.off(eventName, listener);
|
|
4628
|
+
}
|
|
4629
|
+
});
|
|
4630
|
+
};
|
|
4631
|
+
/**
|
|
4632
|
+
* 获取事件名称对应的所有监听器
|
|
4633
|
+
* @param eventName - 事件名称
|
|
4634
|
+
* @returns - 返回事件名称对应的所有监听器
|
|
4635
|
+
*/ this.getListeners = function(eventName) {
|
|
4636
|
+
var _this_listeners_eventName;
|
|
4637
|
+
return ((_this_listeners_eventName = _this.listeners[eventName]) == null ? void 0 : _this_listeners_eventName.map(function(param) {
|
|
4638
|
+
var listener = param.listener;
|
|
4639
|
+
return listener;
|
|
4640
|
+
})) || [];
|
|
4641
|
+
};
|
|
4642
|
+
};
|
|
4643
|
+
|
|
4566
4644
|
/**
|
|
4567
4645
|
* @since 2.0.0
|
|
4568
4646
|
* @internal
|
|
4569
|
-
*/ var EffectsObject = /*#__PURE__*/ function() {
|
|
4647
|
+
*/ var EffectsObject = /*#__PURE__*/ function(EventEmitter) {
|
|
4648
|
+
_inherits(EffectsObject, EventEmitter);
|
|
4570
4649
|
function EffectsObject(engine) {
|
|
4571
|
-
|
|
4572
|
-
|
|
4573
|
-
|
|
4574
|
-
|
|
4650
|
+
var _this;
|
|
4651
|
+
_this = EventEmitter.call(this) || this;
|
|
4652
|
+
_this.engine = engine;
|
|
4653
|
+
_this.guid = generateGUID();
|
|
4654
|
+
_this.taggedProperties = {};
|
|
4655
|
+
_this.engine.addInstance(_assert_this_initialized(_this));
|
|
4656
|
+
return _this;
|
|
4575
4657
|
}
|
|
4576
4658
|
var _proto = EffectsObject.prototype;
|
|
4577
4659
|
_proto.getInstanceId = function getInstanceId() {
|
|
@@ -4597,7 +4679,7 @@ function getDirectStore(target) {
|
|
|
4597
4679
|
return _instanceof1(obj, EffectsObject) && "guid" in obj;
|
|
4598
4680
|
};
|
|
4599
4681
|
return EffectsObject;
|
|
4600
|
-
}();
|
|
4682
|
+
}(EventEmitter);
|
|
4601
4683
|
|
|
4602
4684
|
/**
|
|
4603
4685
|
* @since 2.0.0
|
|
@@ -8987,6 +9069,9 @@ var MaterialRenderType;
|
|
|
8987
9069
|
* 初始化 GPU 资源
|
|
8988
9070
|
* @override
|
|
8989
9071
|
*/ _proto.initialize = function initialize() {
|
|
9072
|
+
// OVERRIDE
|
|
9073
|
+
};
|
|
9074
|
+
_proto.createShaderVariant = function createShaderVariant() {
|
|
8990
9075
|
// OVERRIDE
|
|
8991
9076
|
};
|
|
8992
9077
|
_proto.use = function use(render, globalUniforms) {
|
|
@@ -12697,6 +12782,7 @@ var GlobalUniforms = function GlobalUniforms() {
|
|
|
12697
12782
|
this.floats = {};
|
|
12698
12783
|
this.ints = {};
|
|
12699
12784
|
// vector3s: Record<string, vec3> = {};
|
|
12785
|
+
this.vector4s = {};
|
|
12700
12786
|
this.matrices = {};
|
|
12701
12787
|
//...
|
|
12702
12788
|
this.samplers = [] // 存放的sampler名称。
|
|
@@ -12933,6 +13019,9 @@ var Renderer = /*#__PURE__*/ function() {
|
|
|
12933
13019
|
_proto.setGlobalInt = function setGlobalInt(name, value) {
|
|
12934
13020
|
// OVERRIDE
|
|
12935
13021
|
};
|
|
13022
|
+
_proto.setGlobalVector4 = function setGlobalVector4(name, value) {
|
|
13023
|
+
// OVERRIDE
|
|
13024
|
+
};
|
|
12936
13025
|
_proto.setGlobalMatrix = function setGlobalMatrix(name, value) {
|
|
12937
13026
|
// OVERRIDE
|
|
12938
13027
|
};
|
|
@@ -13478,11 +13567,6 @@ var SpriteLoader = /*#__PURE__*/ function(AbstractPlugin) {
|
|
|
13478
13567
|
return SpriteLoader;
|
|
13479
13568
|
}(AbstractPlugin);
|
|
13480
13569
|
|
|
13481
|
-
function _assert_this_initialized(self) {
|
|
13482
|
-
if (self === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
13483
|
-
return self;
|
|
13484
|
-
}
|
|
13485
|
-
|
|
13486
13570
|
/**
|
|
13487
13571
|
* 动画图,负责更新所有的动画节点
|
|
13488
13572
|
* @since 2.0.0
|
|
@@ -15919,6 +16003,17 @@ var Link = /*#__PURE__*/ function() {
|
|
|
15919
16003
|
}while (node = node.pre);
|
|
15920
16004
|
}
|
|
15921
16005
|
};
|
|
16006
|
+
_proto.getNodeByIndex = function getNodeByIndex(index) {
|
|
16007
|
+
var i = 0, res = this.first;
|
|
16008
|
+
if (!res || index >= this.length || index < 0) {
|
|
16009
|
+
return null;
|
|
16010
|
+
}
|
|
16011
|
+
while(i < index){
|
|
16012
|
+
res = res.next;
|
|
16013
|
+
i++;
|
|
16014
|
+
}
|
|
16015
|
+
return res;
|
|
16016
|
+
};
|
|
15922
16017
|
return Link;
|
|
15923
16018
|
}();
|
|
15924
16019
|
|
|
@@ -16755,10 +16850,8 @@ var ParticleSystem = /*#__PURE__*/ function(Component) {
|
|
|
16755
16850
|
content[3].delay -= duration;
|
|
16756
16851
|
});
|
|
16757
16852
|
this.renderer.minusTimeForLoop(duration);
|
|
16758
|
-
this.onIterate(this);
|
|
16759
16853
|
} else {
|
|
16760
16854
|
this.ended = true;
|
|
16761
|
-
this.onEnd(this);
|
|
16762
16855
|
var endBehavior = this.item.endBehavior;
|
|
16763
16856
|
if (endBehavior === EndBehavior.freeze) {
|
|
16764
16857
|
this.frozen = true;
|
|
@@ -16906,7 +16999,21 @@ var ParticleSystem = /*#__PURE__*/ function(Component) {
|
|
|
16906
16999
|
time: startTime
|
|
16907
17000
|
});
|
|
16908
17001
|
};
|
|
16909
|
-
|
|
17002
|
+
/**
|
|
17003
|
+
* 通过索引获取指定index粒子当前时刻的位置
|
|
17004
|
+
* @params index - 粒子索引
|
|
17005
|
+
*/ _proto.getPointPositionByIndex = function getPointPositionByIndex(index) {
|
|
17006
|
+
var point = this.particleLink.getNodeByIndex(index);
|
|
17007
|
+
if (!point) {
|
|
17008
|
+
console.error("Get point error.");
|
|
17009
|
+
return null;
|
|
17010
|
+
} else {
|
|
17011
|
+
return this.getPointPosition(point.content[3]);
|
|
17012
|
+
}
|
|
17013
|
+
};
|
|
17014
|
+
/**
|
|
17015
|
+
* 通过粒子参数获取当前时刻粒子的位置
|
|
17016
|
+
*/ _proto.getPointPosition = function getPointPosition(point) {
|
|
16910
17017
|
var transform = point.transform, vel = point.vel, lifetime = point.lifetime, delay = point.delay, _point_gravity = point.gravity, gravity = _point_gravity === void 0 ? [] : _point_gravity;
|
|
16911
17018
|
var forceTarget = this.options.forceTarget;
|
|
16912
17019
|
var time = this.lastUpdate - delay;
|
|
@@ -16928,8 +17035,6 @@ var ParticleSystem = /*#__PURE__*/ function(Component) {
|
|
|
16928
17035
|
}
|
|
16929
17036
|
return ret;
|
|
16930
17037
|
};
|
|
16931
|
-
_proto.onEnd = function onEnd(particle) {};
|
|
16932
|
-
_proto.onIterate = function onIterate(particle) {};
|
|
16933
17038
|
_proto.initPoint = function initPoint(data) {
|
|
16934
17039
|
var options = this.options;
|
|
16935
17040
|
var lifetime = this.lifetime;
|
|
@@ -17888,31 +17993,6 @@ var ParticleMesh = /*#__PURE__*/ function() {
|
|
|
17888
17993
|
data[i + 3]
|
|
17889
17994
|
];
|
|
17890
17995
|
};
|
|
17891
|
-
/**
|
|
17892
|
-
* 待废弃
|
|
17893
|
-
* @deprecated - 使用 `particle-system.getPointPosition` 替代
|
|
17894
|
-
*/ _proto.getPointPosition = function getPointPosition(index) {
|
|
17895
|
-
var geo = this.geometry;
|
|
17896
|
-
var posIndex = index * 48;
|
|
17897
|
-
var posData = geo.getAttributeData("aPos");
|
|
17898
|
-
var offsetData = geo.getAttributeData("aOffset");
|
|
17899
|
-
var time = this.time - offsetData[index * 16 + 2];
|
|
17900
|
-
var pointDur = offsetData[index * 16 + 3];
|
|
17901
|
-
var mtl = this.mesh.material;
|
|
17902
|
-
var acc = mtl.getVector4("uAcceleration").toVector3();
|
|
17903
|
-
var pos = Vector3.fromArray(posData, posIndex);
|
|
17904
|
-
var vel = Vector3.fromArray(posData, posIndex + 3);
|
|
17905
|
-
var ret = calculateTranslation(new Vector3(), this, acc, time, pointDur, pos, vel);
|
|
17906
|
-
if (this.forceTarget) {
|
|
17907
|
-
var target = mtl.getVector3("uFinalTarget");
|
|
17908
|
-
var life = this.forceTarget.curve.getValue(time / pointDur);
|
|
17909
|
-
var dl = 1 - life;
|
|
17910
|
-
ret.x = ret.x * dl + target.x * life;
|
|
17911
|
-
ret.y = ret.y * dl + target.y * life;
|
|
17912
|
-
ret.z = ret.z * dl + target.z * life;
|
|
17913
|
-
}
|
|
17914
|
-
return ret;
|
|
17915
|
-
};
|
|
17916
17996
|
_proto.clearPoints = function clearPoints() {
|
|
17917
17997
|
this.resetGeometryData(this.geometry);
|
|
17918
17998
|
this.particleCount = 0;
|
|
@@ -19303,10 +19383,6 @@ function compareTracks(a, b) {
|
|
|
19303
19383
|
};
|
|
19304
19384
|
_proto.update = function update(dt) {
|
|
19305
19385
|
var time = this.time;
|
|
19306
|
-
// 主合成 rootItem 没有绑定轨道,增加结束行为判断。
|
|
19307
|
-
if (this.item.isEnded(this.time) && !this.item.parent) {
|
|
19308
|
-
this.item.ended = true;
|
|
19309
|
-
}
|
|
19310
19386
|
this.timelinePlayable.setTime(time);
|
|
19311
19387
|
this.graph.evaluate(dt);
|
|
19312
19388
|
};
|
|
@@ -19439,6 +19515,8 @@ function compareTracks(a, b) {
|
|
|
19439
19515
|
hitPositions: hitPositions,
|
|
19440
19516
|
behavior: hitParams.behavior
|
|
19441
19517
|
};
|
|
19518
|
+
// 触发单个元素的点击事件
|
|
19519
|
+
item.emit("click", region);
|
|
19442
19520
|
regions.push(region);
|
|
19443
19521
|
if (stop(region)) {
|
|
19444
19522
|
return {
|
|
@@ -20674,8 +20752,6 @@ var VFXItem = /*#__PURE__*/ function(EffectsObject) {
|
|
|
20674
20752
|
this.parentId = parentId;
|
|
20675
20753
|
this.duration = duration;
|
|
20676
20754
|
this.endBehavior = endBehavior;
|
|
20677
|
-
//@ts-expect-error
|
|
20678
|
-
this.oldId = data.oldId;
|
|
20679
20755
|
if (!data.content) {
|
|
20680
20756
|
data.content = {
|
|
20681
20757
|
options: {}
|
|
@@ -24684,89 +24760,93 @@ var listOrder = 0;
|
|
|
24684
24760
|
* 合成抽象类:核心对象,通常一个场景只包含一个合成,可能会有多个合成。
|
|
24685
24761
|
* 合成中包含了相关的 Item 元素,支持对 Item 元素的创建、更新和销毁。
|
|
24686
24762
|
* 也负责 Item 相关的动画播放控制,和持有渲染帧数据。
|
|
24687
|
-
*/ var Composition = /*#__PURE__*/ function() {
|
|
24763
|
+
*/ var Composition = /*#__PURE__*/ function(EventEmitter) {
|
|
24764
|
+
_inherits(Composition, EventEmitter);
|
|
24688
24765
|
function Composition(props, scene) {
|
|
24689
|
-
var _this
|
|
24766
|
+
var _this;
|
|
24767
|
+
_this = EventEmitter.call(this) || this;
|
|
24690
24768
|
/**
|
|
24691
24769
|
* 动画播放速度
|
|
24692
|
-
*/
|
|
24770
|
+
*/ _this.speed = 1;
|
|
24693
24771
|
/**
|
|
24694
24772
|
* 用于保存与当前合成相关的插件数据
|
|
24695
|
-
*/
|
|
24773
|
+
*/ _this.loaderData = {};
|
|
24696
24774
|
/**
|
|
24697
24775
|
* 预合成数组
|
|
24698
|
-
*/
|
|
24776
|
+
*/ _this.refContent = [];
|
|
24699
24777
|
/**
|
|
24700
24778
|
* 预合成的合成属性,在 content 中会被其元素属性覆盖
|
|
24701
|
-
*/
|
|
24779
|
+
*/ _this.refCompositionProps = new Map();
|
|
24702
24780
|
// TODO: 待优化
|
|
24703
|
-
|
|
24781
|
+
_this.assigned = false;
|
|
24704
24782
|
/**
|
|
24705
24783
|
* 销毁状态位
|
|
24706
|
-
*/
|
|
24707
|
-
|
|
24784
|
+
*/ _this.destroyed = false;
|
|
24785
|
+
_this.postLoaders = [];
|
|
24708
24786
|
/**
|
|
24709
24787
|
* 合成暂停/播放 标识
|
|
24710
|
-
*/
|
|
24711
|
-
|
|
24712
|
-
var _props_reusable = props.reusable, reusable = _props_reusable === void 0 ? false : _props_reusable, _props_speed = props.speed, speed = _props_speed === void 0 ? 1 : _props_speed, _props_baseRenderOrder = props.baseRenderOrder, baseRenderOrder = _props_baseRenderOrder === void 0 ? 0 : _props_baseRenderOrder, renderer = props.renderer,
|
|
24713
|
-
|
|
24788
|
+
*/ _this.paused = false;
|
|
24789
|
+
_this.lastVideoUpdateTime = 0;
|
|
24790
|
+
var _props_reusable = props.reusable, reusable = _props_reusable === void 0 ? false : _props_reusable, _props_speed = props.speed, speed = _props_speed === void 0 ? 1 : _props_speed, _props_baseRenderOrder = props.baseRenderOrder, baseRenderOrder = _props_baseRenderOrder === void 0 ? 0 : _props_baseRenderOrder, renderer = props.renderer, event = props.event, width = props.width, height = props.height, handleItemMessage = props.handleItemMessage;
|
|
24791
|
+
_this.compositionSourceManager = new CompositionSourceManager(scene, renderer.engine);
|
|
24714
24792
|
scene.jsonScene.imgUsage = undefined;
|
|
24715
24793
|
if (reusable) {
|
|
24716
|
-
|
|
24794
|
+
_this.keepResource = true;
|
|
24717
24795
|
scene.textures = undefined;
|
|
24718
24796
|
scene.consumed = true;
|
|
24719
24797
|
}
|
|
24720
|
-
var _this_compositionSourceManager =
|
|
24798
|
+
var _this_compositionSourceManager = _this.compositionSourceManager, sourceContent = _this_compositionSourceManager.sourceContent, pluginSystem = _this_compositionSourceManager.pluginSystem, imgUsage = _this_compositionSourceManager.imgUsage, totalTime = _this_compositionSourceManager.totalTime, refCompositionProps = _this_compositionSourceManager.refCompositionProps;
|
|
24721
24799
|
assertExist(sourceContent);
|
|
24722
|
-
|
|
24723
|
-
|
|
24724
|
-
|
|
24725
|
-
|
|
24726
|
-
|
|
24727
|
-
|
|
24728
|
-
|
|
24800
|
+
_this.renderer = renderer;
|
|
24801
|
+
_this.refCompositionProps = refCompositionProps;
|
|
24802
|
+
_this.rootItem = new VFXItem(_this.getEngine(), sourceContent);
|
|
24803
|
+
_this.rootItem.name = "rootItem";
|
|
24804
|
+
_this.rootItem.composition = _assert_this_initialized(_this);
|
|
24805
|
+
_this.rootComposition = _this.rootItem.addComponent(CompositionComponent);
|
|
24806
|
+
_this.rootComposition.startTime = sourceContent.startTime;
|
|
24807
|
+
_this.rootComposition.data = sourceContent;
|
|
24729
24808
|
var imageUsage = !reusable && imgUsage;
|
|
24730
|
-
|
|
24731
|
-
|
|
24732
|
-
|
|
24733
|
-
|
|
24734
|
-
|
|
24735
|
-
|
|
24736
|
-
|
|
24809
|
+
_this.width = width;
|
|
24810
|
+
_this.height = height;
|
|
24811
|
+
_this.renderOrder = baseRenderOrder;
|
|
24812
|
+
_this.id = sourceContent.id;
|
|
24813
|
+
_this.renderer = renderer;
|
|
24814
|
+
_this.texInfo = imageUsage != null ? imageUsage : {};
|
|
24815
|
+
_this.event = event;
|
|
24737
24816
|
var _scene_startTime, _scene_timeInfos_asyncCompile;
|
|
24738
|
-
|
|
24817
|
+
_this.statistic = {
|
|
24739
24818
|
loadTime: totalTime != null ? totalTime : 0,
|
|
24740
24819
|
loadStart: (_scene_startTime = scene.startTime) != null ? _scene_startTime : 0,
|
|
24741
24820
|
firstFrameTime: 0,
|
|
24742
24821
|
precompileTime: (_scene_timeInfos_asyncCompile = scene.timeInfos["asyncCompile"]) != null ? _scene_timeInfos_asyncCompile : scene.timeInfos["syncCompile"]
|
|
24743
24822
|
};
|
|
24744
|
-
|
|
24745
|
-
|
|
24746
|
-
|
|
24747
|
-
|
|
24748
|
-
|
|
24749
|
-
|
|
24750
|
-
|
|
24823
|
+
_this.reusable = reusable;
|
|
24824
|
+
_this.speed = speed;
|
|
24825
|
+
_this.autoRefTex = !_this.keepResource && imageUsage && _this.rootItem.endBehavior !== EndBehavior.restart;
|
|
24826
|
+
_this.name = sourceContent.name;
|
|
24827
|
+
_this.pluginSystem = pluginSystem;
|
|
24828
|
+
_this.pluginSystem.initializeComposition(_assert_this_initialized(_this), scene);
|
|
24829
|
+
_this.camera = new Camera(_this.name, _extends({}, sourceContent == null ? void 0 : sourceContent.camera, {
|
|
24751
24830
|
aspect: width / height
|
|
24752
24831
|
}));
|
|
24753
|
-
|
|
24754
|
-
|
|
24755
|
-
|
|
24756
|
-
|
|
24757
|
-
|
|
24758
|
-
|
|
24759
|
-
|
|
24760
|
-
|
|
24761
|
-
|
|
24762
|
-
|
|
24763
|
-
this.buildItemTree(this.rootItem);
|
|
24764
|
-
this.rootItem.onEnd = function() {
|
|
24832
|
+
_this.url = scene.url;
|
|
24833
|
+
_this.assigned = true;
|
|
24834
|
+
_this.globalTime = 0;
|
|
24835
|
+
_this.interactive = true;
|
|
24836
|
+
_this.handleItemMessage = handleItemMessage;
|
|
24837
|
+
_this.createRenderFrame();
|
|
24838
|
+
_this.rendererOptions = null;
|
|
24839
|
+
_this.rootComposition.createContent();
|
|
24840
|
+
_this.buildItemTree(_this.rootItem);
|
|
24841
|
+
_this.rootItem.onEnd = function() {
|
|
24765
24842
|
window.setTimeout(function() {
|
|
24766
|
-
_this.
|
|
24843
|
+
_this.emit("end", {
|
|
24844
|
+
composition: _assert_this_initialized(_this)
|
|
24845
|
+
});
|
|
24767
24846
|
}, 0);
|
|
24768
24847
|
};
|
|
24769
|
-
|
|
24848
|
+
_this.pluginSystem.resetComposition(_assert_this_initialized(_this), _this.renderFrame);
|
|
24849
|
+
return _this;
|
|
24770
24850
|
}
|
|
24771
24851
|
var _proto = Composition.prototype;
|
|
24772
24852
|
/**
|
|
@@ -24817,7 +24897,7 @@ var listOrder = 0;
|
|
|
24817
24897
|
if (this.rootItem.ended && this.reusable) {
|
|
24818
24898
|
this.restart();
|
|
24819
24899
|
}
|
|
24820
|
-
if (
|
|
24900
|
+
if (this.rootComposition.started) {
|
|
24821
24901
|
this.gotoAndPlay(this.time - this.startTime);
|
|
24822
24902
|
} else {
|
|
24823
24903
|
this.gotoAndPlay(0);
|
|
@@ -24840,18 +24920,14 @@ var listOrder = 0;
|
|
|
24840
24920
|
* 跳转合成到指定时间播放
|
|
24841
24921
|
* @param time - 相对 startTime 的时间
|
|
24842
24922
|
*/ _proto.gotoAndPlay = function gotoAndPlay(time) {
|
|
24923
|
+
this.setTime(time);
|
|
24843
24924
|
this.resume();
|
|
24844
|
-
if (!this.rootComposition.started) {
|
|
24845
|
-
this.rootComposition.start();
|
|
24846
|
-
this.rootComposition.started = true;
|
|
24847
|
-
}
|
|
24848
|
-
this.forwardTime(time + this.startTime);
|
|
24849
24925
|
};
|
|
24850
24926
|
/**
|
|
24851
24927
|
* 跳转合成到指定时间并暂停
|
|
24852
24928
|
* @param time - 相对 startTime 的时间
|
|
24853
24929
|
*/ _proto.gotoAndStop = function gotoAndStop(time) {
|
|
24854
|
-
this.
|
|
24930
|
+
this.setTime(time);
|
|
24855
24931
|
this.pause();
|
|
24856
24932
|
};
|
|
24857
24933
|
/**
|
|
@@ -24878,7 +24954,7 @@ var listOrder = 0;
|
|
|
24878
24954
|
this.rootComposition.start();
|
|
24879
24955
|
this.rootComposition.started = true;
|
|
24880
24956
|
}
|
|
24881
|
-
this.forwardTime(time + this.startTime
|
|
24957
|
+
this.forwardTime(time + this.startTime);
|
|
24882
24958
|
if (pause) {
|
|
24883
24959
|
this.pause();
|
|
24884
24960
|
}
|
|
@@ -24891,17 +24967,16 @@ var listOrder = 0;
|
|
|
24891
24967
|
* 前进合成到指定时间
|
|
24892
24968
|
* @param time - 相对0时刻的时间
|
|
24893
24969
|
* @param skipRender - 是否跳过渲染
|
|
24894
|
-
*/ _proto.forwardTime = function forwardTime(time
|
|
24895
|
-
if (skipRender === void 0) skipRender = false;
|
|
24970
|
+
*/ _proto.forwardTime = function forwardTime(time) {
|
|
24896
24971
|
var deltaTime = time * 1000 - this.rootComposition.time * 1000;
|
|
24897
24972
|
var reverse = deltaTime < 0;
|
|
24898
24973
|
var step = 15;
|
|
24899
24974
|
var t = Math.abs(deltaTime);
|
|
24900
24975
|
var ss = reverse ? -step : step;
|
|
24901
24976
|
for(t; t > step; t -= step){
|
|
24902
|
-
this.update(ss
|
|
24977
|
+
this.update(ss);
|
|
24903
24978
|
}
|
|
24904
|
-
this.update(reverse ? -t : t
|
|
24979
|
+
this.update(reverse ? -t : t);
|
|
24905
24980
|
};
|
|
24906
24981
|
/**
|
|
24907
24982
|
* 重置状态函数
|
|
@@ -24939,74 +25014,68 @@ var listOrder = 0;
|
|
|
24939
25014
|
}
|
|
24940
25015
|
};
|
|
24941
25016
|
/**
|
|
24942
|
-
* 是否合成需要重新播放
|
|
24943
|
-
* @returns 重新播放合成标志位
|
|
24944
|
-
*/ _proto.shouldRestart = function shouldRestart() {
|
|
24945
|
-
var _this_rootItem = this.rootItem, ended = _this_rootItem.ended, endBehavior = _this_rootItem.endBehavior;
|
|
24946
|
-
return ended && endBehavior === EndBehavior.restart;
|
|
24947
|
-
};
|
|
24948
|
-
/**
|
|
24949
|
-
* 是否合成需要销毁
|
|
24950
|
-
* @returns 销毁合成标志位
|
|
24951
|
-
*/ _proto.shouldDispose = function shouldDispose() {
|
|
24952
|
-
if (this.reusable) {
|
|
24953
|
-
return false;
|
|
24954
|
-
}
|
|
24955
|
-
var _this_rootItem = this.rootItem, ended = _this_rootItem.ended, endBehavior = _this_rootItem.endBehavior;
|
|
24956
|
-
// TODO: 合成结束行为
|
|
24957
|
-
return ended && (!endBehavior || endBehavior === END_BEHAVIOR_PAUSE_AND_DESTROY);
|
|
24958
|
-
};
|
|
24959
|
-
/**
|
|
24960
25017
|
* 合成更新,针对所有 item 的更新
|
|
24961
25018
|
* @param deltaTime - 更新的时间步长
|
|
24962
25019
|
* @param skipRender - 是否需要渲染
|
|
24963
|
-
*/ _proto.update = function update(deltaTime
|
|
24964
|
-
if (skipRender === void 0) skipRender = false;
|
|
25020
|
+
*/ _proto.update = function update(deltaTime) {
|
|
24965
25021
|
if (!this.assigned || this.paused) {
|
|
24966
25022
|
return;
|
|
24967
25023
|
}
|
|
24968
|
-
if (this.shouldRestart()) {
|
|
24969
|
-
this.restart();
|
|
24970
|
-
// restart then tick to avoid flicker
|
|
24971
|
-
}
|
|
24972
25024
|
var time = this.getUpdateTime(deltaTime * this.speed);
|
|
24973
25025
|
this.globalTime += time;
|
|
24974
|
-
|
|
24975
|
-
var localTime = this.toLocalTime(this.globalTime / 1000);
|
|
24976
|
-
this.rootComposition.time = localTime;
|
|
24977
|
-
}
|
|
25026
|
+
this.updateRootComposition();
|
|
24978
25027
|
this.updateVideo();
|
|
24979
25028
|
// 更新 model-tree-plugin
|
|
24980
25029
|
this.updatePluginLoaders(deltaTime);
|
|
25030
|
+
// scene VFXItem components lifetime function.
|
|
24981
25031
|
this.callStart(this.rootItem);
|
|
24982
25032
|
this.callUpdate(this.rootItem, time);
|
|
24983
25033
|
this.callLateUpdate(this.rootItem, time);
|
|
24984
|
-
// this.extraCamera?.getComponent(TimelineComponent)?.update(deltaTime);
|
|
24985
25034
|
this.updateCamera();
|
|
25035
|
+
this.prepareRender();
|
|
24986
25036
|
if (this.shouldDispose()) {
|
|
24987
|
-
this.onEnd == null ? void 0 : this.onEnd.call(this, this);
|
|
24988
25037
|
this.dispose();
|
|
24989
|
-
} else {
|
|
24990
|
-
if (!skipRender) {
|
|
24991
|
-
this.prepareRender();
|
|
24992
|
-
}
|
|
24993
25038
|
}
|
|
24994
25039
|
};
|
|
24995
25040
|
_proto.toLocalTime = function toLocalTime(time) {
|
|
24996
25041
|
var localTime = time - this.rootItem.start;
|
|
24997
25042
|
var duration = this.rootItem.duration;
|
|
24998
25043
|
if (localTime - duration > 0.001) {
|
|
24999
|
-
if (this.rootItem.
|
|
25000
|
-
|
|
25001
|
-
|
|
25002
|
-
|
|
25044
|
+
if (!this.rootItem.ended) {
|
|
25045
|
+
this.rootItem.ended = true;
|
|
25046
|
+
this.emit("end", {
|
|
25047
|
+
composition: this
|
|
25048
|
+
});
|
|
25049
|
+
}
|
|
25050
|
+
switch(this.rootItem.endBehavior){
|
|
25051
|
+
case EndBehavior.restart:
|
|
25052
|
+
{
|
|
25053
|
+
localTime = localTime % duration;
|
|
25054
|
+
this.restart();
|
|
25055
|
+
break;
|
|
25056
|
+
}
|
|
25057
|
+
case EndBehavior.freeze:
|
|
25058
|
+
{
|
|
25059
|
+
localTime = Math.min(duration, localTime);
|
|
25060
|
+
break;
|
|
25061
|
+
}
|
|
25062
|
+
case EndBehavior.forward:
|
|
25063
|
+
{
|
|
25064
|
+
break;
|
|
25065
|
+
}
|
|
25066
|
+
case EndBehavior.destroy:
|
|
25067
|
+
{
|
|
25068
|
+
break;
|
|
25069
|
+
}
|
|
25003
25070
|
}
|
|
25004
25071
|
}
|
|
25005
25072
|
return localTime;
|
|
25006
25073
|
};
|
|
25074
|
+
_proto.shouldDispose = function shouldDispose() {
|
|
25075
|
+
return this.rootItem.ended && this.rootItem.endBehavior === EndBehavior.destroy && !this.reusable;
|
|
25076
|
+
};
|
|
25007
25077
|
_proto.getUpdateTime = function getUpdateTime(t) {
|
|
25008
25078
|
var startTimeInMs = this.startTime * 1000;
|
|
25009
|
-
// const content = this.rootItem;
|
|
25010
25079
|
var now = this.rootComposition.time * 1000;
|
|
25011
25080
|
if (t < 0 && now + t < startTimeInMs) {
|
|
25012
25081
|
return startTimeInMs - now;
|
|
@@ -25154,6 +25223,14 @@ var listOrder = 0;
|
|
|
25154
25223
|
});
|
|
25155
25224
|
};
|
|
25156
25225
|
/**
|
|
25226
|
+
* 更新主合成组件
|
|
25227
|
+
*/ _proto.updateRootComposition = function updateRootComposition() {
|
|
25228
|
+
if (this.rootComposition.isActiveAndEnabled) {
|
|
25229
|
+
var localTime = this.toLocalTime(this.globalTime / 1000);
|
|
25230
|
+
this.rootComposition.time = localTime;
|
|
25231
|
+
}
|
|
25232
|
+
};
|
|
25233
|
+
/**
|
|
25157
25234
|
* 通过名称获取元素
|
|
25158
25235
|
* @param name - 元素名称
|
|
25159
25236
|
* @returns 元素对象
|
|
@@ -25202,12 +25279,17 @@ var listOrder = 0;
|
|
|
25202
25279
|
* @param type - 交互类型
|
|
25203
25280
|
*/ _proto.addInteractiveItem = function addInteractiveItem(item, type) {
|
|
25204
25281
|
if (type === InteractType.MESSAGE) {
|
|
25205
|
-
this.
|
|
25282
|
+
this.handleItemMessage({
|
|
25206
25283
|
name: item.name,
|
|
25207
25284
|
phrase: MESSAGE_ITEM_PHRASE_BEGIN,
|
|
25208
25285
|
id: item.id,
|
|
25209
25286
|
compositionId: this.id
|
|
25210
25287
|
});
|
|
25288
|
+
item.emit("message", {
|
|
25289
|
+
name: item.name,
|
|
25290
|
+
phrase: MESSAGE_ITEM_PHRASE_BEGIN,
|
|
25291
|
+
id: item.id
|
|
25292
|
+
});
|
|
25211
25293
|
return item.id;
|
|
25212
25294
|
}
|
|
25213
25295
|
};
|
|
@@ -25216,14 +25298,19 @@ var listOrder = 0;
|
|
|
25216
25298
|
* @param item - 交互元素
|
|
25217
25299
|
* @param type - 交互类型
|
|
25218
25300
|
*/ _proto.removeInteractiveItem = function removeInteractiveItem(item, type) {
|
|
25219
|
-
// MESSAGE ITEM的结束行为
|
|
25301
|
+
// MESSAGE ITEM 的结束行为
|
|
25220
25302
|
if (type === InteractType.MESSAGE) {
|
|
25221
|
-
this.
|
|
25303
|
+
this.handleItemMessage({
|
|
25222
25304
|
name: item.name,
|
|
25223
25305
|
phrase: MESSAGE_ITEM_PHRASE_END,
|
|
25224
25306
|
id: item.id,
|
|
25225
25307
|
compositionId: this.id
|
|
25226
25308
|
});
|
|
25309
|
+
item.emit("message", {
|
|
25310
|
+
name: item.name,
|
|
25311
|
+
phrase: MESSAGE_ITEM_PHRASE_END,
|
|
25312
|
+
id: item.id
|
|
25313
|
+
});
|
|
25227
25314
|
}
|
|
25228
25315
|
};
|
|
25229
25316
|
/**
|
|
@@ -25317,9 +25404,10 @@ var listOrder = 0;
|
|
|
25317
25404
|
(_this_rendererOptions = this.rendererOptions) == null ? void 0 : _this_rendererOptions.emptyTexture.dispose();
|
|
25318
25405
|
(_this_pluginSystem = this.pluginSystem) == null ? void 0 : _this_pluginSystem.destroyComposition(this);
|
|
25319
25406
|
this.update = function() {
|
|
25320
|
-
|
|
25407
|
+
{
|
|
25408
|
+
logger.error("Update disposed composition: " + _this.name + ".");
|
|
25409
|
+
}
|
|
25321
25410
|
};
|
|
25322
|
-
this.onPlayerPause = noop;
|
|
25323
25411
|
this.dispose = noop;
|
|
25324
25412
|
if (textures && this.keepResource) {
|
|
25325
25413
|
textures.forEach(function(tex) {
|
|
@@ -25517,7 +25605,7 @@ var listOrder = 0;
|
|
|
25517
25605
|
}
|
|
25518
25606
|
]);
|
|
25519
25607
|
return Composition;
|
|
25520
|
-
}();
|
|
25608
|
+
}(EventEmitter);
|
|
25521
25609
|
|
|
25522
25610
|
var SIZEOF_SHORT = 2;
|
|
25523
25611
|
var SIZEOF_INT = 4;
|
|
@@ -27481,8 +27569,8 @@ registerPlugin("sprite", SpriteLoader, VFXItem, true);
|
|
|
27481
27569
|
registerPlugin("particle", ParticleLoader, VFXItem, true);
|
|
27482
27570
|
registerPlugin("cal", CalculateLoader, VFXItem, true);
|
|
27483
27571
|
registerPlugin("interact", InteractLoader, VFXItem, true);
|
|
27484
|
-
var version = "2.0.0-alpha.
|
|
27572
|
+
var version = "2.0.0-alpha.33";
|
|
27485
27573
|
logger.info("Core version: " + version + ".");
|
|
27486
27574
|
|
|
27487
|
-
export { AbstractPlugin, ActivationPlayable, ActivationPlayableAsset, ActivationTrack, AnimationClip, AnimationClipPlayable, AssetLoader, AssetManager, BYTES_TYPE_MAP, Behaviour, BezierCurve, BezierCurvePath, BezierCurveQuat, BinaryAsset, COMPRESSED_TEXTURE, COPY_FRAGMENT_SHADER, COPY_MESH_SHADER_ID, COPY_VERTEX_SHADER, CalculateLoader, Camera, CameraController, CameraVFXItemLoader, Component, Composition, CompositionComponent, CompositionSourceManager, DEFAULT_FONTS, 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, EventSystem, FilterMode, Float16ArrayWrapper, Framebuffer, GLSLVersion, GPUCapability, Geometry, GlobalUniforms, GradientValue, HELP_LINK, HitTestType, InteractComponent, InteractLoader, InteractMesh, Item, ItemBehaviour, KTXTexture, LineSegments, LinearValue, Material, MaterialDataBlock, MaterialRenderType, Mesh, ObjectBindingTrack, OrderType, PLAYER_OPTIONS_ENV_EDITOR, POST_PROCESS_SETTINGS, ParticleBehaviourPlayable, ParticleBehaviourPlayableAsset, ParticleLoader, ParticleMesh, ParticleSystem, ParticleSystemRenderer, PassTextureCache, PathSegments, PluginSystem, PostProcessVolume, 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, SemanticMap, SerializationHelper, Shader, ShaderCompileResultStatus, ShaderType, ShaderVariant, SpriteColorPlayable, 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, addByOrder, addItem, addItemWithOrder, applyMixins, assertExist, asserts, base64ToFile, blend, calculateTranslation, canvasPool, colorGradingFrag, colorStopsFromGradient, colorToArr$1 as colorToArr, combineImageTemplate, compatible_frag as compatibleFrag, compatible_vert as compatibleVert, createCopyShader, createGLContext, createKeyFrameMeta, createShaderWithMacros, createShape, createValueGetter, decimalEqual, defaultGlobalVolume, defaultPlugins, deserializeMipmapTexture, earcut, effectsClass, effectsClassStore, enlargeBuffer, ensureFixedNumber, ensureVec3, findPreviousRenderPass, gaussianDown_frag as gaussianDownFrag, gaussianDownHFrag, gaussianDownVFrag, gaussianUpFrag, generateEmptyTypedArray, generateGUID, generateHalfFloatTexture, generateTransparentTexture, generateWhiteTexture, getBackgroundImage, getColorFromGradientStops, getConfig, getDefaultTemplateCanvasPool, 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, isSceneJSON, isSceneURL, isSceneWithOptions, 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, pluginLoaderMap, pointOnLine, 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, vecAssign, vecFill, vecMulCombine, vecNormalize, version, vertexFormatType2GLType };
|
|
27575
|
+
export { AbstractPlugin, ActivationPlayable, ActivationPlayableAsset, ActivationTrack, AnimationClip, AnimationClipPlayable, AssetLoader, AssetManager, BYTES_TYPE_MAP, Behaviour, BezierCurve, BezierCurvePath, BezierCurveQuat, BinaryAsset, COMPRESSED_TEXTURE, COPY_FRAGMENT_SHADER, COPY_MESH_SHADER_ID, COPY_VERTEX_SHADER, CalculateLoader, Camera, CameraController, CameraVFXItemLoader, Component, Composition, CompositionComponent, CompositionSourceManager, DEFAULT_FONTS, 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, FilterMode, Float16ArrayWrapper, Framebuffer, GLSLVersion, GPUCapability, Geometry, GlobalUniforms, GradientValue, HELP_LINK, HitTestType, InteractComponent, InteractLoader, InteractMesh, Item, ItemBehaviour, KTXTexture, LineSegments, LinearValue, Material, MaterialDataBlock, MaterialRenderType, Mesh, ObjectBindingTrack, OrderType, PLAYER_OPTIONS_ENV_EDITOR, POST_PROCESS_SETTINGS, ParticleBehaviourPlayable, ParticleBehaviourPlayableAsset, ParticleLoader, ParticleMesh, ParticleSystem, ParticleSystemRenderer, PassTextureCache, PathSegments, PluginSystem, PostProcessVolume, 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, SemanticMap, SerializationHelper, Shader, ShaderCompileResultStatus, ShaderType, ShaderVariant, SpriteColorPlayable, 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, addByOrder, addItem, addItemWithOrder, applyMixins, assertExist, asserts, base64ToFile, blend, calculateTranslation, canvasPool, colorGradingFrag, colorStopsFromGradient, colorToArr$1 as colorToArr, combineImageTemplate, compatible_frag as compatibleFrag, compatible_vert as compatibleVert, createCopyShader, createGLContext, createKeyFrameMeta, createShaderWithMacros, createShape, createValueGetter, decimalEqual, defaultGlobalVolume, defaultPlugins, deserializeMipmapTexture, earcut, effectsClass, effectsClassStore, enlargeBuffer, ensureFixedNumber, ensureVec3, findPreviousRenderPass, gaussianDown_frag as gaussianDownFrag, gaussianDownHFrag, gaussianDownVFrag, gaussianUpFrag, generateEmptyTypedArray, generateGUID, generateHalfFloatTexture, generateTransparentTexture, generateWhiteTexture, getBackgroundImage, getColorFromGradientStops, getConfig, getDefaultTemplateCanvasPool, 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, isSceneJSON, isSceneURL, isSceneWithOptions, 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, pluginLoaderMap, pointOnLine, 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, vecAssign, vecFill, vecMulCombine, vecNormalize, version, vertexFormatType2GLType };
|
|
27488
27576
|
//# sourceMappingURL=index.mjs.map
|