@vertexvis/geometry 0.24.3-canary.0 → 0.24.3-canary.2

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.
@@ -42,3 +42,8 @@ export declare function union(...boxes: BoundingBox[]): BoundingBox | undefined;
42
42
  * bounding box for each axis.
43
43
  */
44
44
  export declare const lengths: (box: BoundingBox) => Vector3.Vector3;
45
+ /**
46
+ * Checks if each component of the given bounding box is populated with a numeric
47
+ * component. A component is invalid if it contains a non-finite or NaN value.
48
+ */
49
+ export declare function isValid(boundingBox: BoundingBox): boolean;
@@ -1200,7 +1200,7 @@ function create$a() {
1200
1200
  * Checks if each component of the given vector is populated with a numeric
1201
1201
  * component. A component is invalid if it contains a non-finite or NaN value.
1202
1202
  */
1203
- function isValid(_a) {
1203
+ function isValid$1(_a) {
1204
1204
  var x = _a.x, y = _a.y, z = _a.z;
1205
1205
  return [x, y, z].every(function (v) { return isFinite(v) && !isNaN(v); });
1206
1206
  }
@@ -1550,7 +1550,7 @@ function transformNdcToWorldSpace(ndc, worldMatrix, projectionMatrixInverse) {
1550
1550
  var vector3 = /*#__PURE__*/Object.freeze({
1551
1551
  __proto__: null,
1552
1552
  create: create$a,
1553
- isValid: isValid,
1553
+ isValid: isValid$1,
1554
1554
  fromMatrixScale: fromMatrixScale,
1555
1555
  fromMatrixPosition: fromMatrixPosition,
1556
1556
  fromJson: fromJson$2,
@@ -1636,7 +1636,16 @@ function union(box) {
1636
1636
  */
1637
1637
  var lengths = function (box) {
1638
1638
  return create$a(box.max.x - box.min.x, box.max.y - box.min.y, box.max.z - box.min.z);
1639
- };
1639
+ };
1640
+ /**
1641
+ * Checks if each component of the given bounding box is populated with a numeric
1642
+ * component. A component is invalid if it contains a non-finite or NaN value.
1643
+ */
1644
+ function isValid(boundingBox) {
1645
+ var maxIsValid = isValid$1(boundingBox.max);
1646
+ var minIsValid = isValid$1(boundingBox.min);
1647
+ return maxIsValid && minIsValid;
1648
+ }
1640
1649
 
1641
1650
  var boundingBox = /*#__PURE__*/Object.freeze({
1642
1651
  __proto__: null,
@@ -1646,7 +1655,8 @@ var boundingBox = /*#__PURE__*/Object.freeze({
1646
1655
  diagonal: diagonal,
1647
1656
  epsilon: epsilon,
1648
1657
  union: union,
1649
- lengths: lengths
1658
+ lengths: lengths,
1659
+ isValid: isValid
1650
1660
  });
1651
1661
 
1652
1662
  /**