@galacean/engine-loader 1.1.0-beta.25 → 1.1.0-beta.28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/main.js CHANGED
@@ -538,6 +538,8 @@ var ReflectionParser = /*#__PURE__*/ function() {
538
538
  if (position) entity.transform.position.copyFrom(position);
539
539
  if (rotation) entity.transform.rotation.copyFrom(rotation);
540
540
  if (scale) entity.transform.scale.copyFrom(scale);
541
+ var _entityConfig_layer;
542
+ entity.layer = (_entityConfig_layer = entityConfig.layer) != null ? _entityConfig_layer : entity.layer;
541
543
  return entity;
542
544
  });
543
545
  };
@@ -5438,9 +5440,13 @@ var Texture2DLoader = /*#__PURE__*/ function(Loader1) {
5438
5440
  type: "image"
5439
5441
  });
5440
5442
  _this.request(url, requestConfig).then(function(image) {
5441
- var _params, _params1;
5442
- var params = item.params;
5443
- var texture = new engineCore.Texture2D(resourceManager.engine, image.width, image.height, (_params = params) == null ? void 0 : _params.format, (_params1 = params) == null ? void 0 : _params1.mipmap);
5443
+ var _item_params;
5444
+ var _ref = (_item_params = item.params) != null ? _item_params : {}, format = _ref.format, mipmap = _ref.mipmap, anisoLevel = _ref.anisoLevel, wrapModeU = _ref.wrapModeU, wrapModeV = _ref.wrapModeV, filterMode = _ref.filterMode;
5445
+ var texture = new engineCore.Texture2D(resourceManager.engine, image.width, image.height, format, mipmap);
5446
+ texture.anisoLevel = anisoLevel != null ? anisoLevel : texture.anisoLevel;
5447
+ texture.filterMode = filterMode != null ? filterMode : texture.filterMode;
5448
+ texture.wrapModeU = wrapModeU != null ? wrapModeU : texture.wrapModeU;
5449
+ texture.wrapModeV = wrapModeV != null ? wrapModeV : texture.wrapModeV;
5444
5450
  texture.setImageSource(image);
5445
5451
  texture.generateMipmaps();
5446
5452
  if (url.indexOf("data:") !== 0) {
@@ -5657,6 +5663,9 @@ var SceneLoader = /*#__PURE__*/ function(Loader1) {
5657
5663
  if (shadow.shadowResolution != undefined) scene.shadowResolution = shadow.shadowResolution;
5658
5664
  if (shadow.shadowDistance != undefined) scene.shadowDistance = shadow.shadowDistance;
5659
5665
  if (shadow.shadowCascades != undefined) scene.shadowCascades = shadow.shadowCascades;
5666
+ var _shadow_shadowTwoCascadeSplits;
5667
+ scene.shadowTwoCascadeSplits = (_shadow_shadowTwoCascadeSplits = shadow.shadowTwoCascadeSplits) != null ? _shadow_shadowTwoCascadeSplits : scene.shadowTwoCascadeSplits;
5668
+ shadow.shadowFourCascadeSplits && scene.shadowFourCascadeSplits.copyFrom(shadow.shadowFourCascadeSplits);
5660
5669
  }
5661
5670
  return Promise.all(promises).then(function() {
5662
5671
  resolve(scene);