brepjs 20.13.1 → 20.13.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.
Files changed (93) hide show
  1. package/dist/2d.cjs +6 -6
  2. package/dist/2d.js +6 -6
  3. package/dist/{adjacencyFns-BA9xrrmS.cjs → adjacencyFns-BBugwmvl.cjs} +2 -2
  4. package/dist/{adjacencyFns-C4Tui11_.js → adjacencyFns-V29Gvfs9.js} +2 -2
  5. package/dist/{blueprint-D193PMxX.cjs → blueprint-BO8zuqoy.cjs} +5 -5
  6. package/dist/{blueprint-DH0H9OWv.js → blueprint-CDmOJybf.js} +5 -5
  7. package/dist/{blueprintFns-Bfiqbmtc.js → blueprintFns-CEKZsu4N.js} +2 -2
  8. package/dist/{blueprintFns-DYIKTIvJ.cjs → blueprintFns-Cki-iwEl.cjs} +2 -2
  9. package/dist/{blueprintSketcher-B1UrnhFt.cjs → blueprintSketcher-Bxkp-vjK.cjs} +3 -3
  10. package/dist/{blueprintSketcher-RA8ti2Xp.js → blueprintSketcher-DG_2zJg7.js} +3 -3
  11. package/dist/{boolean2D-XIehGONX.cjs → boolean2D-C_sEMz0u.cjs} +4 -4
  12. package/dist/{boolean2D-CCKUmway.js → boolean2D-DqCcYA2X.js} +4 -4
  13. package/dist/{booleanFns-zRlNDHQY.cjs → booleanFns-CA9tvtqr.cjs} +5 -5
  14. package/dist/{booleanFns-CyxmW1pL.js → booleanFns-CopMFBLS.js} +5 -5
  15. package/dist/brepjs.cjs +32 -30
  16. package/dist/brepjs.js +32 -30
  17. package/dist/{cameraFns-CtpBKmwD.js → cameraFns-BIIpsfds.js} +3 -3
  18. package/dist/{cameraFns-BDjt94fY.cjs → cameraFns-BJ35ht2H.cjs} +3 -3
  19. package/dist/core.cjs +2 -2
  20. package/dist/core.js +2 -2
  21. package/dist/{cornerFinder-CIryesVI.js → cornerFinder-C8VCstc3.js} +1 -1
  22. package/dist/{cornerFinder-DWN1Vkea.cjs → cornerFinder-D83OLL_I.cjs} +1 -1
  23. package/dist/{curveFns-b_C6tBeU.js → curveFns--TqXOi8f.js} +1 -1
  24. package/dist/{curveFns-0vAErrs9.cjs → curveFns-B29Eot3K.cjs} +1 -1
  25. package/dist/{drawFns-vcRf5KKV.cjs → drawFns-Bqs4HPzo.cjs} +12 -12
  26. package/dist/{drawFns--_Bd7ONO.js → drawFns-g9FrZ_P4.js} +12 -12
  27. package/dist/{faceFns-DzNcnzS5.cjs → faceFns-BeSpw0Dz.cjs} +2 -2
  28. package/dist/{faceFns-WtnWpVQl.js → faceFns-BzHfvPea.js} +2 -2
  29. package/dist/{healingFns-D26gj7M5.cjs → healingFns-BtZg6i3J.cjs} +30 -13
  30. package/dist/{healingFns-B82dNj9P.js → healingFns-DtefNa-x.js} +30 -13
  31. package/dist/{helpers-BO5NktbN.cjs → helpers-CFEuQ0ok.cjs} +6 -6
  32. package/dist/{helpers-C5I0ZqYC.js → helpers-CHUowMmV.js} +6 -6
  33. package/dist/{importFns-sxpO2z86.js → importFns-BLaneR8r.js} +5 -5
  34. package/dist/{importFns-Ceb2VgcK.cjs → importFns-BX0866c6.cjs} +5 -5
  35. package/dist/io.cjs +2 -2
  36. package/dist/io.js +2 -2
  37. package/dist/kernel/brepkit/brepkitWasmTypes.d.ts +0 -4
  38. package/dist/kernel/brepkit/helpers.d.ts +15 -0
  39. package/dist/kernel/brepkit/measureOps.d.ts +7 -0
  40. package/dist/kernel/brepkit/modifierOps.d.ts +11 -1
  41. package/dist/{loftFns-KXrP3aat.cjs → loftFns-Byjbneme.cjs} +31 -16
  42. package/dist/{loftFns-Y-aBF_f7.js → loftFns-Cth8Le9X.js} +32 -17
  43. package/dist/{measureFns-C8UjdHpB.cjs → measureFns-BlS2xJcn.cjs} +53 -9
  44. package/dist/{measureFns-B0PhQ5dY.js → measureFns-CLsSuByu.js} +49 -11
  45. package/dist/measurement/measureFns.d.ts +16 -1
  46. package/dist/measurement.cjs +2 -2
  47. package/dist/measurement.js +2 -2
  48. package/dist/{meshFns-BazHDlpY.js → meshFns-CzpP9SBf.js} +3 -3
  49. package/dist/{meshFns-BnkXZ0Xm.cjs → meshFns-ECQqx-8Q.cjs} +3 -3
  50. package/dist/operations/sweepFns.d.ts +7 -3
  51. package/dist/operations.cjs +2 -2
  52. package/dist/operations.js +2 -2
  53. package/dist/{primitiveFns-BM709SMs.cjs → primitiveFns-CzhQz02F.cjs} +5 -5
  54. package/dist/{primitiveFns-BZALpT35.js → primitiveFns-Kph3YP3A.js} +5 -5
  55. package/dist/{principalBoxFns-DLOoxmZB.js → principalBoxFns-C8ZmZNxJ.js} +3 -3
  56. package/dist/{principalBoxFns-C_hSxRc7.cjs → principalBoxFns-Ck9rR3Op.cjs} +3 -3
  57. package/dist/projection.cjs +1 -1
  58. package/dist/projection.js +1 -1
  59. package/dist/query.cjs +2 -2
  60. package/dist/query.js +2 -2
  61. package/dist/{refResolveFns-BkSLmvyY.cjs → refResolveFns-CVUSuVee.cjs} +6 -6
  62. package/dist/{refResolveFns-BA1ES0sL.js → refResolveFns-Cf16q6AH.js} +6 -6
  63. package/dist/{shapeFns-Bgql2_E6.cjs → shapeFns-BEwoFgq2.cjs} +2 -2
  64. package/dist/{shapeFns-CSWOXGx9.js → shapeFns-Bepwarf3.js} +2 -2
  65. package/dist/shapeRef.cjs +1 -1
  66. package/dist/shapeRef.js +1 -1
  67. package/dist/{shapeTypes-BFfnNmzj.cjs → shapeTypes-CIw6-GFy.cjs} +685 -175
  68. package/dist/{shapeTypes-C7hqbMwl.js → shapeTypes-hLHmANUz.js} +685 -175
  69. package/dist/sketching.cjs +3 -3
  70. package/dist/sketching.js +3 -3
  71. package/dist/{solidBuilders-CWw3yasa.cjs → solidBuilders-BVHK-era.cjs} +3 -3
  72. package/dist/{solidBuilders-B01dFnd7.js → solidBuilders-IA8xNuxJ.js} +3 -3
  73. package/dist/{surfaceBuilders-Cn7GIsyR.js → surfaceBuilders-BYwkPzfM.js} +3 -3
  74. package/dist/{surfaceBuilders-DL7UTpW2.cjs → surfaceBuilders-DIM5GSAT.cjs} +3 -3
  75. package/dist/text.cjs +2 -2
  76. package/dist/text.js +2 -2
  77. package/dist/{textBlueprints-B7gDC-aP.js → textBlueprints-B4w-_4_D.js} +8 -8
  78. package/dist/{textBlueprints-dOnCv38X.cjs → textBlueprints-CPJ6sBZZ.cjs} +8 -8
  79. package/dist/{textMetrics-Cqc0xzHC.cjs → textMetrics-Dfr_9G6g.cjs} +1 -1
  80. package/dist/{textMetrics-BFzj8Zvn.js → textMetrics-na1BYw65.js} +1 -1
  81. package/dist/{threadFns-M8pqF4TW.js → threadFns-BEO0-PP6.js} +7 -7
  82. package/dist/{threadFns-DwTPnV_1.cjs → threadFns-CAsRIX6c.cjs} +7 -7
  83. package/dist/topology/apiTypes.d.ts +7 -3
  84. package/dist/topology/chamferAngleFns.d.ts +2 -2
  85. package/dist/topology/evolutionFns.d.ts +1 -1
  86. package/dist/topology/modifierFns.d.ts +11 -4
  87. package/dist/topology.cjs +9 -9
  88. package/dist/topology.js +9 -9
  89. package/dist/{topologyQueryFns-95FptXtu.cjs → topologyQueryFns-BNDmjz7x.cjs} +1 -1
  90. package/dist/{topologyQueryFns-C3-_9dFM.js → topologyQueryFns-BYqsNs6q.js} +1 -1
  91. package/dist/{validityTypes-C6qOP241.js → validityTypes-BYhzdgTM.js} +1 -1
  92. package/dist/{validityTypes--tgDeAF8.cjs → validityTypes-Gd5B_HcL.cjs} +1 -1
  93. package/package.json +2 -2
