@babylonjs/core 7.11.3 → 7.12.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.
Files changed (39) hide show
  1. package/Actions/abstractActionManager.d.ts +1 -1
  2. package/Actions/abstractActionManager.js +1 -1
  3. package/Actions/abstractActionManager.js.map +1 -1
  4. package/Compute/computeEffect.js +21 -3
  5. package/Compute/computeEffect.js.map +1 -1
  6. package/Culling/Helper/IBoundingInfoHelperPlatform.d.ts +8 -0
  7. package/Culling/Helper/IBoundingInfoHelperPlatform.js +2 -0
  8. package/Culling/Helper/IBoundingInfoHelperPlatform.js.map +1 -0
  9. package/Culling/Helper/boundingInfoHelper.d.ts +14 -10
  10. package/Culling/Helper/boundingInfoHelper.js +22 -152
  11. package/Culling/Helper/boundingInfoHelper.js.map +1 -1
  12. package/Culling/Helper/computeShaderBoundingHelper.d.ts +34 -0
  13. package/Culling/Helper/computeShaderBoundingHelper.js +209 -0
  14. package/Culling/Helper/computeShaderBoundingHelper.js.map +1 -0
  15. package/Culling/Helper/transformFeedbackBoundingHelper.d.ts +21 -0
  16. package/Culling/Helper/transformFeedbackBoundingHelper.js +197 -0
  17. package/Culling/Helper/transformFeedbackBoundingHelper.js.map +1 -0
  18. package/Culling/index.d.ts +2 -0
  19. package/Culling/index.js +2 -0
  20. package/Culling/index.js.map +1 -1
  21. package/Engines/Processors/shaderProcessingOptions.d.ts +1 -1
  22. package/Engines/Processors/shaderProcessingOptions.js.map +1 -1
  23. package/Engines/Processors/shaderProcessor.js +2 -2
  24. package/Engines/Processors/shaderProcessor.js.map +1 -1
  25. package/Engines/abstractEngine.js +2 -2
  26. package/Engines/abstractEngine.js.map +1 -1
  27. package/Meshes/abstractMesh.d.ts +7 -0
  28. package/Meshes/abstractMesh.js +19 -2
  29. package/Meshes/abstractMesh.js.map +1 -1
  30. package/Morph/morphTargetManager.d.ts +8 -4
  31. package/Morph/morphTargetManager.js +6 -3
  32. package/Morph/morphTargetManager.js.map +1 -1
  33. package/ShadersWGSL/boundingInfo.compute.d.ts +5 -0
  34. package/ShadersWGSL/boundingInfo.compute.js +80 -0
  35. package/ShadersWGSL/boundingInfo.compute.js.map +1 -0
  36. package/package.json +1 -1
  37. package/Culling/Helper/webgl2BoundingHelper.d.ts +0 -22
  38. package/Culling/Helper/webgl2BoundingHelper.js +0 -61
  39. package/Culling/Helper/webgl2BoundingHelper.js.map +0 -1
@@ -792,6 +792,13 @@ export declare abstract class AbstractMesh extends TransformNode implements IDis
792
792
  * @internal
793
793
  */
794
794
  _refreshBoundingInfo(data: Nullable<FloatArray>, bias: Nullable<Vector2>): void;
795
+ /**
796
+ * @internal
797
+ */
798
+ _refreshBoundingInfoDirect(extend: {
799
+ minimum: Vector3;
800
+ maximum: Vector3;
801
+ }): void;
795
802
  /**
796
803
  * Internal function to get buffer data and possibly apply morphs and normals
797
804
  * @param applySkeleton
@@ -1223,6 +1223,23 @@ export class AbstractMesh extends TransformNode {
1223
1223
  }
1224
1224
  this._updateBoundingInfo();
1225
1225
  }
1226
+ /**
1227
+ * @internal
1228
+ */
1229
+ _refreshBoundingInfoDirect(extend) {
1230
+ if (this._boundingInfo) {
1231
+ this._boundingInfo.reConstruct(extend.minimum, extend.maximum);
1232
+ }
1233
+ else {
1234
+ this._boundingInfo = new BoundingInfo(extend.minimum, extend.maximum);
1235
+ }
1236
+ if (this.subMeshes) {
1237
+ for (let index = 0; index < this.subMeshes.length; index++) {
1238
+ this.subMeshes[index].refreshBoundingInfo(null);
1239
+ }
1240
+ }
1241
+ this._updateBoundingInfo();
1242
+ }
1226
1243
  /**
1227
1244
  * Internal function to get buffer data and possibly apply morphs and normals
1228
1245
  * @param applySkeleton
@@ -1698,8 +1715,8 @@ export class AbstractMesh extends TransformNode {
1698
1715
  }
1699
1716
  // Action manager
1700
1717
  if (this.actionManager !== undefined && this.actionManager !== null) {
1701
- // If it's the only mesh using the action manager, dispose of it.
1702
- if (!this._scene.meshes.some((m) => m !== this && m.actionManager === this.actionManager) && this.actionManager.disposeWhenUnowned) {
1718
+ // If we are the only mesh using the action manager, dispose of the action manager too unless it has opted out from that behavior
1719
+ if (this.actionManager.disposeWhenUnowned && !this._scene.meshes.some((m) => m !== this && m.actionManager === this.actionManager)) {
1703
1720
  this.actionManager.dispose();
1704
1721
  }
1705
1722
  this.actionManager = null;