@galacean/effects-threejs 2.1.0-alpha.10 → 2.1.0-alpha.12
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 +264 -229
- package/dist/index.js.map +1 -1
- package/dist/index.min.js +2 -2
- package/dist/index.min.js.map +1 -1
- package/dist/index.mjs +272 -236
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Description: Galacean Effects runtime threejs plugin for the web
|
|
4
4
|
* Author: Ant Group CO., Ltd.
|
|
5
5
|
* Contributors: 燃然,飂兮,十弦,云垣,茂安,意绮
|
|
6
|
-
* Version: v2.1.0-alpha.
|
|
6
|
+
* Version: v2.1.0-alpha.12
|
|
7
7
|
*/
|
|
8
8
|
|
|
9
9
|
'use strict';
|
|
@@ -2045,7 +2045,7 @@ function getDirectStore(target) {
|
|
|
2045
2045
|
this.onAwake();
|
|
2046
2046
|
this.isAwakeCalled = true;
|
|
2047
2047
|
}
|
|
2048
|
-
if (item.
|
|
2048
|
+
if (item.isActive && this.enabled) {
|
|
2049
2049
|
this.start();
|
|
2050
2050
|
this.enable();
|
|
2051
2051
|
}
|
|
@@ -2090,7 +2090,7 @@ function getDirectStore(target) {
|
|
|
2090
2090
|
get: /**
|
|
2091
2091
|
* 组件是否可以更新,true 更新,false 不更新
|
|
2092
2092
|
*/ function get() {
|
|
2093
|
-
return this.item.
|
|
2093
|
+
return this.item.isActive && this.enabled;
|
|
2094
2094
|
}
|
|
2095
2095
|
},
|
|
2096
2096
|
{
|
|
@@ -3792,24 +3792,29 @@ exports.EffectComponent = __decorate([
|
|
|
3792
3792
|
|
|
3793
3793
|
exports.PostProcessVolume = /*#__PURE__*/ function(Behaviour) {
|
|
3794
3794
|
_inherits(PostProcessVolume, Behaviour);
|
|
3795
|
-
function PostProcessVolume() {
|
|
3795
|
+
function PostProcessVolume(engine) {
|
|
3796
3796
|
var _this;
|
|
3797
|
-
_this = Behaviour.
|
|
3798
|
-
|
|
3799
|
-
|
|
3800
|
-
|
|
3801
|
-
|
|
3802
|
-
|
|
3803
|
-
_this.
|
|
3804
|
-
|
|
3805
|
-
|
|
3806
|
-
|
|
3807
|
-
|
|
3808
|
-
|
|
3809
|
-
_this.
|
|
3810
|
-
|
|
3811
|
-
|
|
3812
|
-
|
|
3797
|
+
_this = Behaviour.call(this, engine) || this;
|
|
3798
|
+
_this.bloom = {
|
|
3799
|
+
threshold: 0,
|
|
3800
|
+
intensity: 0,
|
|
3801
|
+
active: false
|
|
3802
|
+
};
|
|
3803
|
+
_this.vignette = {
|
|
3804
|
+
intensity: 0,
|
|
3805
|
+
smoothness: 0,
|
|
3806
|
+
roundness: 0,
|
|
3807
|
+
active: false
|
|
3808
|
+
};
|
|
3809
|
+
_this.tonemapping = {
|
|
3810
|
+
active: false
|
|
3811
|
+
};
|
|
3812
|
+
_this.colorAdjustments = {
|
|
3813
|
+
brightness: 0,
|
|
3814
|
+
saturation: 0,
|
|
3815
|
+
contrast: 0,
|
|
3816
|
+
active: false
|
|
3817
|
+
};
|
|
3813
3818
|
return _this;
|
|
3814
3819
|
}
|
|
3815
3820
|
var _proto = PostProcessVolume.prototype;
|
|
@@ -3823,36 +3828,18 @@ exports.PostProcessVolume = /*#__PURE__*/ function(Behaviour) {
|
|
|
3823
3828
|
}(Behaviour);
|
|
3824
3829
|
__decorate([
|
|
3825
3830
|
serialize()
|
|
3826
|
-
], exports.PostProcessVolume.prototype, "
|
|
3827
|
-
__decorate([
|
|
3828
|
-
serialize()
|
|
3829
|
-
], exports.PostProcessVolume.prototype, "threshold", void 0);
|
|
3830
|
-
__decorate([
|
|
3831
|
-
serialize()
|
|
3832
|
-
], exports.PostProcessVolume.prototype, "bloomIntensity", void 0);
|
|
3833
|
-
__decorate([
|
|
3834
|
-
serialize()
|
|
3835
|
-
], exports.PostProcessVolume.prototype, "brightness", void 0);
|
|
3836
|
-
__decorate([
|
|
3837
|
-
serialize()
|
|
3838
|
-
], exports.PostProcessVolume.prototype, "saturation", void 0);
|
|
3839
|
-
__decorate([
|
|
3840
|
-
serialize()
|
|
3841
|
-
], exports.PostProcessVolume.prototype, "contrast", void 0);
|
|
3842
|
-
__decorate([
|
|
3843
|
-
serialize()
|
|
3844
|
-
], exports.PostProcessVolume.prototype, "vignetteIntensity", void 0);
|
|
3831
|
+
], exports.PostProcessVolume.prototype, "bloom", void 0);
|
|
3845
3832
|
__decorate([
|
|
3846
3833
|
serialize()
|
|
3847
|
-
], exports.PostProcessVolume.prototype, "
|
|
3834
|
+
], exports.PostProcessVolume.prototype, "vignette", void 0);
|
|
3848
3835
|
__decorate([
|
|
3849
3836
|
serialize()
|
|
3850
|
-
], exports.PostProcessVolume.prototype, "
|
|
3837
|
+
], exports.PostProcessVolume.prototype, "tonemapping", void 0);
|
|
3851
3838
|
__decorate([
|
|
3852
3839
|
serialize()
|
|
3853
|
-
], exports.PostProcessVolume.prototype, "
|
|
3840
|
+
], exports.PostProcessVolume.prototype, "colorAdjustments", void 0);
|
|
3854
3841
|
exports.PostProcessVolume = __decorate([
|
|
3855
|
-
effectsClass(
|
|
3842
|
+
effectsClass(DataType.PostProcessVolume)
|
|
3856
3843
|
], exports.PostProcessVolume);
|
|
3857
3844
|
|
|
3858
3845
|
function _assert_this_initialized(self) {
|
|
@@ -6939,6 +6926,7 @@ exports.MaterialRenderType = void 0;
|
|
|
6939
6926
|
_this.enabledMacros = {};
|
|
6940
6927
|
_this.destroyed = false;
|
|
6941
6928
|
_this.initialized = false;
|
|
6929
|
+
_this.shaderDirty = true;
|
|
6942
6930
|
if (props) {
|
|
6943
6931
|
var _props_name = props.name, name = _props_name === void 0 ? "Material" + seed$9++ : _props_name, _props_renderType = props.renderType, renderType = _props_renderType === void 0 ? 0 : _props_renderType, shader = props.shader, uniformSemantics = props.uniformSemantics;
|
|
6944
6932
|
_this.name = name;
|
|
@@ -6966,6 +6954,19 @@ exports.MaterialRenderType = void 0;
|
|
|
6966
6954
|
// OVERRIDE
|
|
6967
6955
|
};
|
|
6968
6956
|
_create_class(Material, [
|
|
6957
|
+
{
|
|
6958
|
+
key: "shader",
|
|
6959
|
+
get: function get() {
|
|
6960
|
+
return this._shader;
|
|
6961
|
+
},
|
|
6962
|
+
set: function set(value) {
|
|
6963
|
+
if (this._shader === value) {
|
|
6964
|
+
return;
|
|
6965
|
+
}
|
|
6966
|
+
this._shader = value;
|
|
6967
|
+
this.shaderDirty = true;
|
|
6968
|
+
}
|
|
6969
|
+
},
|
|
6969
6970
|
{
|
|
6970
6971
|
key: "blending",
|
|
6971
6972
|
set: /******** effects-core 中会调用 引擎必须实现 ***********************/ /**
|
|
@@ -10333,15 +10334,15 @@ var BloomThresholdPass = /*#__PURE__*/ function(RenderPass) {
|
|
|
10333
10334
|
renderer.setFramebuffer(this.framebuffer);
|
|
10334
10335
|
};
|
|
10335
10336
|
_proto.execute = function execute(renderer) {
|
|
10336
|
-
var _renderer_renderingData_currentFrame_globalVolume;
|
|
10337
|
+
var _renderer_renderingData_currentFrame_globalVolume_bloom, _renderer_renderingData_currentFrame_globalVolume;
|
|
10337
10338
|
renderer.clear({
|
|
10338
10339
|
colorAction: exports.TextureStoreAction.clear,
|
|
10339
10340
|
depthAction: exports.TextureStoreAction.clear,
|
|
10340
10341
|
stencilAction: exports.TextureStoreAction.clear
|
|
10341
10342
|
});
|
|
10342
10343
|
this.screenMesh.material.setTexture("_MainTex", this.mainTexture);
|
|
10343
|
-
var
|
|
10344
|
-
var threshold = (
|
|
10344
|
+
var _renderer_renderingData_currentFrame_globalVolume_bloom_threshold;
|
|
10345
|
+
var threshold = (_renderer_renderingData_currentFrame_globalVolume_bloom_threshold = (_renderer_renderingData_currentFrame_globalVolume = renderer.renderingData.currentFrame.globalVolume) == null ? void 0 : (_renderer_renderingData_currentFrame_globalVolume_bloom = _renderer_renderingData_currentFrame_globalVolume.bloom) == null ? void 0 : _renderer_renderingData_currentFrame_globalVolume_bloom.threshold) != null ? _renderer_renderingData_currentFrame_globalVolume_bloom_threshold : 1.0;
|
|
10345
10346
|
this.screenMesh.material.setFloat("_Threshold", threshold);
|
|
10346
10347
|
renderer.renderMeshes([
|
|
10347
10348
|
this.screenMesh
|
|
@@ -10554,25 +10555,44 @@ var ToneMappingPass = /*#__PURE__*/ function(RenderPass) {
|
|
|
10554
10555
|
depthAction: exports.TextureStoreAction.clear,
|
|
10555
10556
|
stencilAction: exports.TextureStoreAction.clear
|
|
10556
10557
|
});
|
|
10557
|
-
var
|
|
10558
|
-
var
|
|
10558
|
+
var globalVolume = renderer.renderingData.currentFrame.globalVolume;
|
|
10559
|
+
var bloom = _extends({
|
|
10560
|
+
threshold: 0,
|
|
10561
|
+
intensity: 0,
|
|
10562
|
+
active: false
|
|
10563
|
+
}, globalVolume == null ? void 0 : globalVolume.bloom);
|
|
10564
|
+
var vignette = _extends({
|
|
10565
|
+
intensity: 0,
|
|
10566
|
+
smoothness: 0,
|
|
10567
|
+
roundness: 0,
|
|
10568
|
+
active: false
|
|
10569
|
+
}, globalVolume == null ? void 0 : globalVolume.vignette);
|
|
10570
|
+
var colorAdjustments = _extends({
|
|
10571
|
+
brightness: 0,
|
|
10572
|
+
saturation: 0,
|
|
10573
|
+
contrast: 0,
|
|
10574
|
+
active: false
|
|
10575
|
+
}, globalVolume == null ? void 0 : globalVolume.colorAdjustments);
|
|
10576
|
+
var tonemapping = _extends({
|
|
10577
|
+
active: false
|
|
10578
|
+
}, globalVolume == null ? void 0 : globalVolume.tonemapping);
|
|
10559
10579
|
this.screenMesh.material.setTexture("_SceneTex", this.sceneTextureHandle.texture);
|
|
10560
|
-
this.screenMesh.material.setFloat("_Brightness", brightness);
|
|
10561
|
-
this.screenMesh.material.setFloat("_Saturation", saturation);
|
|
10562
|
-
this.screenMesh.material.setFloat("_Contrast", contrast);
|
|
10563
|
-
this.screenMesh.material.setInt("_UseBloom", Number(
|
|
10564
|
-
if (
|
|
10580
|
+
this.screenMesh.material.setFloat("_Brightness", Math.pow(2, colorAdjustments.brightness));
|
|
10581
|
+
this.screenMesh.material.setFloat("_Saturation", colorAdjustments.saturation * 0.01 + 1);
|
|
10582
|
+
this.screenMesh.material.setFloat("_Contrast", colorAdjustments.contrast * 0.01 + 1);
|
|
10583
|
+
this.screenMesh.material.setInt("_UseBloom", Number(bloom.active));
|
|
10584
|
+
if (bloom.active) {
|
|
10565
10585
|
this.screenMesh.material.setTexture("_GaussianTex", this.mainTexture);
|
|
10566
|
-
this.screenMesh.material.setFloat("_BloomIntensity",
|
|
10586
|
+
this.screenMesh.material.setFloat("_BloomIntensity", bloom.intensity);
|
|
10567
10587
|
}
|
|
10568
|
-
if (
|
|
10569
|
-
this.screenMesh.material.setFloat("_VignetteIntensity",
|
|
10570
|
-
this.screenMesh.material.setFloat("_VignetteSmoothness",
|
|
10571
|
-
this.screenMesh.material.setFloat("_VignetteRoundness",
|
|
10588
|
+
if (vignette.intensity > 0) {
|
|
10589
|
+
this.screenMesh.material.setFloat("_VignetteIntensity", vignette.intensity);
|
|
10590
|
+
this.screenMesh.material.setFloat("_VignetteSmoothness", vignette.smoothness);
|
|
10591
|
+
this.screenMesh.material.setFloat("_VignetteRoundness", vignette.roundness);
|
|
10572
10592
|
this.screenMesh.material.setVector2("_VignetteCenter", new Vector2(0.5, 0.5));
|
|
10573
10593
|
this.screenMesh.material.setVector3("_VignetteColor", new Vector3(0.0, 0.0, 0.0));
|
|
10574
10594
|
}
|
|
10575
|
-
this.screenMesh.material.setInt("_UseToneMapping", Number(
|
|
10595
|
+
this.screenMesh.material.setInt("_UseToneMapping", Number(tonemapping.active));
|
|
10576
10596
|
renderer.renderMeshes([
|
|
10577
10597
|
this.screenMesh
|
|
10578
10598
|
]);
|
|
@@ -15783,70 +15803,79 @@ exports.ShapeComponent = /*#__PURE__*/ function(MeshComponent) {
|
|
|
15783
15803
|
};
|
|
15784
15804
|
_proto.buildPath = function buildPath(data) {
|
|
15785
15805
|
this.path.clear();
|
|
15786
|
-
|
|
15787
|
-
|
|
15788
|
-
|
|
15789
|
-
|
|
15790
|
-
|
|
15791
|
-
|
|
15792
|
-
|
|
15793
|
-
|
|
15794
|
-
|
|
15795
|
-
|
|
15796
|
-
|
|
15797
|
-
|
|
15798
|
-
|
|
15799
|
-
|
|
15800
|
-
|
|
15801
|
-
|
|
15802
|
-
this.curveValues.push({
|
|
15803
|
-
point: points[pointIndex.point],
|
|
15804
|
-
controlPoint1: easingOuts[lastPointIndex.easingOut],
|
|
15805
|
-
controlPoint2: easingIns[pointIndex.easingIn]
|
|
15806
|
-
});
|
|
15807
|
-
}
|
|
15808
|
-
// Push the last curve
|
|
15806
|
+
var shapeData = data;
|
|
15807
|
+
switch(shapeData.type){
|
|
15808
|
+
case 0:
|
|
15809
|
+
{
|
|
15810
|
+
var customData = shapeData;
|
|
15811
|
+
var points = customData.points;
|
|
15812
|
+
var easingIns = customData.easingIns;
|
|
15813
|
+
var easingOuts = customData.easingOuts;
|
|
15814
|
+
this.curveValues = [];
|
|
15815
|
+
for(var _iterator = _create_for_of_iterator_helper_loose(customData.shapes), _step; !(_step = _iterator()).done;){
|
|
15816
|
+
var shape = _step.value;
|
|
15817
|
+
this.setFillColor(shape.fill);
|
|
15818
|
+
var indices = shape.indexes;
|
|
15819
|
+
for(var i = 1; i < indices.length; i++){
|
|
15820
|
+
var pointIndex = indices[i];
|
|
15821
|
+
var lastPointIndex = indices[i - 1];
|
|
15809
15822
|
this.curveValues.push({
|
|
15810
|
-
point: points[
|
|
15811
|
-
controlPoint1: easingOuts[
|
|
15812
|
-
controlPoint2: easingIns[
|
|
15823
|
+
point: points[pointIndex.point],
|
|
15824
|
+
controlPoint1: easingOuts[lastPointIndex.easingOut],
|
|
15825
|
+
controlPoint2: easingIns[pointIndex.easingIn]
|
|
15813
15826
|
});
|
|
15814
15827
|
}
|
|
15815
|
-
|
|
15816
|
-
|
|
15817
|
-
|
|
15818
|
-
|
|
15819
|
-
|
|
15820
|
-
|
|
15821
|
-
this.path.bezierCurveTo(control1.x, control1.y, control2.x, control2.y, point.x, point.y, 1);
|
|
15822
|
-
}
|
|
15823
|
-
break;
|
|
15824
|
-
}
|
|
15825
|
-
case 2:
|
|
15826
|
-
{
|
|
15827
|
-
var ellipseData = shapeData;
|
|
15828
|
-
this.path.ellipse(0, 0, ellipseData.xRadius, ellipseData.yRadius);
|
|
15829
|
-
break;
|
|
15830
|
-
}
|
|
15831
|
-
case 1:
|
|
15832
|
-
{
|
|
15833
|
-
var rectangleData = shapeData;
|
|
15834
|
-
this.path.rect(-rectangleData.width / 2, rectangleData.height / 2, rectangleData.width, rectangleData.height);
|
|
15835
|
-
break;
|
|
15836
|
-
}
|
|
15837
|
-
case 4:
|
|
15838
|
-
{
|
|
15839
|
-
var starData = shapeData;
|
|
15840
|
-
this.path.polyStar(starData.pointCount, starData.outerRadius, starData.innerRadius, starData.outerRoundness, starData.innerRoundness, StarType.Star);
|
|
15841
|
-
break;
|
|
15828
|
+
// Push the last curve
|
|
15829
|
+
this.curveValues.push({
|
|
15830
|
+
point: points[indices[0].point],
|
|
15831
|
+
controlPoint1: easingOuts[indices[indices.length - 1].easingOut],
|
|
15832
|
+
controlPoint2: easingIns[indices[0].easingIn]
|
|
15833
|
+
});
|
|
15842
15834
|
}
|
|
15843
|
-
|
|
15844
|
-
{
|
|
15845
|
-
var
|
|
15846
|
-
|
|
15847
|
-
|
|
15835
|
+
this.path.moveTo(this.curveValues[this.curveValues.length - 1].point.x, this.curveValues[this.curveValues.length - 1].point.y);
|
|
15836
|
+
for(var _iterator1 = _create_for_of_iterator_helper_loose(this.curveValues), _step1; !(_step1 = _iterator1()).done;){
|
|
15837
|
+
var curveValue = _step1.value;
|
|
15838
|
+
var point = curveValue.point;
|
|
15839
|
+
var control1 = curveValue.controlPoint1;
|
|
15840
|
+
var control2 = curveValue.controlPoint2;
|
|
15841
|
+
this.path.bezierCurveTo(control1.x, control1.y, control2.x, control2.y, point.x, point.y, 1);
|
|
15848
15842
|
}
|
|
15849
|
-
|
|
15843
|
+
break;
|
|
15844
|
+
}
|
|
15845
|
+
case 2:
|
|
15846
|
+
{
|
|
15847
|
+
var ellipseData = shapeData;
|
|
15848
|
+
this.path.ellipse(0, 0, ellipseData.xRadius, ellipseData.yRadius);
|
|
15849
|
+
this.setFillColor(ellipseData.fill);
|
|
15850
|
+
break;
|
|
15851
|
+
}
|
|
15852
|
+
case 1:
|
|
15853
|
+
{
|
|
15854
|
+
var rectangleData = shapeData;
|
|
15855
|
+
this.path.rect(-rectangleData.width / 2, rectangleData.height / 2, rectangleData.width, rectangleData.height);
|
|
15856
|
+
this.setFillColor(rectangleData.fill);
|
|
15857
|
+
break;
|
|
15858
|
+
}
|
|
15859
|
+
case 4:
|
|
15860
|
+
{
|
|
15861
|
+
var starData = shapeData;
|
|
15862
|
+
this.path.polyStar(starData.pointCount, starData.outerRadius, starData.innerRadius, starData.outerRoundness, starData.innerRoundness, StarType.Star);
|
|
15863
|
+
this.setFillColor(starData.fill);
|
|
15864
|
+
break;
|
|
15865
|
+
}
|
|
15866
|
+
case 3:
|
|
15867
|
+
{
|
|
15868
|
+
var polygonData = shapeData;
|
|
15869
|
+
this.path.polyStar(polygonData.pointCount, polygonData.radius, polygonData.radius, polygonData.roundness, polygonData.roundness, StarType.Polygon);
|
|
15870
|
+
this.setFillColor(polygonData.fill);
|
|
15871
|
+
break;
|
|
15872
|
+
}
|
|
15873
|
+
}
|
|
15874
|
+
};
|
|
15875
|
+
_proto.setFillColor = function setFillColor(fill) {
|
|
15876
|
+
if (fill) {
|
|
15877
|
+
var color = fill.color;
|
|
15878
|
+
this.material.setColor("_Color", new Color(color.r, color.g, color.b, color.a));
|
|
15850
15879
|
}
|
|
15851
15880
|
};
|
|
15852
15881
|
_proto.fromData = function fromData(data) {
|
|
@@ -15866,26 +15895,24 @@ exports.ShapeComponent = /*#__PURE__*/ function(MeshComponent) {
|
|
|
15866
15895
|
exports.ShapeComponent = __decorate([
|
|
15867
15896
|
effectsClass("ShapeComponent")
|
|
15868
15897
|
], exports.ShapeComponent);
|
|
15869
|
-
exports.
|
|
15870
|
-
(function(
|
|
15898
|
+
exports.ShapePrimitiveType = void 0;
|
|
15899
|
+
(function(ShapePrimitiveType) {
|
|
15871
15900
|
/**
|
|
15872
15901
|
* 自定义图形
|
|
15873
|
-
*/
|
|
15902
|
+
*/ ShapePrimitiveType[ShapePrimitiveType["Custom"] = 0] = "Custom";
|
|
15874
15903
|
/**
|
|
15875
15904
|
* 矩形
|
|
15876
|
-
*/
|
|
15905
|
+
*/ ShapePrimitiveType[ShapePrimitiveType["Rectangle"] = 1] = "Rectangle";
|
|
15877
15906
|
/**
|
|
15878
15907
|
* 椭圆
|
|
15879
|
-
*/
|
|
15908
|
+
*/ ShapePrimitiveType[ShapePrimitiveType["Ellipse"] = 2] = "Ellipse";
|
|
15880
15909
|
/**
|
|
15881
15910
|
* 多边形
|
|
15882
|
-
*/
|
|
15911
|
+
*/ ShapePrimitiveType[ShapePrimitiveType["Polygon"] = 3] = "Polygon";
|
|
15883
15912
|
/**
|
|
15884
15913
|
* 星形
|
|
15885
|
-
*/
|
|
15886
|
-
})(exports.
|
|
15887
|
-
var ShapeData = function ShapeData() {
|
|
15888
|
-
};
|
|
15914
|
+
*/ ShapePrimitiveType[ShapePrimitiveType["Star"] = 4] = "Star";
|
|
15915
|
+
})(exports.ShapePrimitiveType || (exports.ShapePrimitiveType = {}));
|
|
15889
15916
|
exports.ShapeConnectType = void 0;
|
|
15890
15917
|
(function(ShapeConnectType) {})(exports.ShapeConnectType || (exports.ShapeConnectType = {}));
|
|
15891
15918
|
exports.ShapePointType = void 0;
|
|
@@ -16387,8 +16414,8 @@ exports.InteractComponent = /*#__PURE__*/ function(RendererComponent) {
|
|
|
16387
16414
|
0
|
|
16388
16415
|
]
|
|
16389
16416
|
};
|
|
16417
|
+
_this.duringPlay = false;
|
|
16390
16418
|
/** 是否响应点击和拖拽交互事件 */ _this._interactive = true;
|
|
16391
|
-
_this.hasBeenAddedToComposition = false;
|
|
16392
16419
|
_this.getHitTestParams = function(force) {
|
|
16393
16420
|
if (!_this.clickable) {
|
|
16394
16421
|
return;
|
|
@@ -16425,7 +16452,6 @@ exports.InteractComponent = /*#__PURE__*/ function(RendererComponent) {
|
|
|
16425
16452
|
];
|
|
16426
16453
|
};
|
|
16427
16454
|
_proto.onStart = function onStart() {
|
|
16428
|
-
var _this = this;
|
|
16429
16455
|
var options = this.item.props.content.options;
|
|
16430
16456
|
var env = this.item.engine.renderer.env;
|
|
16431
16457
|
var composition = this.item.composition;
|
|
@@ -16449,32 +16475,35 @@ exports.InteractComponent = /*#__PURE__*/ function(RendererComponent) {
|
|
|
16449
16475
|
this.materials = this.previewContent.mesh.materials;
|
|
16450
16476
|
}
|
|
16451
16477
|
this.item.getHitTestParams = this.getHitTestParams;
|
|
16452
|
-
|
|
16453
|
-
|
|
16454
|
-
|
|
16455
|
-
|
|
16456
|
-
|
|
16457
|
-
|
|
16458
|
-
|
|
16459
|
-
_this.endDragTarget();
|
|
16478
|
+
};
|
|
16479
|
+
_proto.onDisable = function onDisable() {
|
|
16480
|
+
if (this.item && this.item.composition) {
|
|
16481
|
+
var _this_previewContent;
|
|
16482
|
+
if (this.duringPlay) {
|
|
16483
|
+
this.item.composition.removeInteractiveItem(this.item, this.item.props.content.options.type);
|
|
16484
|
+
this.duringPlay = false;
|
|
16460
16485
|
}
|
|
16461
|
-
|
|
16486
|
+
this.clickable = false;
|
|
16487
|
+
(_this_previewContent = this.previewContent) == null ? void 0 : _this_previewContent.mesh.dispose();
|
|
16488
|
+
this.endDragTarget();
|
|
16489
|
+
}
|
|
16490
|
+
};
|
|
16491
|
+
_proto.onEnable = function onEnable() {
|
|
16492
|
+
var type = this.interactData.options.type;
|
|
16493
|
+
if (type === InteractType.CLICK) {
|
|
16494
|
+
this.clickable = true;
|
|
16495
|
+
}
|
|
16462
16496
|
};
|
|
16463
16497
|
_proto.onUpdate = function onUpdate(dt) {
|
|
16464
16498
|
var _this_previewContent;
|
|
16465
|
-
|
|
16466
|
-
|
|
16467
|
-
|
|
16468
|
-
|
|
16469
|
-
if (!this.hasBeenAddedToComposition && this.item.composition) {
|
|
16470
|
-
var type = this.interactData.options.type;
|
|
16471
|
-
if (type === InteractType.CLICK) {
|
|
16472
|
-
this.clickable = true;
|
|
16473
|
-
}
|
|
16499
|
+
this.duringPlay = true;
|
|
16500
|
+
// trigger messageBegin when item enter
|
|
16501
|
+
if (this.item.time > 0 && this.item.time - dt / 1000 <= 0) {
|
|
16502
|
+
var _this_item_composition;
|
|
16474
16503
|
var options = this.item.props.content.options;
|
|
16475
|
-
this.item.composition.addInteractiveItem(this.item, options.type);
|
|
16476
|
-
this.hasBeenAddedToComposition = true;
|
|
16504
|
+
(_this_item_composition = this.item.composition) == null ? void 0 : _this_item_composition.addInteractiveItem(this.item, options.type);
|
|
16477
16505
|
}
|
|
16506
|
+
(_this_previewContent = this.previewContent) == null ? void 0 : _this_previewContent.updateMesh();
|
|
16478
16507
|
if (!this.dragEvent || !this.bouncingArg) {
|
|
16479
16508
|
return;
|
|
16480
16509
|
}
|
|
@@ -16888,6 +16917,7 @@ var SpriteLoader = /*#__PURE__*/ function(AbstractPlugin) {
|
|
|
16888
16917
|
if (inputCount === void 0) inputCount = 0;
|
|
16889
16918
|
this.onPlayablePlayFlag = true;
|
|
16890
16919
|
this.onPlayablePauseFlag = false;
|
|
16920
|
+
this.duration = 0;
|
|
16891
16921
|
this.destroyed = false;
|
|
16892
16922
|
this.inputs = [];
|
|
16893
16923
|
this.inputOuputPorts = [];
|
|
@@ -16980,6 +17010,12 @@ var SpriteLoader = /*#__PURE__*/ function(AbstractPlugin) {
|
|
|
16980
17010
|
_proto.getTime = function getTime() {
|
|
16981
17011
|
return this.time;
|
|
16982
17012
|
};
|
|
17013
|
+
_proto.setDuration = function setDuration(duration) {
|
|
17014
|
+
this.duration = duration;
|
|
17015
|
+
};
|
|
17016
|
+
_proto.getDuration = function getDuration() {
|
|
17017
|
+
return this.duration;
|
|
17018
|
+
};
|
|
16983
17019
|
_proto.getPlayState = function getPlayState() {
|
|
16984
17020
|
return this.playState;
|
|
16985
17021
|
};
|
|
@@ -17696,17 +17732,15 @@ exports.VFXItem = /*#__PURE__*/ function(EffectsObject) {
|
|
|
17696
17732
|
/**
|
|
17697
17733
|
* 元素动画结束时行为(如何处理元素)
|
|
17698
17734
|
*/ _this.endBehavior = EndBehavior.forward;
|
|
17699
|
-
/**
|
|
17700
|
-
* 元素是否可用
|
|
17701
|
-
*/ _this.ended = false;
|
|
17702
|
-
_this.reusable = false;
|
|
17703
17735
|
_this.type = ItemType.base;
|
|
17704
17736
|
_this.isDuringPlay = false;
|
|
17705
17737
|
_this.components = [];
|
|
17706
17738
|
_this.rendererComponents = [];
|
|
17707
17739
|
/**
|
|
17708
|
-
*
|
|
17709
|
-
|
|
17740
|
+
* 元素是否激活
|
|
17741
|
+
*/ _this.active = true;
|
|
17742
|
+
/**
|
|
17743
|
+
* 元素组件是否显示,用于批量开关元素组件
|
|
17710
17744
|
*/ _this.visible = true;
|
|
17711
17745
|
/**
|
|
17712
17746
|
* 元素动画的速度
|
|
@@ -17837,12 +17871,6 @@ exports.VFXItem = /*#__PURE__*/ function(EffectsObject) {
|
|
|
17837
17871
|
}
|
|
17838
17872
|
};
|
|
17839
17873
|
/**
|
|
17840
|
-
* 元素动画结束播放时回调函数
|
|
17841
|
-
* @override
|
|
17842
|
-
*/ _proto.onEnd = function onEnd() {
|
|
17843
|
-
// OVERRIDE
|
|
17844
|
-
};
|
|
17845
|
-
/**
|
|
17846
17874
|
* 通过指定 r、g、b、a 值设置元素的颜色
|
|
17847
17875
|
* @param {number} r
|
|
17848
17876
|
* @param {number} g
|
|
@@ -17855,17 +17883,27 @@ exports.VFXItem = /*#__PURE__*/ function(EffectsObject) {
|
|
|
17855
17883
|
* @param opacity - 透明度值,范围 [0,1]
|
|
17856
17884
|
*/ _proto.setOpacity = function setOpacity(opacity) {};
|
|
17857
17885
|
/**
|
|
17858
|
-
*
|
|
17859
|
-
*/ _proto.
|
|
17860
|
-
|
|
17886
|
+
* 激活或停用 VFXItem
|
|
17887
|
+
*/ _proto.setActive = function setActive(value) {
|
|
17888
|
+
if (this.active !== value) {
|
|
17889
|
+
this.active = !!value;
|
|
17890
|
+
this.onActiveChanged();
|
|
17891
|
+
}
|
|
17861
17892
|
};
|
|
17862
17893
|
/**
|
|
17863
|
-
*
|
|
17894
|
+
* 设置元素的显隐,该设置会批量开关元素组件
|
|
17864
17895
|
*/ _proto.setVisible = function setVisible(visible) {
|
|
17865
|
-
|
|
17866
|
-
|
|
17867
|
-
|
|
17896
|
+
for(var _iterator = _create_for_of_iterator_helper_loose(this.components), _step; !(_step = _iterator()).done;){
|
|
17897
|
+
var component = _step.value;
|
|
17898
|
+
component.enabled = visible;
|
|
17868
17899
|
}
|
|
17900
|
+
this.visible = visible;
|
|
17901
|
+
};
|
|
17902
|
+
/**
|
|
17903
|
+
* 元素组件显隐状态
|
|
17904
|
+
* @deprecated use isVisible instead
|
|
17905
|
+
*/ _proto.getVisible = function getVisible() {
|
|
17906
|
+
return this.visible;
|
|
17869
17907
|
};
|
|
17870
17908
|
/**
|
|
17871
17909
|
* 获取元素变换包括位置、旋转、缩放
|
|
@@ -17947,14 +17985,6 @@ exports.VFXItem = /*#__PURE__*/ function(EffectsObject) {
|
|
|
17947
17985
|
this.transform.assignWorldTRS(pos);
|
|
17948
17986
|
return pos;
|
|
17949
17987
|
};
|
|
17950
|
-
/**
|
|
17951
|
-
* 是否到达元素的结束时间
|
|
17952
|
-
* @param now
|
|
17953
|
-
* @returns
|
|
17954
|
-
*/ _proto.isEnded = function isEnded(now) {
|
|
17955
|
-
// at least 1 ms
|
|
17956
|
-
return now - this.duration > 0.001;
|
|
17957
|
-
};
|
|
17958
17988
|
_proto.find = function find(name) {
|
|
17959
17989
|
var _queue;
|
|
17960
17990
|
if (this.name === name) {
|
|
@@ -17978,7 +18008,7 @@ exports.VFXItem = /*#__PURE__*/ function(EffectsObject) {
|
|
|
17978
18008
|
* @internal
|
|
17979
18009
|
*/ _proto.beginPlay = function beginPlay() {
|
|
17980
18010
|
this.isDuringPlay = true;
|
|
17981
|
-
if (this.composition && this.
|
|
18011
|
+
if (this.composition && this.active && !this.isEnabled) {
|
|
17982
18012
|
this.onEnable();
|
|
17983
18013
|
}
|
|
17984
18014
|
for(var _iterator = _create_for_of_iterator_helper_loose(this.children), _step; !(_step = _iterator()).done;){
|
|
@@ -18254,6 +18284,22 @@ exports.VFXItem = /*#__PURE__*/ function(EffectsObject) {
|
|
|
18254
18284
|
}
|
|
18255
18285
|
}
|
|
18256
18286
|
}
|
|
18287
|
+
},
|
|
18288
|
+
{
|
|
18289
|
+
key: "isActive",
|
|
18290
|
+
get: /**
|
|
18291
|
+
* 当前 VFXItem 是否激活
|
|
18292
|
+
*/ function get() {
|
|
18293
|
+
return this.active;
|
|
18294
|
+
}
|
|
18295
|
+
},
|
|
18296
|
+
{
|
|
18297
|
+
key: "isVisible",
|
|
18298
|
+
get: /**
|
|
18299
|
+
* 元素组件显隐状态
|
|
18300
|
+
*/ function get() {
|
|
18301
|
+
return this.visible;
|
|
18302
|
+
}
|
|
18257
18303
|
}
|
|
18258
18304
|
]);
|
|
18259
18305
|
return VFXItem;
|
|
@@ -23018,6 +23064,7 @@ exports.TrackAsset = /*#__PURE__*/ function(PlayableAsset) {
|
|
|
23018
23064
|
for(var _iterator = _create_for_of_iterator_helper_loose(timelineClips), _step; !(_step = _iterator()).done;){
|
|
23019
23065
|
var timelineClip = _step.value;
|
|
23020
23066
|
var clipPlayable = this.createClipPlayable(graph, timelineClip);
|
|
23067
|
+
clipPlayable.setDuration(timelineClip.duration);
|
|
23021
23068
|
var clip = new RuntimeClip(timelineClip, clipPlayable, mixer, this);
|
|
23022
23069
|
runtimeClips.push(clip);
|
|
23023
23070
|
mixer.addInput(clipPlayable, 0);
|
|
@@ -23121,14 +23168,6 @@ var RuntimeClip = /*#__PURE__*/ function() {
|
|
|
23121
23168
|
this.playable.setTime(clipTime);
|
|
23122
23169
|
// 判断动画是否结束
|
|
23123
23170
|
if (ended) {
|
|
23124
|
-
if (_instanceof1(boundObject, exports.VFXItem) && !boundObject.ended) {
|
|
23125
|
-
boundObject.ended = true;
|
|
23126
|
-
boundObject.onEnd();
|
|
23127
|
-
if (!boundObject.compositionReusable && !boundObject.reusable) {
|
|
23128
|
-
boundObject.dispose();
|
|
23129
|
-
this.playable.dispose();
|
|
23130
|
-
}
|
|
23131
|
-
}
|
|
23132
23171
|
if (this.playable.getPlayState() === PlayState.Playing) {
|
|
23133
23172
|
this.playable.pause();
|
|
23134
23173
|
}
|
|
@@ -23171,26 +23210,10 @@ var ActivationMixerPlayable = /*#__PURE__*/ function(Playable) {
|
|
|
23171
23210
|
}
|
|
23172
23211
|
if (hasInput) {
|
|
23173
23212
|
boundItem.transform.setValid(true);
|
|
23174
|
-
|
|
23213
|
+
boundItem.setActive(true);
|
|
23175
23214
|
} else {
|
|
23176
23215
|
boundItem.transform.setValid(false);
|
|
23177
|
-
|
|
23178
|
-
}
|
|
23179
|
-
};
|
|
23180
|
-
_proto.hideRendererComponents = function hideRendererComponents(item) {
|
|
23181
|
-
for(var _iterator = _create_for_of_iterator_helper_loose(item.rendererComponents), _step; !(_step = _iterator()).done;){
|
|
23182
|
-
var rendererComponent = _step.value;
|
|
23183
|
-
if (rendererComponent.enabled) {
|
|
23184
|
-
rendererComponent.enabled = false;
|
|
23185
|
-
}
|
|
23186
|
-
}
|
|
23187
|
-
};
|
|
23188
|
-
_proto.showRendererComponents = function showRendererComponents(item) {
|
|
23189
|
-
for(var _iterator = _create_for_of_iterator_helper_loose(item.rendererComponents), _step; !(_step = _iterator()).done;){
|
|
23190
|
-
var rendererComponent = _step.value;
|
|
23191
|
-
if (!rendererComponent.enabled) {
|
|
23192
|
-
rendererComponent.enabled = true;
|
|
23193
|
-
}
|
|
23216
|
+
boundItem.setActive(false);
|
|
23194
23217
|
}
|
|
23195
23218
|
};
|
|
23196
23219
|
return ActivationMixerPlayable;
|
|
@@ -23218,7 +23241,7 @@ var PropertyClipPlayable = /*#__PURE__*/ function(Playable) {
|
|
|
23218
23241
|
}
|
|
23219
23242
|
var _proto = PropertyClipPlayable.prototype;
|
|
23220
23243
|
_proto.processFrame = function processFrame(context) {
|
|
23221
|
-
this.value = this.curve.getValue(this.time);
|
|
23244
|
+
this.value = this.curve.getValue(this.time / this.getDuration());
|
|
23222
23245
|
};
|
|
23223
23246
|
return PropertyClipPlayable;
|
|
23224
23247
|
}(Playable);
|
|
@@ -23736,9 +23759,6 @@ var SerializationHelper = /*#__PURE__*/ function() {
|
|
|
23736
23759
|
var track = _step.value;
|
|
23737
23760
|
var boundObject = track.boundObject;
|
|
23738
23761
|
if (_instanceof1(boundObject, exports.VFXItem)) {
|
|
23739
|
-
if (_instanceof1(track, exports.ObjectBindingTrack)) {
|
|
23740
|
-
boundObject.reusable = value;
|
|
23741
|
-
}
|
|
23742
23762
|
var subCompositionComponent = boundObject.getComponent(CompositionComponent);
|
|
23743
23763
|
if (subCompositionComponent) {
|
|
23744
23764
|
subCompositionComponent.setReusable(value);
|
|
@@ -23783,16 +23803,16 @@ var SerializationHelper = /*#__PURE__*/ function() {
|
|
|
23783
23803
|
}
|
|
23784
23804
|
}
|
|
23785
23805
|
};
|
|
23786
|
-
_proto.
|
|
23806
|
+
_proto.onEnable = function onEnable() {
|
|
23787
23807
|
for(var _iterator = _create_for_of_iterator_helper_loose(this.items), _step; !(_step = _iterator()).done;){
|
|
23788
23808
|
var item = _step.value;
|
|
23789
|
-
item.
|
|
23809
|
+
item.setActive(true);
|
|
23790
23810
|
}
|
|
23791
23811
|
};
|
|
23792
|
-
_proto.
|
|
23812
|
+
_proto.onDisable = function onDisable() {
|
|
23793
23813
|
for(var _iterator = _create_for_of_iterator_helper_loose(this.items), _step; !(_step = _iterator()).done;){
|
|
23794
23814
|
var item = _step.value;
|
|
23795
|
-
item.
|
|
23815
|
+
item.setActive(false);
|
|
23796
23816
|
}
|
|
23797
23817
|
};
|
|
23798
23818
|
_proto.onDestroy = function onDestroy() {
|
|
@@ -23808,7 +23828,7 @@ var SerializationHelper = /*#__PURE__*/ function() {
|
|
|
23808
23828
|
_proto.hitTest = function hitTest(ray, x, y, regions, force, options) {
|
|
23809
23829
|
var _this, _loop = function(i) {
|
|
23810
23830
|
var item = _this.items[i];
|
|
23811
|
-
if (item.
|
|
23831
|
+
if (item.isActive && item.transform.getValid() && !exports.VFXItem.isComposition(item) && !skip(item)) {
|
|
23812
23832
|
var hitParams = item.getHitTestParams(force);
|
|
23813
23833
|
if (hitParams) {
|
|
23814
23834
|
var success = false;
|
|
@@ -23950,9 +23970,9 @@ var SubCompositionMixerPlayable = /*#__PURE__*/ function(Playable) {
|
|
|
23950
23970
|
}
|
|
23951
23971
|
}
|
|
23952
23972
|
if (hasInput) {
|
|
23953
|
-
compositionComponent.
|
|
23973
|
+
compositionComponent.item.setActive(true);
|
|
23954
23974
|
} else {
|
|
23955
|
-
compositionComponent.
|
|
23975
|
+
compositionComponent.item.setActive(false);
|
|
23956
23976
|
}
|
|
23957
23977
|
};
|
|
23958
23978
|
return SubCompositionMixerPlayable;
|
|
@@ -24617,6 +24637,8 @@ exports.TextComponent = /*#__PURE__*/ function(BaseRenderComponent) {
|
|
|
24617
24637
|
/**
|
|
24618
24638
|
* 文本行数
|
|
24619
24639
|
*/ _this.lineCount = 0;
|
|
24640
|
+
_this.SCALE_FACTOR = 0.1;
|
|
24641
|
+
_this.ALPHA_FIX_VALUE = 1 / 255;
|
|
24620
24642
|
_this.name = "MText" + seed$2++;
|
|
24621
24643
|
_this.geometry = _this.createGeometry(glContext.TRIANGLES);
|
|
24622
24644
|
if (props) {
|
|
@@ -28407,6 +28429,9 @@ var LateUpdateTickData = /*#__PURE__*/ function(TickData) {
|
|
|
28407
28429
|
* 动画播放速度
|
|
28408
28430
|
*/ _this.speed = 1;
|
|
28409
28431
|
/**
|
|
28432
|
+
* 合成是否结束
|
|
28433
|
+
*/ _this.isEnded = false;
|
|
28434
|
+
/**
|
|
28410
28435
|
* 用于保存与当前合成相关的插件数据
|
|
28411
28436
|
*/ _this.loaderData = {};
|
|
28412
28437
|
/**
|
|
@@ -28428,6 +28453,7 @@ var LateUpdateTickData = /*#__PURE__*/ function(TickData) {
|
|
|
28428
28453
|
* 合成暂停/播放 标识
|
|
28429
28454
|
*/ _this.paused = false;
|
|
28430
28455
|
_this.lastVideoUpdateTime = 0;
|
|
28456
|
+
_this.isEndCalled = false;
|
|
28431
28457
|
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;
|
|
28432
28458
|
_this.compositionSourceManager = new CompositionSourceManager(scene, renderer.engine);
|
|
28433
28459
|
if (reusable) {
|
|
@@ -28517,7 +28543,7 @@ var LateUpdateTickData = /*#__PURE__*/ function(TickData) {
|
|
|
28517
28543
|
* @param visible - 是否可见
|
|
28518
28544
|
*/ _proto.setVisible = function setVisible(visible) {
|
|
28519
28545
|
this.items.forEach(function(item) {
|
|
28520
|
-
item.
|
|
28546
|
+
item.setActive(visible);
|
|
28521
28547
|
});
|
|
28522
28548
|
};
|
|
28523
28549
|
/**
|
|
@@ -28527,7 +28553,7 @@ var LateUpdateTickData = /*#__PURE__*/ function(TickData) {
|
|
|
28527
28553
|
return this.speed;
|
|
28528
28554
|
};
|
|
28529
28555
|
_proto.play = function play() {
|
|
28530
|
-
if (this.
|
|
28556
|
+
if (this.isEnded && this.reusable) {
|
|
28531
28557
|
this.restart();
|
|
28532
28558
|
}
|
|
28533
28559
|
if (this.rootComposition.isStartCalled) {
|
|
@@ -28618,7 +28644,8 @@ var LateUpdateTickData = /*#__PURE__*/ function(TickData) {
|
|
|
28618
28644
|
* 重置状态函数
|
|
28619
28645
|
*/ _proto.reset = function reset() {
|
|
28620
28646
|
this.rendererOptions = null;
|
|
28621
|
-
this.
|
|
28647
|
+
this.isEnded = false;
|
|
28648
|
+
this.isEndCalled = false;
|
|
28622
28649
|
this.rootComposition.time = 0;
|
|
28623
28650
|
this.pluginSystem.resetComposition(this, this.renderFrame);
|
|
28624
28651
|
};
|
|
@@ -28670,12 +28697,18 @@ var LateUpdateTickData = /*#__PURE__*/ function(TickData) {
|
|
|
28670
28697
|
this.sceneTicking.lateUpdate.tick(dt);
|
|
28671
28698
|
this.updateCamera();
|
|
28672
28699
|
this.prepareRender();
|
|
28700
|
+
if (this.isEnded && !this.isEndCalled) {
|
|
28701
|
+
this.isEndCalled = true;
|
|
28702
|
+
this.emit("end", {
|
|
28703
|
+
composition: this
|
|
28704
|
+
});
|
|
28705
|
+
}
|
|
28673
28706
|
if (this.shouldDispose()) {
|
|
28674
28707
|
this.dispose();
|
|
28675
28708
|
}
|
|
28676
28709
|
};
|
|
28677
28710
|
_proto.shouldDispose = function shouldDispose() {
|
|
28678
|
-
return this.
|
|
28711
|
+
return this.isEnded && this.rootItem.endBehavior === EndBehavior.destroy && !this.reusable;
|
|
28679
28712
|
};
|
|
28680
28713
|
_proto.getUpdateTime = function getUpdateTime(t) {
|
|
28681
28714
|
var startTimeInMs = this.startTime * 1000;
|
|
@@ -28766,11 +28799,11 @@ var LateUpdateTickData = /*#__PURE__*/ function(TickData) {
|
|
|
28766
28799
|
*/ _proto.updateRootComposition = function updateRootComposition(deltaTime) {
|
|
28767
28800
|
if (this.rootComposition.isActiveAndEnabled) {
|
|
28768
28801
|
var localTime = this.time + deltaTime - this.rootItem.start;
|
|
28769
|
-
var
|
|
28802
|
+
var isEnded = false;
|
|
28770
28803
|
var duration = this.rootItem.duration;
|
|
28771
28804
|
var endBehavior = this.rootItem.endBehavior;
|
|
28772
28805
|
if (localTime - duration > 0.001) {
|
|
28773
|
-
|
|
28806
|
+
isEnded = true;
|
|
28774
28807
|
switch(endBehavior){
|
|
28775
28808
|
case EndBehavior.restart:
|
|
28776
28809
|
{
|
|
@@ -28794,11 +28827,14 @@ var LateUpdateTickData = /*#__PURE__*/ function(TickData) {
|
|
|
28794
28827
|
}
|
|
28795
28828
|
}
|
|
28796
28829
|
this.rootComposition.time = localTime;
|
|
28797
|
-
|
|
28798
|
-
|
|
28799
|
-
|
|
28800
|
-
|
|
28801
|
-
}
|
|
28830
|
+
// end state changed, handle onEnd flags
|
|
28831
|
+
if (this.isEnded !== isEnded) {
|
|
28832
|
+
if (isEnded) {
|
|
28833
|
+
this.isEnded = true;
|
|
28834
|
+
} else {
|
|
28835
|
+
this.isEnded = false;
|
|
28836
|
+
this.isEndCalled = false;
|
|
28837
|
+
}
|
|
28802
28838
|
}
|
|
28803
28839
|
}
|
|
28804
28840
|
};
|
|
@@ -31124,7 +31160,7 @@ registerPlugin("sprite", SpriteLoader, exports.VFXItem, true);
|
|
|
31124
31160
|
registerPlugin("particle", ParticleLoader, exports.VFXItem, true);
|
|
31125
31161
|
registerPlugin("cal", CalculateLoader, exports.VFXItem, true);
|
|
31126
31162
|
registerPlugin("interact", InteractLoader, exports.VFXItem, true);
|
|
31127
|
-
var version$1 = "2.1.0-alpha.
|
|
31163
|
+
var version$1 = "2.1.0-alpha.12";
|
|
31128
31164
|
logger.info("Core version: " + version$1 + ".");
|
|
31129
31165
|
|
|
31130
31166
|
var _obj;
|
|
@@ -32768,7 +32804,7 @@ setMaxSpriteMeshItemCount(8);
|
|
|
32768
32804
|
*/ Mesh.create = function(engine, props) {
|
|
32769
32805
|
return new ThreeMesh(engine, props);
|
|
32770
32806
|
};
|
|
32771
|
-
var version = "2.1.0-alpha.
|
|
32807
|
+
var version = "2.1.0-alpha.12";
|
|
32772
32808
|
logger.info("THREEJS plugin version: " + version + ".");
|
|
32773
32809
|
|
|
32774
32810
|
exports.AbstractPlugin = AbstractPlugin;
|
|
@@ -32864,7 +32900,6 @@ exports.SemanticMap = SemanticMap;
|
|
|
32864
32900
|
exports.SerializationHelper = SerializationHelper;
|
|
32865
32901
|
exports.ShaderFactory = ShaderFactory;
|
|
32866
32902
|
exports.ShaderVariant = ShaderVariant;
|
|
32867
|
-
exports.ShapeData = ShapeData;
|
|
32868
32903
|
exports.SpriteLoader = SpriteLoader;
|
|
32869
32904
|
exports.StaticValue = StaticValue;
|
|
32870
32905
|
exports.TEMPLATE_USE_OFFSCREEN_CANVAS = TEMPLATE_USE_OFFSCREEN_CANVAS;
|