@@ -1,7 +1,8 @@
1
- const require_shapeTypes = require("./shapeTypes-BFfnNmzj.cjs");
1
+ const require_shapeTypes = require("./shapeTypes-CIw6-GFy.cjs");
2
+ const require_occtWasmAdapter = require("./occtWasmAdapter-4YnvqZOW.cjs");
2
3
  const require_errors = require("./errors-O_blYTWT.cjs");
3
- const require_topologyQueryFns = require("./topologyQueryFns-95FptXtu.cjs");
4
- const require_faceFns = require("./faceFns-DzNcnzS5.cjs");
4
+ const require_topologyQueryFns = require("./topologyQueryFns-BNDmjz7x.cjs");
5
+ const require_faceFns = require("./faceFns-BeSpw0Dz.cjs");
5
6
  // src/measurement/measureCache.ts
6
7
  var cache = /* @__PURE__ */ new WeakMap();
7
8
  function getCachedMeasurement(shape, key) {
@@ -214,24 +215,56 @@ function measureLength(shape) {
214
215
  return require_errors.ok(props.value.mass);
215
216
  }
216
217
  /**
218
+ * The kernel's distance between two shapes, or `UNSUPPORTED_CAPABILITY` for a
219
+ * pair of shape types the kernel has no exact measure for (brepkit measures
220
+ * only from a point, or between solids).
221
+ *
222
+ * @internal
223
+ */
224
+ function kernelDistance(fn, a, b) {
225
+ try {
226
+ return require_errors.ok(require_shapeTypes.getKernel().distance(a, b));
227
+ } catch (e) {
228
+ if (!require_occtWasmAdapter.isUnsupportedKernelOperationError(e)) throw e;
229
+ return distanceUnsupported(fn, e);
230
+ }
231
+ }
232
+ function distanceUnsupported(fn, e) {
233
+ const kernelId = require_shapeTypes.getKernel().kernelId;
234
+ const raw = e instanceof Error ? e.message : String(e);
235
+ return require_errors.err(require_errors.unsupportedError(require_errors.BrepErrorCode.UNSUPPORTED_CAPABILITY, `${fn}: the ${kernelId} kernel cannot measure this distance (${raw})`, e, {
236
+ kernel: kernelId,
237
+ operation: fn
238
+ }, "Measure from a vertex or between two solids, or use the occt-wasm kernel"));
239
+ }
240
+ /**
217
241
  * Measure the minimum distance between two shapes.
242
+ *
243
+ * @returns Err `UNSUPPORTED_CAPABILITY` for a pair of shapes the kernel cannot
244
+ * measure exactly (on brepkit, anything but a vertex against a shape or a
245
+ * solid against a solid).
218
246
  */
219
247
  function measureDistance(shape1, shape2) {
220
248
  if (shapeIsNull(shape1)) return nullShapeErr("measureDistance");
221
249
  if (shapeIsNull(shape2)) return nullShapeErr("measureDistance");
222
- return require_errors.ok(require_shapeTypes.getKernel().distance(shape1.wrapped, shape2.wrapped).value);
250
+ const d = kernelDistance("measureDistance", shape1.wrapped, shape2.wrapped);
251
+ return d.ok ? require_errors.ok(d.value.value) : d;
223
252
  }
224
253
  /**
225
254
  * Measure the minimum distance between two shapes, including witness points.
255
+ *
256
+ * @returns Err `UNSUPPORTED_CAPABILITY` for a pair of shapes the kernel cannot
257
+ * measure exactly, as {@link measureDistance} does.
226
258
  */
227
259
  function measureDistanceProps(shape1, shape2) {
228
260
  if (shapeIsNull(shape1)) return nullShapeErr("measureDistanceProps");
229
261
  if (shapeIsNull(shape2)) return nullShapeErr("measureDistanceProps");
230
- const d = require_shapeTypes.getKernel().distance(shape1.wrapped, shape2.wrapped);
262
+ const d = kernelDistance("measureDistanceProps", shape1.wrapped, shape2.wrapped);
263
+ if (!d.ok) return d;
231
264
  return require_errors.ok({
232
- distance: d.value,
233
- point1: d.point1,
234
- point2: d.point2
265
+ distance: d.value.value,
266
+ point1: d.value.point1,
267
+ point2: d.value.point2
235
268
  });
236
269
  }
237
270
  /**
@@ -248,7 +281,12 @@ function createDistanceQuery(referenceShape) {
248
281
  return require_errors.ok({
249
282
  distanceTo(other) {
250
283
  if (shapeIsNull(other)) return nullShapeErr("createDistanceQuery.distanceTo");
251
- return require_errors.ok(query.distanceTo(other.wrapped).value);
284
+ try {
285
+ return require_errors.ok(query.distanceTo(other.wrapped).value);
286
+ } catch (e) {
287
+ if (!require_occtWasmAdapter.isUnsupportedKernelOperationError(e)) throw e;
288
+ return distanceUnsupported("createDistanceQuery.distanceTo", e);
289
+ }
252
290
  },
253
291
  dispose() {
254
292
  query.dispose();
@@ -307,6 +345,12 @@ Object.defineProperty(exports, "getCachedMeasurement", {
307
345
  return getCachedMeasurement;
308
346
  }
309
347
  });
348
+ Object.defineProperty(exports, "kernelDistance", {
349
+ enumerable: true,
350
+ get: function() {
351
+ return kernelDistance;
352
+ }
353
+ });
310
354
  Object.defineProperty(exports, "measureArea", {
311
355
  enumerable: true,
312
356
  get: function() {
@@ -1,7 +1,8 @@
1
- import { q as getKernel } from "./shapeTypes-C7hqbMwl.js";
2
- import { E as ok, d as validationError, g as err, t as BrepErrorCode } from "./errors-BTccWbtE.js";
3
- import { E as kernelCallRaw } from "./topologyQueryFns-C3-_9dFM.js";
4
- import { m as uvBounds } from "./faceFns-WtnWpVQl.js";
1
+ import { q as getKernel } from "./shapeTypes-hLHmANUz.js";
2
+ import { j as isUnsupportedKernelOperationError } from "./occtWasmAdapter-CGsnjMOe.js";
3
+ import { E as ok, d as validationError, g as err, t as BrepErrorCode, u as unsupportedError } from "./errors-BTccWbtE.js";
4
+ import { E as kernelCallRaw } from "./topologyQueryFns-BYqsNs6q.js";
5
+ import { m as uvBounds } from "./faceFns-BzHfvPea.js";
5
6
  // src/measurement/measureCache.ts
6
7
  var cache = /* @__PURE__ */ new WeakMap();
7
8
  function getCachedMeasurement(shape, key) {
@@ -214,24 +215,56 @@ function measureLength(shape) {
214
215
  return ok(props.value.mass);
215
216
  }
216
217
  /**
218
+ * The kernel's distance between two shapes, or `UNSUPPORTED_CAPABILITY` for a
219
+ * pair of shape types the kernel has no exact measure for (brepkit measures
220
+ * only from a point, or between solids).
221
+ *
222
+ * @internal
223
+ */
224
+ function kernelDistance(fn, a, b) {
225
+ try {
226
+ return ok(getKernel().distance(a, b));
227
+ } catch (e) {
228
+ if (!isUnsupportedKernelOperationError(e)) throw e;
229
+ return distanceUnsupported(fn, e);
230
+ }
231
+ }
232
+ function distanceUnsupported(fn, e) {
233
+ const kernelId = getKernel().kernelId;
234
+ const raw = e instanceof Error ? e.message : String(e);
235
+ return err(unsupportedError(BrepErrorCode.UNSUPPORTED_CAPABILITY, `${fn}: the ${kernelId} kernel cannot measure this distance (${raw})`, e, {
236
+ kernel: kernelId,
237
+ operation: fn
238
+ }, "Measure from a vertex or between two solids, or use the occt-wasm kernel"));
239
+ }
240
+ /**
217
241
  * Measure the minimum distance between two shapes.
242
+ *
243
+ * @returns Err `UNSUPPORTED_CAPABILITY` for a pair of shapes the kernel cannot
244
+ * measure exactly (on brepkit, anything but a vertex against a shape or a
245
+ * solid against a solid).
218
246
  */
219
247
  function measureDistance(shape1, shape2) {
220
248
  if (shapeIsNull(shape1)) return nullShapeErr("measureDistance");
221
249
  if (shapeIsNull(shape2)) return nullShapeErr("measureDistance");
222
- return ok(getKernel().distance(shape1.wrapped, shape2.wrapped).value);
250
+ const d = kernelDistance("measureDistance", shape1.wrapped, shape2.wrapped);
251
+ return d.ok ? ok(d.value.value) : d;
223
252
  }
224
253
  /**
225
254
  * Measure the minimum distance between two shapes, including witness points.
255
+ *
256
+ * @returns Err `UNSUPPORTED_CAPABILITY` for a pair of shapes the kernel cannot
257
+ * measure exactly, as {@link measureDistance} does.
226
258
  */
227
259
  function measureDistanceProps(shape1, shape2) {
228
260
  if (shapeIsNull(shape1)) return nullShapeErr("measureDistanceProps");
229
261
  if (shapeIsNull(shape2)) return nullShapeErr("measureDistanceProps");
230
- const d = getKernel().distance(shape1.wrapped, shape2.wrapped);
262
+ const d = kernelDistance("measureDistanceProps", shape1.wrapped, shape2.wrapped);
263
+ if (!d.ok) return d;
231
264
  return ok({
232
- distance: d.value,
233
- point1: d.point1,
234
- point2: d.point2
265
+ distance: d.value.value,
266
+ point1: d.value.point1,
267
+ point2: d.value.point2
235
268
  });
236
269
  }
237
270
  /**
@@ -248,7 +281,12 @@ function createDistanceQuery(referenceShape) {
248
281
  return ok({
249
282
  distanceTo(other) {
250
283
  if (shapeIsNull(other)) return nullShapeErr("createDistanceQuery.distanceTo");
251
- return ok(query.distanceTo(other.wrapped).value);
284
+ try {
285
+ return ok(query.distanceTo(other.wrapped).value);
286
+ } catch (e) {
287
+ if (!isUnsupportedKernelOperationError(e)) throw e;
288
+ return distanceUnsupported("createDistanceQuery.distanceTo", e);
289
+ }
252
290
  },
253
291
  dispose() {
254
292
  query.dispose();
@@ -295,4 +333,4 @@ function measureCurvatureAtMid(face) {
295
333
  minDirection: result.minDirection
296
334
  });
297
335
  }
298
- export { measureDistance as a, measureLinearProps as c, measureVolumeProps as d, withCompoundOf as f, setCachedMeasurement as h, measureCurvatureAtMid as i, measureSurfaceProps as l, getCachedMeasurement as m, measureArea as n, measureDistanceProps as o, withSubShapes as p, measureCurvatureAt as r, measureLength as s, createDistanceQuery as t, measureVolume as u };
336
+ export { measureCurvatureAtMid as a, measureLength as c, measureVolume as d, measureVolumeProps as f, setCachedMeasurement as g, getCachedMeasurement as h, measureCurvatureAt as i, measureLinearProps as l, withSubShapes as m, kernelDistance as n, measureDistance as o, withCompoundOf as p, measureArea as r, measureDistanceProps as s, createDistanceQuery as t, measureSurfaceProps as u };
@@ -1,4 +1,4 @@
1
- import { KernelShape, ShapeType } from '../kernel/types.js';
1
+ import { DistanceResult, KernelShape, ShapeType } from '../kernel/types.js';
2
2
  import { AnyShape, Dimension, Face, OrientedFace, Shape3D } from '../core/shapeTypes.js';
3
3
  import { Result } from '../core/result.js';
4
4
  import { CurvatureResult } from '../kernel/occt/measureOps.js';
@@ -64,12 +64,27 @@ export declare function measureArea(shape: Face<Dimension> | Shape3D): Result<nu
64
64
  * @see {@link measureLinearProps} for the full property set including center of mass.
65
65
  */
66
66
  export declare function measureLength(shape: AnyShape<Dimension>): Result<number>;
67
+ /**
68
+ * The kernel's distance between two shapes, or `UNSUPPORTED_CAPABILITY` for a
69
+ * pair of shape types the kernel has no exact measure for (brepkit measures
70
+ * only from a point, or between solids).
71
+ *
72
+ * @internal
73
+ */
74
+ export declare function kernelDistance(fn: string, a: KernelShape, b: KernelShape): Result<DistanceResult>;
67
75
  /**
68
76
  * Measure the minimum distance between two shapes.
77
+ *
78
+ * @returns Err `UNSUPPORTED_CAPABILITY` for a pair of shapes the kernel cannot
79
+ * measure exactly (on brepkit, anything but a vertex against a shape or a
80
+ * solid against a solid).
69
81
  */
70
82
  export declare function measureDistance(shape1: AnyShape<Dimension>, shape2: AnyShape<Dimension>): Result<number>;
71
83
  /**
72
84
  * Measure the minimum distance between two shapes, including witness points.
85
+ *
86
+ * @returns Err `UNSUPPORTED_CAPABILITY` for a pair of shapes the kernel cannot
87
+ * measure exactly, as {@link measureDistance} does.
73
88
  */
74
89
  export declare function measureDistanceProps(shape1: AnyShape<Dimension>, shape2: AnyShape<Dimension>): Result<DistanceProps>;
75
90
  /**
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_measureFns = require("./measureFns-C8UjdHpB.cjs");
3
- const require_principalBoxFns = require("./principalBoxFns-C_hSxRc7.cjs");
2
+ const require_measureFns = require("./measureFns-BlS2xJcn.cjs");
3
+ const require_principalBoxFns = require("./principalBoxFns-Ck9rR3Op.cjs");
4
4
  exports.createDistanceQuery = require_measureFns.createDistanceQuery;
5
5
  exports.measureArea = require_measureFns.measureArea;
6
6
  exports.measureDistance = require_measureFns.measureDistance;
@@ -1,3 +1,3 @@
1
- import { a as measureDistance, c as measureLinearProps, d as measureVolumeProps, l as measureSurfaceProps, n as measureArea, o as measureDistanceProps, s as measureLength, t as createDistanceQuery, u as measureVolume } from "./measureFns-B0PhQ5dY.js";
2
- import { t as principalBoundingBox } from "./principalBoxFns-DLOoxmZB.js";
1
+ import { c as measureLength, d as measureVolume, f as measureVolumeProps, l as measureLinearProps, o as measureDistance, r as measureArea, s as measureDistanceProps, t as createDistanceQuery, u as measureSurfaceProps } from "./measureFns-CLsSuByu.js";
2
+ import { t as principalBoundingBox } from "./principalBoxFns-C8ZmZNxJ.js";
3
3
  export { createDistanceQuery, measureArea, measureDistance, measureDistanceProps, measureLength, measureLinearProps, measureSurfaceProps, measureVolume, measureVolumeProps, principalBoundingBox };
@@ -1,8 +1,8 @@
1
- import { q as getKernel, ut as qualityDeflection } from "./shapeTypes-C7hqbMwl.js";
1
+ import { q as getKernel, ut as qualityDeflection } from "./shapeTypes-hLHmANUz.js";
2
2
  import { j as isUnsupportedKernelOperationError } from "./occtWasmAdapter-CGsnjMOe.js";
3
3
  import { E as ok, g as err, r as ioError, t as BrepErrorCode, u as unsupportedError } from "./errors-BTccWbtE.js";
4
- import { d as getSolids, n as getBounds } from "./topologyQueryFns-C3-_9dFM.js";
5
- import { d as getFaceOrigins } from "./solidBuilders-B01dFnd7.js";
4
+ import { d as getSolids, n as getBounds } from "./topologyQueryFns-BYqsNs6q.js";
5
+ import { d as getFaceOrigins } from "./solidBuilders-IA8xNuxJ.js";
6
6
  // src/topology/meshCache.ts
7
7
  /**
8
8
  * Build a parameter key for the inner cache map (excludes shape identity).
@@ -1,8 +1,8 @@
1
- const require_shapeTypes = require("./shapeTypes-BFfnNmzj.cjs");
1
+ const require_shapeTypes = require("./shapeTypes-CIw6-GFy.cjs");
2
2
  const require_occtWasmAdapter = require("./occtWasmAdapter-4YnvqZOW.cjs");
3
3
  const require_errors = require("./errors-O_blYTWT.cjs");
4
- const require_topologyQueryFns = require("./topologyQueryFns-95FptXtu.cjs");
5
- const require_solidBuilders = require("./solidBuilders-CWw3yasa.cjs");
4
+ const require_topologyQueryFns = require("./topologyQueryFns-BNDmjz7x.cjs");
5
+ const require_solidBuilders = require("./solidBuilders-BVHK-era.cjs");
6
6
  // src/topology/meshCache.ts
7
7
  /**
8
8
  * Build a parameter key for the inner cache map (excludes shape identity).
@@ -39,7 +39,9 @@ export interface GuidedSweepOptions {
39
39
  * @param spine - The path wire to sweep along.
40
40
  * @param config - Sweep configuration (frenet, transition mode, scaling law, etc.).
41
41
  * @param shellMode - When `true`, return `[shell, startWire, endWire]` instead of a solid.
42
- * @returns `Result` containing the swept shape, or a `[Shape3D, Wire, Wire]` tuple in shell mode.
42
+ * @returns `Result` containing the swept shape, or a `[Shape3D, Wire, Wire]` tuple in shell mode;
43
+ * Err `UNSUPPORTED_CAPABILITY` when the kernel cannot build the auxiliary spine or law
44
+ * (brepkit builds neither).
43
45
  */
44
46
  export declare function sweep(wire: ClosedWire<Dimension>, spine: Wire<Dimension>, config?: SweepOptions, shellMode?: false): Result<Shape3D>;
45
47
  /** Sweep in shell mode, returning `[shell, startWire, endWire]`. */
@@ -71,7 +73,8 @@ export declare function supportExtrude(wire: ClosedWire<Dimension>, center: Vec3
71
73
  * @param normal - Direction and length of the extrusion. Must be non-zero.
72
74
  * @param profileShape - Optional scaling profile applied along the extrusion.
73
75
  * @param shellMode - When `true`, return `[shell, startWire, endWire]` instead of a solid.
74
- * @returns `Result` containing the extruded shape, or a shell tuple in shell mode.
76
+ * @returns `Result` containing the extruded shape, or a shell tuple in shell mode; Err
77
+ * `UNSUPPORTED_CAPABILITY` for a profile on a kernel without a scaling-law sweep (brepkit).
75
78
  */
76
79
  export declare function complexExtrude(wire: ClosedWire<Dimension>, center: Vec3, normal: Vec3, profileShape?: ExtrusionProfile, shellMode?: false): Result<Shape3D>;
77
80
  /** Complex extrusion in shell mode, returning `[shell, startWire, endWire]`. */
@@ -91,7 +94,8 @@ export declare function complexExtrude(wire: ClosedWire<Dimension>, center: Vec3
91
94
  * @param normal - Direction and length of the extrusion. Must be non-zero.
92
95
  * @param profileShape - Optional scaling profile applied along the extrusion.
93
96
  * @param shellMode - When `true`, return `[shell, startWire, endWire]` instead of a solid.
94
- * @returns `Result` containing the twisted extruded shape, or a shell tuple in shell mode.
97
+ * @returns `Result` containing the twisted extruded shape, or a shell tuple in shell mode;
98
+ * Err `UNSUPPORTED_CAPABILITY` on a kernel without a twisted sweep (brepkit).
95
99
  */
96
100
  export declare function twistExtrude(wire: ClosedWire<Dimension>, angleDegrees: number, center: Vec3, normal: Vec3, profileShape?: ExtrusionProfile, shellMode?: false): Result<Shape3D>;
97
101
  /** Twisted extrusion in shell mode, returning `[shell, startWire, endWire]`. */
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_threadFns = require("./threadFns-DwTPnV_1.cjs");
3
- const require_loftFns = require("./loftFns-KXrP3aat.cjs");
2
+ const require_threadFns = require("./threadFns-CAsRIX6c.cjs");
3
+ const require_loftFns = require("./loftFns-Byjbneme.cjs");
4
4
  exports.addChild = require_threadFns.addChild;
5
5
  exports.addJoint = require_threadFns.addJoint;
6
6
  exports.addStep = require_threadFns.addStep;
@@ -1,3 +1,3 @@
1
- import { A as setJointValue, B as walkAssembly, C as cylindricalJoint, D as planarJoint, E as mechanismDOF, F as countNodes, H as circularPattern, I as createAssemblyNode, L as findNode, M as sphericalJoint, N as addChild, O as prismaticJoint, P as collectShapes, R as removeChild, S as addJoint, T as jointTransform, U as gridPattern, V as exportAssemblySTEP, W as linearPattern, Y as createAssembly, _ as exportURDF, b as inverseKinematics, c as modifyStep, d as replayFrom, f as replayHistory, g as undoLast, h as stepsFrom, i as createRegistry, j as setJointValues, k as revoluteJoint, l as registerOperation, m as stepCount, n as addStep, o as findStep, r as createHistory, s as getShape, t as thread, u as registerShape, v as importURDF, w as forwardKinematics, x as jointTrajectory, y as jointsFromDH, z as updateNode } from "./threadFns-M8pqF4TW.js";
2
- import { c as twistExtrude, o as supportExtrude, r as complexExtrude, s as sweep } from "./loftFns-Y-aBF_f7.js";
1
+ import { A as setJointValue, B as walkAssembly, C as cylindricalJoint, D as planarJoint, E as mechanismDOF, F as countNodes, H as circularPattern, I as createAssemblyNode, L as findNode, M as sphericalJoint, N as addChild, O as prismaticJoint, P as collectShapes, R as removeChild, S as addJoint, T as jointTransform, U as gridPattern, V as exportAssemblySTEP, W as linearPattern, Y as createAssembly, _ as exportURDF, b as inverseKinematics, c as modifyStep, d as replayFrom, f as replayHistory, g as undoLast, h as stepsFrom, i as createRegistry, j as setJointValues, k as revoluteJoint, l as registerOperation, m as stepCount, n as addStep, o as findStep, r as createHistory, s as getShape, t as thread, u as registerShape, v as importURDF, w as forwardKinematics, x as jointTrajectory, y as jointsFromDH, z as updateNode } from "./threadFns-BEO0-PP6.js";
2
+ import { c as twistExtrude, o as supportExtrude, r as complexExtrude, s as sweep } from "./loftFns-Cth8Le9X.js";
3
3
  export { addChild, addJoint, addStep, circularPattern, collectShapes, complexExtrude, countNodes, createAssembly, createAssemblyNode, createHistory, createRegistry, cylindricalJoint, exportAssemblySTEP, exportURDF, findNode, findStep, forwardKinematics, getShape as getHistoryShape, gridPattern, importURDF, inverseKinematics, jointTrajectory, jointTransform, jointsFromDH, linearPattern, mechanismDOF, modifyStep, planarJoint, prismaticJoint, registerOperation, registerShape, removeChild, replayFrom, replayHistory, revoluteJoint, setJointValue, setJointValues, sphericalJoint, stepCount, stepsFrom, supportExtrude, sweep, thread, twistExtrude, undoLast, updateNode, walkAssembly };
@@ -1,11 +1,11 @@
1
- const require_shapeTypes = require("./shapeTypes-BFfnNmzj.cjs");
1
+ const require_shapeTypes = require("./shapeTypes-CIw6-GFy.cjs");
2
2
  const require_errors = require("./errors-O_blYTWT.cjs");
3
- const require_validityTypes = require("./validityTypes--tgDeAF8.cjs");
3
+ const require_validityTypes = require("./validityTypes-Gd5B_HcL.cjs");
4
4
  const require_constants = require("./constants-oee0S_x6.cjs");
5
5
  const require_vecOps = require("./vecOps-CrGEPPQM.cjs");
6
- const require_solidBuilders = require("./solidBuilders-CWw3yasa.cjs");
7
- const require_booleanFns = require("./booleanFns-zRlNDHQY.cjs");
8
- const require_surfaceBuilders = require("./surfaceBuilders-DL7UTpW2.cjs");
6
+ const require_solidBuilders = require("./solidBuilders-BVHK-era.cjs");
7
+ const require_booleanFns = require("./booleanFns-CA9tvtqr.cjs");
8
+ const require_surfaceBuilders = require("./surfaceBuilders-DIM5GSAT.cjs");
9
9
  // src/topology/transformFns.ts
10
10
  /**
11
11
  * Immutable shape transforms — translate, rotate, scale, mirror, applyMatrix.
@@ -1,11 +1,11 @@
1
- import { E as GeometryCleanupError, G as _usingCtx, d as createSolid, n as castResultShape, q as getKernel } from "./shapeTypes-C7hqbMwl.js";
1
+ import { E as GeometryCleanupError, G as _usingCtx, d as createSolid, n as castResultShape, q as getKernel } from "./shapeTypes-hLHmANUz.js";
2
2
  import { E as ok, d as validationError, g as err, m as andThen, t as BrepErrorCode } from "./errors-BTccWbtE.js";
3
- import { n as isClosedWire } from "./validityTypes-C6qOP241.js";
3
+ import { n as isClosedWire } from "./validityTypes-BYhzdgTM.js";
4
4
  import { n as HASH_CODE_MAX, t as DEG2RAD } from "./constants-iraOnb2p.js";
5
5
  import { d as vecNormalize, h as vecScale } from "./vecOps-S-m9H_fe.js";
6
- import { a as makeOffset, c as makeTorus, i as makeEllipsoid, l as makeVertex, n as makeCone, o as makeSolid, r as makeCylinder, s as makeSphere, t as makeCompound, u as weldShellsAndFaces } from "./solidBuilders-B01dFnd7.js";
7
- import { f as collectInputFaceHashes, g as propagateMetadataThroughRelocation, h as propagateMetadataByHash, m as propagateAllMetadata, p as hasAnyMetadata } from "./booleanFns-CyxmW1pL.js";
8
- import { _ as makeThreePointArc, a as makeNonPlanarFace, c as makeBSplineApproximation, d as makeCircle, f as makeEllipse, g as makeTangentArc, h as makeLine, i as makeNewFaceWithinFace, m as makeHelix, o as makePolygon, p as makeEllipseArc, r as makeFace, s as assembleWire, t as addHolesInFace, u as makeBezierCurve } from "./surfaceBuilders-Cn7GIsyR.js";
6
+ import { a as makeOffset, c as makeTorus, i as makeEllipsoid, l as makeVertex, n as makeCone, o as makeSolid, r as makeCylinder, s as makeSphere, t as makeCompound, u as weldShellsAndFaces } from "./solidBuilders-IA8xNuxJ.js";
7
+ import { f as collectInputFaceHashes, g as propagateMetadataThroughRelocation, h as propagateMetadataByHash, m as propagateAllMetadata, p as hasAnyMetadata } from "./booleanFns-CopMFBLS.js";
8
+ import { _ as makeThreePointArc, a as makeNonPlanarFace, c as makeBSplineApproximation, d as makeCircle, f as makeEllipse, g as makeTangentArc, h as makeLine, i as makeNewFaceWithinFace, m as makeHelix, o as makePolygon, p as makeEllipseArc, r as makeFace, s as assembleWire, t as addHolesInFace, u as makeBezierCurve } from "./surfaceBuilders-BYwkPzfM.js";
9
9
  // src/topology/transformFns.ts
10
10
  /**
11
11
  * Immutable shape transforms — translate, rotate, scale, mirror, applyMatrix.
@@ -1,9 +1,9 @@
1
- import { G as _usingCtx, n as castResultShape, q as getKernel } from "./shapeTypes-C7hqbMwl.js";
1
+ import { G as _usingCtx, n as castResultShape, q as getKernel } from "./shapeTypes-hLHmANUz.js";
2
2
  import { i as wasmIndex } from "./bug-ClMTAJhe.js";
3
3
  import { E as ok, d as validationError, g as err, t as BrepErrorCode, u as unsupportedError } from "./errors-BTccWbtE.js";
4
- import { E as kernelCallRaw } from "./topologyQueryFns-C3-_9dFM.js";
4
+ import { E as kernelCallRaw } from "./topologyQueryFns-BYqsNs6q.js";
5
5
  import { r as vecCross } from "./vecOps-S-m9H_fe.js";
6
- import { f as withCompoundOf, h as setCachedMeasurement, m as getCachedMeasurement, p as withSubShapes } from "./measureFns-B0PhQ5dY.js";
6
+ import { g as setCachedMeasurement, h as getCachedMeasurement, m as withSubShapes, p as withCompoundOf } from "./measureFns-CLsSuByu.js";
7
7
  // src/measurement/principalBoxFns.ts
8
8
  /**
9
9
  * Principal-axes bounding box: a solid's extent measured in the frame of its
@@ -1,9 +1,9 @@
1
- const require_shapeTypes = require("./shapeTypes-BFfnNmzj.cjs");
1
+ const require_shapeTypes = require("./shapeTypes-CIw6-GFy.cjs");
2
2
  const require_bug = require("./bug-CBcpIPuf.cjs");
3
3
  const require_errors = require("./errors-O_blYTWT.cjs");
4
- const require_topologyQueryFns = require("./topologyQueryFns-95FptXtu.cjs");
4
+ const require_topologyQueryFns = require("./topologyQueryFns-BNDmjz7x.cjs");
5
5
  const require_vecOps = require("./vecOps-CrGEPPQM.cjs");
6
- const require_measureFns = require("./measureFns-C8UjdHpB.cjs");
6
+ const require_measureFns = require("./measureFns-BlS2xJcn.cjs");
7
7
  // src/measurement/principalBoxFns.ts
8
8
  /**
9
9
  * Principal-axes bounding box: a solid's extent measured in the frame of its
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_cameraFns = require("./cameraFns-BDjt94fY.cjs");
2
+ const require_cameraFns = require("./cameraFns-BJ35ht2H.cjs");
3
3
  exports.PROJECTION_PLANES = require_cameraFns.PROJECTION_PLANES;
4
4
  exports.cameraFromPlane = require_cameraFns.cameraFromPlane;
5
5
  exports.cameraLookAt = require_cameraFns.cameraLookAt;
@@ -1 +1 @@
1
- export { o as PROJECTION_PLANES, t as cameraFromPlane, n as cameraLookAt, r as createCamera, s as isProjectionPlane, a as makeProjectedEdges, i as projectEdges } from "./cameraFns-CtpBKmwD.js";
1
+ export { o as PROJECTION_PLANES, t as cameraFromPlane, n as cameraLookAt, r as createCamera, s as isProjectionPlane, a as makeProjectedEdges, i as projectEdges } from "./cameraFns-BIIpsfds.js";
package/dist/query.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_helpers = require("./helpers-BO5NktbN.cjs");
3
- const require_cornerFinder = require("./cornerFinder-DWN1Vkea.cjs");
2
+ const require_helpers = require("./helpers-CFEuQ0ok.cjs");
3
+ const require_cornerFinder = require("./cornerFinder-D83OLL_I.cjs");
4
4
  exports.cornerFinder = require_cornerFinder.cornerFinder;
5
5
  exports.edgeFinder = require_helpers.edgeFinder;
6
6
  exports.faceFinder = require_helpers.faceFinder;
package/dist/query.js CHANGED
@@ -1,3 +1,3 @@
1
- import { n as edgeFinder, r as faceFinder, t as getSingleFace } from "./helpers-C5I0ZqYC.js";
2
- import { t as cornerFinder } from "./cornerFinder-CIryesVI.js";
1
+ import { n as edgeFinder, r as faceFinder, t as getSingleFace } from "./helpers-CHUowMmV.js";
2
+ import { t as cornerFinder } from "./cornerFinder-C8VCstc3.js";
3
3
  export { cornerFinder, edgeFinder, faceFinder, getSingleFace };
@@ -1,10 +1,10 @@
1
- const require_shapeTypes = require("./shapeTypes-BFfnNmzj.cjs");
2
- const require_topologyQueryFns = require("./topologyQueryFns-95FptXtu.cjs");
3
- const require_faceFns = require("./faceFns-DzNcnzS5.cjs");
1
+ const require_shapeTypes = require("./shapeTypes-CIw6-GFy.cjs");
2
+ const require_topologyQueryFns = require("./topologyQueryFns-BNDmjz7x.cjs");
3
+ const require_faceFns = require("./faceFns-BeSpw0Dz.cjs");
4
4
  const require_faceRoleFns = require("./faceRoleFns-Db5bYj4Q.cjs");
5
- const require_shapeFns = require("./shapeFns-Bgql2_E6.cjs");
6
- const require_measureFns = require("./measureFns-C8UjdHpB.cjs");
7
- const require_adjacencyFns = require("./adjacencyFns-BA9xrrmS.cjs");
5
+ const require_shapeFns = require("./shapeFns-BEwoFgq2.cjs");
6
+ const require_measureFns = require("./measureFns-BlS2xJcn.cjs");
7
+ const require_adjacencyFns = require("./adjacencyFns-BBugwmvl.cjs");
8
8
  // src/topology/shapeRef/scoring.ts
9
9
  /**
10
10
  * Default face scorer combining surface type, normal alignment, centroid proximity,
@@ -1,10 +1,10 @@
1
- import { g as disposeTransientSubShape, o as castShapeWithKnownType, q as getKernel } from "./shapeTypes-C7hqbMwl.js";
2
- import { c as getFaces, w as vertexPosition } from "./topologyQueryFns-C3-_9dFM.js";
3
- import { i as faceGeomType, l as normalAt, r as faceCenter } from "./faceFns-WtnWpVQl.js";
1
+ import { g as disposeTransientSubShape, o as castShapeWithKnownType, q as getKernel } from "./shapeTypes-hLHmANUz.js";
2
+ import { c as getFaces, w as vertexPosition } from "./topologyQueryFns-BYqsNs6q.js";
3
+ import { i as faceGeomType, l as normalAt, r as faceCenter } from "./faceFns-BzHfvPea.js";
4
4
  import { t as getFaceRoles } from "./faceRoleFns-BPxzQF-n.js";
5
- import { n as getHashCode } from "./shapeFns-CSWOXGx9.js";
6
- import { n as measureArea, s as measureLength } from "./measureFns-B0PhQ5dY.js";
7
- import { a as facesOfVertex, c as verticesOfFace, i as facesOfEdge, o as sharedEdges, s as verticesOfEdge, t as adjacentFaceHashes } from "./adjacencyFns-C4Tui11_.js";
5
+ import { n as getHashCode } from "./shapeFns-Bepwarf3.js";
6
+ import { c as measureLength, r as measureArea } from "./measureFns-CLsSuByu.js";
7
+ import { a as facesOfVertex, c as verticesOfFace, i as facesOfEdge, o as sharedEdges, s as verticesOfEdge, t as adjacentFaceHashes } from "./adjacencyFns-V29Gvfs9.js";
8
8
  // src/topology/shapeRef/scoring.ts
9
9
  /**
10
10
  * Default face scorer combining surface type, normal alignment, centroid proximity,
@@ -1,6 +1,6 @@
1
- const require_shapeTypes = require("./shapeTypes-BFfnNmzj.cjs");
1
+ const require_shapeTypes = require("./shapeTypes-CIw6-GFy.cjs");
2
2
  const require_errors = require("./errors-O_blYTWT.cjs");
3
- const require_topologyQueryFns = require("./topologyQueryFns-95FptXtu.cjs");
3
+ const require_topologyQueryFns = require("./topologyQueryFns-BNDmjz7x.cjs");
4
4
  const require_constants = require("./constants-oee0S_x6.cjs");
5
5
  // src/topology/shapeFns.ts
6
6
  /**
@@ -1,6 +1,6 @@
1
- import { q as getKernel } from "./shapeTypes-C7hqbMwl.js";
1
+ import { q as getKernel } from "./shapeTypes-hLHmANUz.js";
2
2
  import { t as BrepErrorCode } from "./errors-BTccWbtE.js";
3
- import { E as kernelCallRaw, T as kernelCall } from "./topologyQueryFns-C3-_9dFM.js";
3
+ import { E as kernelCallRaw, T as kernelCall } from "./topologyQueryFns-BYqsNs6q.js";
4
4
  import { n as HASH_CODE_MAX } from "./constants-iraOnb2p.js";
5
5
  // src/topology/shapeFns.ts
6
6
  /**
package/dist/shapeRef.cjs CHANGED
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_refResolveFns = require("./refResolveFns-BkSLmvyY.cjs");
2
+ const require_refResolveFns = require("./refResolveFns-CVUSuVee.cjs");
3
3
  exports.assignRoles = require_refResolveFns.assignRoles;
4
4
  exports.captureHint = require_refResolveFns.captureHint;
5
5
  exports.createDerivedFaceRef = require_refResolveFns.createDerivedFaceRef;
package/dist/shapeRef.js CHANGED
@@ -1 +1 @@
1
- export { h as assignRoles, g as captureHint, l as createDerivedFaceRef, p as createEdgeRef, _ as createRef, d as createVertexRef, b as defaultScorer, t as isDerivedFaceRef, n as isEdgeRef, r as isFaceRef, i as isLineageRef, a as isVertexRef, u as resolveDerivedFaceRef, m as resolveEdgeRef, o as resolveLineageRef, v as resolveRef, s as resolveRefIn, c as resolveRefParams, f as resolveVertexRef, y as updateRoles } from "./refResolveFns-BA1ES0sL.js";
1
+ export { h as assignRoles, g as captureHint, l as createDerivedFaceRef, p as createEdgeRef, _ as createRef, d as createVertexRef, b as defaultScorer, t as isDerivedFaceRef, n as isEdgeRef, r as isFaceRef, i as isLineageRef, a as isVertexRef, u as resolveDerivedFaceRef, m as resolveEdgeRef, o as resolveLineageRef, v as resolveRef, s as resolveRefIn, c as resolveRefParams, f as resolveVertexRef, y as updateRoles } from "./refResolveFns-Cf16q6AH.js";