brepjs 20.12.7 → 20.12.8

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 (94) hide show
  1. package/dist/2d.cjs +6 -6
  2. package/dist/2d.js +6 -6
  3. package/dist/{adjacencyFns-mMmTBUBY.cjs → adjacencyFns-BfgFo-Rh.cjs} +3 -3
  4. package/dist/{adjacencyFns-hMihivxC.js → adjacencyFns-Bl109A3Z.js} +3 -3
  5. package/dist/{blueprint-17RUHsoP.cjs → blueprint-DTDSztfd.cjs} +5 -5
  6. package/dist/{blueprint-BS50D3J_.js → blueprint-RqemOtg5.js} +5 -5
  7. package/dist/{blueprintFns-zy5lo2IF.js → blueprintFns-B9_PhTr8.js} +2 -2
  8. package/dist/{blueprintFns-Dw5_4_Bk.cjs → blueprintFns-C7E5R89N.cjs} +2 -2
  9. package/dist/{blueprintSketcher-C1WCI6E0.js → blueprintSketcher-B15522Kr.js} +3 -3
  10. package/dist/{blueprintSketcher-BG--DxWB.cjs → blueprintSketcher-Brj4lXjj.cjs} +3 -3
  11. package/dist/{boolean2D-7SQ3B0pC.cjs → boolean2D-DZ8aJbI-.cjs} +4 -4
  12. package/dist/{boolean2D-CsdyfjFE.js → boolean2D-_eiIiNw1.js} +4 -4
  13. package/dist/{solidBuilders-DdG4NPHM.cjs → booleanFns-D5nQ1nWS.cjs} +11 -217
  14. package/dist/{solidBuilders-Bmr59cGp.js → booleanFns-cNfXGqMX.js} +10 -156
  15. package/dist/brepjs.cjs +325 -168
  16. package/dist/brepjs.js +282 -125
  17. package/dist/{cameraFns-BAtzhCYM.cjs → cameraFns-6Er2lhp5.cjs} +3 -3
  18. package/dist/{cameraFns-BVWyAscu.js → cameraFns-YhB7A_Zc.js} +3 -3
  19. package/dist/core.cjs +2 -2
  20. package/dist/core.js +2 -2
  21. package/dist/{cornerFinder-e4Wc7_yp.cjs → cornerFinder-D9Wx3DWu.cjs} +1 -1
  22. package/dist/{cornerFinder-Dv_2rmaY.js → cornerFinder-G1WkSkVl.js} +1 -1
  23. package/dist/{curveFns-BAM7QHrP.cjs → curveFns-B5_N-gMj.cjs} +1 -1
  24. package/dist/{curveFns-CEI-rouh.js → curveFns-C4CqthJp.js} +1 -1
  25. package/dist/{drawFns-Cl1i8B_B.js → drawFns-DU5fewKl.js} +12 -12
  26. package/dist/{drawFns-d-RvC6u6.cjs → drawFns-UPbO2heB.cjs} +12 -12
  27. package/dist/{faceFns-Q87HCJrp.js → faceFns-BgRNa5vx.js} +2 -2
  28. package/dist/{faceFns-C-2ttg8X.cjs → faceFns-C4NOGZBg.cjs} +2 -2
  29. package/dist/{healingFns-Cm4NkKD8.js → healingFns-BzOo0yyz.js} +5 -5
  30. package/dist/{healingFns-DZkO5okn.cjs → healingFns-i5gV3BMG.cjs} +29 -29
  31. package/dist/{helpers-BdGGaLhF.cjs → helpers-DJQeDf_5.cjs} +6 -6
  32. package/dist/{helpers-DpGcM2qZ.js → helpers-DPHQt2Kr.js} +6 -6
  33. package/dist/{importFns-DLiP26NW.cjs → importFns-BiRpt227.cjs} +319 -14
  34. package/dist/{importFns-Bp-p0jiP.js → importFns-CwrJsNvg.js} +314 -15
  35. package/dist/io/igesSupport.d.ts +6 -0
  36. package/dist/io/importFns.d.ts +15 -5
  37. package/dist/io/ioUtils.d.ts +15 -3
  38. package/dist/io/meshNesting.d.ts +11 -0
  39. package/dist/io/threemfImportFns.d.ts +6 -3
  40. package/dist/io.cjs +2 -2
  41. package/dist/io.js +2 -2
  42. package/dist/kernel/occtWasm/occtWasmAdapter.cjs +1 -1
  43. package/dist/kernel/occtWasm/occtWasmAdapter.js +1 -1
  44. package/dist/kernel/occtWasm/occtWasmTypes.d.ts +4 -2
  45. package/dist/{loftFns-DGV1z2NJ.cjs → loftFns-DgkK4Kj_.cjs} +1 -1
  46. package/dist/{loftFns-DQ7Z29n3.js → loftFns-lwzTh1fI.js} +1 -1
  47. package/dist/{measureFns-BdSjw5fr.cjs → measureFns-D_RRjCZg.cjs} +3 -3
  48. package/dist/{measureFns-BrdCH4cH.js → measureFns-Q3K25IfN.js} +3 -3
  49. package/dist/measurement.cjs +2 -2
  50. package/dist/measurement.js +2 -2
  51. package/dist/{meshFns-UE8tByyw.js → meshFns-BGoJU6_P.js} +20 -6
  52. package/dist/{meshFns-BeubBqEI.cjs → meshFns-Djbb4PUC.cjs} +25 -5
  53. package/dist/{occtWasmAdapter-DA7oMgcQ.js → occtWasmAdapter-BCCwaYkq.js} +7 -5
  54. package/dist/{occtWasmAdapter-D3qerQTq.cjs → occtWasmAdapter-UcYZRi-w.cjs} +7 -5
  55. package/dist/operations.cjs +2 -2
  56. package/dist/operations.js +2 -2
  57. package/dist/{primitiveFns-CLGVLwG8.cjs → primitiveFns-CfSnex9P.cjs} +19 -18
  58. package/dist/{primitiveFns-3-gs-FUX.js → primitiveFns-D-aYcwt2.js} +5 -4
  59. package/dist/{principalBoxFns-RMZItjfR.js → principalBoxFns-Dcp9gg5e.js} +3 -3
  60. package/dist/{principalBoxFns-CiXzjOkr.cjs → principalBoxFns-IY8FfPVj.cjs} +3 -3
  61. package/dist/projection.cjs +1 -1
  62. package/dist/projection.js +1 -1
  63. package/dist/query.cjs +2 -2
  64. package/dist/query.js +2 -2
  65. package/dist/{refResolveFns-kJg2iCad.js → refResolveFns-BPge7T5w.js} +6 -6
  66. package/dist/{refResolveFns-DNX0bCrP.cjs → refResolveFns-gZQ1o5XK.cjs} +6 -6
  67. package/dist/{shapeFns-SgIrOjN4.cjs → shapeFns-Bs92VrZh.cjs} +2 -2
  68. package/dist/{shapeFns-CZ6VF1yd.js → shapeFns-TWdr4Dv4.js} +2 -2
  69. package/dist/shapeRef.cjs +1 -1
  70. package/dist/shapeRef.js +1 -1
  71. package/dist/{shapeTypes-BNGu103j.js → shapeTypes-CIH-8d_a.js} +1 -1
  72. package/dist/{shapeTypes-MUEH4XuH.cjs → shapeTypes-DmThK_oa.cjs} +1 -1
  73. package/dist/sketching.cjs +3 -3
  74. package/dist/sketching.js +3 -3
  75. package/dist/{originTrackingFns-rEKOAP65.cjs → solidBuilders-DGskMugU.cjs} +209 -2
  76. package/dist/{originTrackingFns-c2qgRZ_9.js → solidBuilders-q_hwYsdo.js} +150 -3
  77. package/dist/{surfaceBuilders-DI376ai0.js → surfaceBuilders-DXo4N7wQ.js} +3 -3
  78. package/dist/{surfaceBuilders-DOmDVuMs.cjs → surfaceBuilders-DeSLKg73.cjs} +3 -3
  79. package/dist/text.cjs +2 -2
  80. package/dist/text.js +2 -2
  81. package/dist/{textBlueprints-CE0oxB43.js → textBlueprints-BYWZho_c.js} +8 -7
  82. package/dist/{textBlueprints-B7Vhr0xu.cjs → textBlueprints-Dz6wNgve.cjs} +9 -8
  83. package/dist/{textMetrics-C6_kSht6.cjs → textMetrics-bKoFTj3m.cjs} +1 -1
  84. package/dist/{textMetrics-_VGqdewQ.js → textMetrics-k_rGqib2.js} +1 -1
  85. package/dist/{threadFns-CHdY-4Cz.js → threadFns-BeB8s0tA.js} +7 -7
  86. package/dist/{threadFns-1H60LrFX.cjs → threadFns-CoGAFHHt.cjs} +9 -9
  87. package/dist/topology/meshFns.d.ts +3 -0
  88. package/dist/topology.cjs +11 -11
  89. package/dist/topology.js +9 -9
  90. package/dist/{topologyQueryFns-C_fXO6xL.cjs → topologyQueryFns-CXbCFaU2.cjs} +1 -1
  91. package/dist/{topologyQueryFns-CltEv7Pi.js → topologyQueryFns-Cp0yekBh.js} +1 -1
  92. package/dist/{validityTypes-GanLrmvY.js → validityTypes-DlrWkrSR.js} +1 -1
  93. package/dist/{validityTypes-CGX2ES81.cjs → validityTypes-m6eLRTYE.cjs} +1 -1
  94. package/package.json +1 -1
@@ -1,7 +1,8 @@
1
- const require_shapeTypes = require("./shapeTypes-MUEH4XuH.cjs");
1
+ const require_shapeTypes = require("./shapeTypes-DmThK_oa.cjs");
2
+ const require_occtWasmAdapter = require("./occtWasmAdapter-UcYZRi-w.cjs");
2
3
  const require_errors = require("./errors-O_blYTWT.cjs");
3
- const require_topologyQueryFns = require("./topologyQueryFns-C_fXO6xL.cjs");
4
- const require_originTrackingFns = require("./originTrackingFns-rEKOAP65.cjs");
4
+ const require_topologyQueryFns = require("./topologyQueryFns-CXbCFaU2.cjs");
5
+ const require_solidBuilders = require("./solidBuilders-DGskMugU.cjs");
5
6
  // src/topology/meshCache.ts
6
7
  /**
7
8
  * Build a parameter key for the inner cache map (excludes shape identity).
@@ -107,6 +108,16 @@ function createMeshCache() {
107
108
  }
108
109
  };
109
110
  }
111
+ // src/io/igesSupport.ts
112
+ /**
113
+ * The capability error for an IGES call on a kernel built without an IGES
114
+ * translator (occt-wasm), or `null` when `cause` is any other failure.
115
+ */
116
+ function igesUnsupportedError(operation, cause) {
117
+ if (!require_occtWasmAdapter.isUnsupportedKernelOperationError(cause)) return null;
118
+ const kernel = require_shapeTypes.getKernel().kernelId;
119
+ return require_errors.unsupportedError(require_errors.BrepErrorCode.UNSUPPORTED_CAPABILITY, `${operation}: the ${kernel} kernel has no IGES support`, cause, { kernel }, "Exchange the model as STEP (importSTEP / exportSTEP) instead");
120
+ }
110
121
  // src/topology/meshFns.ts
111
122
  /**
112
123
  * Meshing and export functions — functional replacements for Shape mesh/export methods.
@@ -150,7 +161,7 @@ function mesh(shape, opts = {}) {
150
161
  includeUVs,
151
162
  ...signal ? { signal } : {}
152
163
  });
153
- const origins = require_originTrackingFns.getFaceOrigins(shape);
164
+ const origins = require_solidBuilders.getFaceOrigins(shape);
154
165
  const mesh = {
155
166
  vertices: result.vertices,
156
167
  normals: result.normals,
@@ -297,13 +308,16 @@ function exportSTL(shape, opts = {}) {
297
308
  * Export a shape as an IGES file Blob.
298
309
  *
299
310
  * @returns Ok with a Blob (MIME type `application/iges`), or Err on failure.
311
+ *
312
+ * @remarks The default occt-wasm kernel is built without an IGES translator, so
313
+ * there this returns an `UNSUPPORTED_CAPABILITY` error; export STEP instead.
300
314
  */
301
315
  function exportIGES(shape) {
302
316
  try {
303
317
  const igesString = require_shapeTypes.getKernel().exportIGES([shape.wrapped]);
304
318
  return require_errors.ok(new Blob([igesString], { type: "application/iges" }));
305
319
  } catch (e) {
306
- return require_errors.err(require_errors.ioError("IGES_EXPORT_FAILED", "Failed to write IGES file", e));
320
+ return require_errors.err(igesUnsupportedError("exportIGES", e) ?? require_errors.ioError("IGES_EXPORT_FAILED", "Failed to write IGES file", e));
307
321
  }
308
322
  }
309
323
  /**
@@ -472,6 +486,12 @@ Object.defineProperty(exports, "exportSTL", {
472
486
  return exportSTL;
473
487
  }
474
488
  });
489
+ Object.defineProperty(exports, "igesUnsupportedError", {
490
+ enumerable: true,
491
+ get: function() {
492
+ return igesUnsupportedError;
493
+ }
494
+ });
475
495
  Object.defineProperty(exports, "mesh", {
476
496
  enumerable: true,
477
497
  get: function() {
@@ -4508,13 +4508,15 @@ function importSTL(k, Module, data) {
4508
4508
  return wrapResult(k, k.importStl(""));
4509
4509
  }
4510
4510
  function exportIGES(k, makeCompound, shapes) {
4511
- if (shapes.length === 1) return k.exportIges(unwrap(shapes[0]));
4512
- const compound = makeCompound(shapes);
4513
- return k.exportIges(unwrap(compound));
4511
+ const exportIges = k.exportIges?.bind(k);
4512
+ if (!exportIges) throw new UnsupportedKernelOperationError("occt-wasm: exportIGES is unsupported");
4513
+ if (shapes.length === 1) return exportIges(unwrap(shapes[0]));
4514
+ return exportIges(unwrap(makeCompound(shapes)));
4514
4515
  }
4515
4516
  function importIGES(k, data) {
4516
- const str = typeof data === "string" ? data : new TextDecoder().decode(data);
4517
- return [wrapResult(k, k.importIges(str))];
4517
+ const importIges = k.importIges?.bind(k);
4518
+ if (!importIges) throw new UnsupportedKernelOperationError("occt-wasm: importIGES is unsupported");
4519
+ return [wrapResult(k, importIges(typeof data === "string" ? data : new TextDecoder().decode(data)))];
4518
4520
  }
4519
4521
  function exportSTEPAssembly(k, Module, parts, _options) {
4520
4522
  if (parts.length === 0) return "";
@@ -4508,13 +4508,15 @@ function importSTL(k, Module, data) {
4508
4508
  return wrapResult(k, k.importStl(""));
4509
4509
  }
4510
4510
  function exportIGES(k, makeCompound, shapes) {
4511
- if (shapes.length === 1) return k.exportIges(unwrap(shapes[0]));
4512
- const compound = makeCompound(shapes);
4513
- return k.exportIges(unwrap(compound));
4511
+ const exportIges = k.exportIges?.bind(k);
4512
+ if (!exportIges) throw new UnsupportedKernelOperationError("occt-wasm: exportIGES is unsupported");
4513
+ if (shapes.length === 1) return exportIges(unwrap(shapes[0]));
4514
+ return exportIges(unwrap(makeCompound(shapes)));
4514
4515
  }
4515
4516
  function importIGES(k, data) {
4516
- const str = typeof data === "string" ? data : new TextDecoder().decode(data);
4517
- return [wrapResult(k, k.importIges(str))];
4517
+ const importIges = k.importIges?.bind(k);
4518
+ if (!importIges) throw new UnsupportedKernelOperationError("occt-wasm: importIGES is unsupported");
4519
+ return [wrapResult(k, importIges(typeof data === "string" ? data : new TextDecoder().decode(data)))];
4518
4520
  }
4519
4521
  function exportSTEPAssembly(k, Module, parts, _options) {
4520
4522
  if (parts.length === 0) return "";
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_threadFns = require("./threadFns-1H60LrFX.cjs");
3
- const require_loftFns = require("./loftFns-DGV1z2NJ.cjs");
2
+ const require_threadFns = require("./threadFns-CoGAFHHt.cjs");
3
+ const require_loftFns = require("./loftFns-DgkK4Kj_.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-CHdY-4Cz.js";
2
- import { c as twistExtrude, o as supportExtrude, r as complexExtrude, s as sweep } from "./loftFns-DQ7Z29n3.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-BeB8s0tA.js";
2
+ import { c as twistExtrude, o as supportExtrude, r as complexExtrude, s as sweep } from "./loftFns-lwzTh1fI.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,10 +1,11 @@
1
- const require_shapeTypes = require("./shapeTypes-MUEH4XuH.cjs");
1
+ const require_shapeTypes = require("./shapeTypes-DmThK_oa.cjs");
2
2
  const require_errors = require("./errors-O_blYTWT.cjs");
3
- const require_validityTypes = require("./validityTypes-CGX2ES81.cjs");
3
+ const require_validityTypes = require("./validityTypes-m6eLRTYE.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-DdG4NPHM.cjs");
7
- const require_surfaceBuilders = require("./surfaceBuilders-DOmDVuMs.cjs");
6
+ const require_solidBuilders = require("./solidBuilders-DGskMugU.cjs");
7
+ const require_booleanFns = require("./booleanFns-D5nQ1nWS.cjs");
8
+ const require_surfaceBuilders = require("./surfaceBuilders-DeSLKg73.cjs");
8
9
  // src/topology/transformFns.ts
9
10
  /**
10
11
  * Immutable shape transforms — translate, rotate, scale, mirror, applyMatrix.
@@ -12,10 +13,10 @@ const require_surfaceBuilders = require("./surfaceBuilders-DOmDVuMs.cjs");
12
13
  */
13
14
  /** Translate a shape by a vector. Returns a new shape. */
14
15
  function translate(shape, v) {
15
- const inputFaceHashes = require_solidBuilders.collectInputFaceHashes([shape]);
16
+ const inputFaceHashes = require_booleanFns.collectInputFaceHashes([shape]);
16
17
  const { shape: resultShape, evolution } = require_shapeTypes.getKernel().translateWithHistory(shape.wrapped, v[0], v[1], v[2], inputFaceHashes, require_constants.HASH_CODE_MAX);
17
18
  const result = require_shapeTypes.castResultShape(resultShape);
18
- require_solidBuilders.propagateAllMetadata(evolution, [shape], result);
19
+ require_booleanFns.propagateAllMetadata(evolution, [shape], result);
19
20
  return result;
20
21
  }
21
22
  /** Rotate a shape around an axis. Angle is in degrees. Returns a new shape. */
@@ -28,10 +29,10 @@ function rotate(shape, angle, position = [
28
29
  0,
29
30
  1
30
31
  ]) {
31
- const inputFaceHashes = require_solidBuilders.collectInputFaceHashes([shape]);
32
+ const inputFaceHashes = require_booleanFns.collectInputFaceHashes([shape]);
32
33
  const { shape: resultShape, evolution } = require_shapeTypes.getKernel().rotateWithHistory(shape.wrapped, angle * require_constants.DEG2RAD, inputFaceHashes, require_constants.HASH_CODE_MAX, direction, position);
33
34
  const result = require_shapeTypes.castResultShape(resultShape);
34
- require_solidBuilders.propagateAllMetadata(evolution, [shape], result);
35
+ require_booleanFns.propagateAllMetadata(evolution, [shape], result);
35
36
  return result;
36
37
  }
37
38
  /** Mirror a shape through a plane defined by origin and normal. Returns a new shape. */
@@ -44,10 +45,10 @@ function mirror(shape, planeNormal = [
44
45
  0,
45
46
  0
46
47
  ]) {
47
- const inputFaceHashes = require_solidBuilders.collectInputFaceHashes([shape]);
48
+ const inputFaceHashes = require_booleanFns.collectInputFaceHashes([shape]);
48
49
  const { shape: resultShape, evolution } = require_shapeTypes.getKernel().mirrorWithHistory(shape.wrapped, planeOrigin, planeNormal, inputFaceHashes, require_constants.HASH_CODE_MAX);
49
50
  const result = require_shapeTypes.castResultShape(resultShape);
50
- require_solidBuilders.propagateAllMetadata(evolution, [shape], result);
51
+ require_booleanFns.propagateAllMetadata(evolution, [shape], result);
51
52
  return result;
52
53
  }
53
54
  /** Scale a shape uniformly. Returns a new shape. */
@@ -56,10 +57,10 @@ function scale(shape, factor, center = [
56
57
  0,
57
58
  0
58
59
  ]) {
59
- const inputFaceHashes = require_solidBuilders.collectInputFaceHashes([shape]);
60
+ const inputFaceHashes = require_booleanFns.collectInputFaceHashes([shape]);
60
61
  const { shape: resultShape, evolution } = require_shapeTypes.getKernel().scaleWithHistory(shape.wrapped, center, factor, inputFaceHashes, require_constants.HASH_CODE_MAX);
61
62
  const result = require_shapeTypes.castResultShape(resultShape);
62
- require_solidBuilders.propagateAllMetadata(evolution, [shape], result);
63
+ require_booleanFns.propagateAllMetadata(evolution, [shape], result);
63
64
  return result;
64
65
  }
65
66
  /** Resize a shape to exact target dimensions with optional auto-proportional scaling. */
@@ -167,16 +168,16 @@ function applyMatrix(shape, matrix) {
167
168
  const d = det3x3(linear);
168
169
  if (Math.abs(d) < 1e-12) return require_errors.err(require_errors.validationError(require_errors.BrepErrorCode.VALIDATION_FAILED, "applyMatrix: singular matrix (determinant ≈ 0). Cannot apply a non-invertible transform."));
169
170
  if (isOrthogonalMatrix(linear)) {
170
- const inputFaceHashes = require_solidBuilders.collectInputFaceHashes([shape]);
171
+ const inputFaceHashes = require_booleanFns.collectInputFaceHashes([shape]);
171
172
  const { shape: resultShape, evolution } = require_shapeTypes.getKernel().generalTransformWithHistory(shape.wrapped, linear, translation, true, inputFaceHashes, require_constants.HASH_CODE_MAX);
172
173
  const result = require_shapeTypes.castResultShape(resultShape);
173
- require_solidBuilders.propagateAllMetadata(evolution, [shape], result);
174
+ require_booleanFns.propagateAllMetadata(evolution, [shape], result);
174
175
  return require_errors.ok(result);
175
176
  }
176
177
  /* v8 ignore start -- untestable until WASM is rebuilt with BRepBuilderAPI_GTransform */
177
178
  const resultShape = require_shapeTypes.getKernel().generalTransformNonOrthogonal(shape.wrapped, linear, translation);
178
179
  const result = require_shapeTypes.castResultShape(resultShape);
179
- require_solidBuilders.propagateMetadataByHash([shape], result);
180
+ require_booleanFns.propagateMetadataByHash([shape], result);
180
181
  return require_errors.ok(result);
181
182
  /* v8 ignore stop */
182
183
  }
@@ -244,7 +245,7 @@ function locate(shape, placement) {
244
245
  } finally {
245
246
  _usingCtx$2.d();
246
247
  }
247
- if (require_solidBuilders.hasAnyMetadata(shape)) require_solidBuilders.propagateMetadataThroughRelocation(shape, moved);
248
+ if (require_booleanFns.hasAnyMetadata(shape)) require_booleanFns.propagateMetadataThroughRelocation(shape, moved);
248
249
  return moved;
249
250
  } catch (cause) {
250
251
  if (moved !== void 0) try {
@@ -264,10 +265,10 @@ function locate(shape, placement) {
264
265
  * Much faster than separate clone() + translate() + rotate() calls.
265
266
  */
266
267
  function transformCopy(shape, composed) {
267
- const inputFaceHashes = require_solidBuilders.collectInputFaceHashes([shape]);
268
+ const inputFaceHashes = require_booleanFns.collectInputFaceHashes([shape]);
268
269
  const { shape: resultShape, evolution } = require_shapeTypes.getKernel().applyComposedTransformWithHistory(shape.wrapped, composed.trsf, inputFaceHashes, require_constants.HASH_CODE_MAX);
269
270
  const result = require_shapeTypes.castResultShape(resultShape);
270
- require_solidBuilders.propagateAllMetadata(evolution, [shape], result);
271
+ require_booleanFns.propagateAllMetadata(evolution, [shape], result);
271
272
  return result;
272
273
  }
273
274
  // src/topology/primitiveFns.ts
@@ -1,10 +1,11 @@
1
- import { E as GeometryCleanupError, G as _usingCtx, d as createSolid, n as castResultShape, q as getKernel } from "./shapeTypes-BNGu103j.js";
1
+ import { E as GeometryCleanupError, G as _usingCtx, d as createSolid, n as castResultShape, q as getKernel } from "./shapeTypes-CIH-8d_a.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-GanLrmvY.js";
3
+ import { n as isClosedWire } from "./validityTypes-DlrWkrSR.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 { C as propagateAllMetadata, S as hasAnyMetadata, T as propagateMetadataThroughRelocation, 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, w as propagateMetadataByHash, x as collectInputFaceHashes } from "./solidBuilders-Bmr59cGp.js";
7
- 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-DI376ai0.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-q_hwYsdo.js";
7
+ import { d as collectInputFaceHashes, f as hasAnyMetadata, h as propagateMetadataThroughRelocation, m as propagateMetadataByHash, p as propagateAllMetadata } from "./booleanFns-cNfXGqMX.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-DXo4N7wQ.js";
8
9
  // src/topology/transformFns.ts
9
10
  /**
10
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-BNGu103j.js";
1
+ import { G as _usingCtx, n as castResultShape, q as getKernel } from "./shapeTypes-CIH-8d_a.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, S as subShapeCount } from "./topologyQueryFns-CltEv7Pi.js";
4
+ import { E as kernelCallRaw, S as subShapeCount } from "./topologyQueryFns-Cp0yekBh.js";
5
5
  import { r as vecCross } from "./vecOps-S-m9H_fe.js";
6
- import { f as getCachedMeasurement, p as setCachedMeasurement } from "./measureFns-BrdCH4cH.js";
6
+ import { f as getCachedMeasurement, p as setCachedMeasurement } from "./measureFns-Q3K25IfN.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-MUEH4XuH.cjs");
1
+ const require_shapeTypes = require("./shapeTypes-DmThK_oa.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-C_fXO6xL.cjs");
4
+ const require_topologyQueryFns = require("./topologyQueryFns-CXbCFaU2.cjs");
5
5
  const require_vecOps = require("./vecOps-CrGEPPQM.cjs");
6
- const require_measureFns = require("./measureFns-BdSjw5fr.cjs");
6
+ const require_measureFns = require("./measureFns-D_RRjCZg.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-BAtzhCYM.cjs");
2
+ const require_cameraFns = require("./cameraFns-6Er2lhp5.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-BVWyAscu.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-YhB7A_Zc.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-BdGGaLhF.cjs");
3
- const require_cornerFinder = require("./cornerFinder-e4Wc7_yp.cjs");
2
+ const require_helpers = require("./helpers-DJQeDf_5.cjs");
3
+ const require_cornerFinder = require("./cornerFinder-D9Wx3DWu.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-DpGcM2qZ.js";
2
- import { t as cornerFinder } from "./cornerFinder-Dv_2rmaY.js";
1
+ import { n as edgeFinder, r as faceFinder, t as getSingleFace } from "./helpers-DPHQt2Kr.js";
2
+ import { t as cornerFinder } from "./cornerFinder-G1WkSkVl.js";
3
3
  export { cornerFinder, edgeFinder, faceFinder, getSingleFace };
@@ -1,10 +1,10 @@
1
- import { g as disposeTransientSubShape, o as castShapeWithKnownType, q as getKernel } from "./shapeTypes-BNGu103j.js";
2
- import { c as getFaces, w as vertexPosition } from "./topologyQueryFns-CltEv7Pi.js";
3
- import { i as faceGeomType, l as normalAt, r as faceCenter } from "./faceFns-Q87HCJrp.js";
1
+ import { g as disposeTransientSubShape, o as castShapeWithKnownType, q as getKernel } from "./shapeTypes-CIH-8d_a.js";
2
+ import { c as getFaces, w as vertexPosition } from "./topologyQueryFns-Cp0yekBh.js";
3
+ import { i as faceGeomType, l as normalAt, r as faceCenter } from "./faceFns-BgRNa5vx.js";
4
4
  import { t as getFaceRoles } from "./faceRoleFns-BPxzQF-n.js";
5
- import { n as getHashCode } from "./shapeFns-CZ6VF1yd.js";
6
- import { n as measureArea, s as measureLength } from "./measureFns-BrdCH4cH.js";
7
- import { a as facesOfVertex, c as verticesOfFace, i as facesOfEdge, o as sharedEdges, s as verticesOfEdge, t as adjacentFaceHashes } from "./adjacencyFns-hMihivxC.js";
5
+ import { n as getHashCode } from "./shapeFns-TWdr4Dv4.js";
6
+ import { n as measureArea, s as measureLength } from "./measureFns-Q3K25IfN.js";
7
+ import { a as facesOfVertex, c as verticesOfFace, i as facesOfEdge, o as sharedEdges, s as verticesOfEdge, t as adjacentFaceHashes } from "./adjacencyFns-Bl109A3Z.js";
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
- const require_shapeTypes = require("./shapeTypes-MUEH4XuH.cjs");
2
- const require_topologyQueryFns = require("./topologyQueryFns-C_fXO6xL.cjs");
3
- const require_faceFns = require("./faceFns-C-2ttg8X.cjs");
1
+ const require_shapeTypes = require("./shapeTypes-DmThK_oa.cjs");
2
+ const require_topologyQueryFns = require("./topologyQueryFns-CXbCFaU2.cjs");
3
+ const require_faceFns = require("./faceFns-C4NOGZBg.cjs");
4
4
  const require_faceRoleFns = require("./faceRoleFns-Db5bYj4Q.cjs");
5
- const require_shapeFns = require("./shapeFns-SgIrOjN4.cjs");
6
- const require_measureFns = require("./measureFns-BdSjw5fr.cjs");
7
- const require_adjacencyFns = require("./adjacencyFns-mMmTBUBY.cjs");
5
+ const require_shapeFns = require("./shapeFns-Bs92VrZh.cjs");
6
+ const require_measureFns = require("./measureFns-D_RRjCZg.cjs");
7
+ const require_adjacencyFns = require("./adjacencyFns-BfgFo-Rh.cjs");
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-MUEH4XuH.cjs");
1
+ const require_shapeTypes = require("./shapeTypes-DmThK_oa.cjs");
2
2
  const require_errors = require("./errors-O_blYTWT.cjs");
3
- const require_topologyQueryFns = require("./topologyQueryFns-C_fXO6xL.cjs");
3
+ const require_topologyQueryFns = require("./topologyQueryFns-CXbCFaU2.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-BNGu103j.js";
1
+ import { q as getKernel } from "./shapeTypes-CIH-8d_a.js";
2
2
  import { t as BrepErrorCode } from "./errors-BTccWbtE.js";
3
- import { E as kernelCallRaw, T as kernelCall } from "./topologyQueryFns-CltEv7Pi.js";
3
+ import { E as kernelCallRaw, T as kernelCall } from "./topologyQueryFns-Cp0yekBh.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-DNX0bCrP.cjs");
2
+ const require_refResolveFns = require("./refResolveFns-gZQ1o5XK.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-kJg2iCad.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-BPge7T5w.js";
@@ -1,4 +1,4 @@
1
- import { A as UnsupportedKernelOperationError, C as reverseCurve2d$2, D as tangentCurve2d, E as serializeCurve2d$2, N as EXACT_BREP_CAPABILITIES, O as translateCurve2d$2, P as OCCT_CAPABILITIES, S as offsetCurve2d$2, T as scaleCurve2d$2, _ as makeCircle2d$2, a as buildAsciiSTL, b as mirrorAcrossAxis, c as createBBox2d, d as deserializeCurve2d$2, f as evaluateCurve2d$2, g as makeBezier2d$2, h as makeArc2dThreePoints, i as DEFAULT_STL_TOLERANCE, j as isUnsupportedKernelOperationError, k as quickHull, l as curveBounds, m as makeArc2dTangent, o as buildBinarySTL, p as intersectCurves2dFn, r as DEFAULT_STL_ANGULAR_TOLERANCE, s as addCurveToBBox, t as OcctWasmAdapter, u as curveTypeName, v as makeEllipse2d$2, w as rotateCurve2d$2, x as mirrorAtPoint, y as makeLine2d$2 } from "./occtWasmAdapter-DA7oMgcQ.js";
1
+ import { A as UnsupportedKernelOperationError, C as reverseCurve2d$2, D as tangentCurve2d, E as serializeCurve2d$2, N as EXACT_BREP_CAPABILITIES, O as translateCurve2d$2, P as OCCT_CAPABILITIES, S as offsetCurve2d$2, T as scaleCurve2d$2, _ as makeCircle2d$2, a as buildAsciiSTL, b as mirrorAcrossAxis, c as createBBox2d, d as deserializeCurve2d$2, f as evaluateCurve2d$2, g as makeBezier2d$2, h as makeArc2dThreePoints, i as DEFAULT_STL_TOLERANCE, j as isUnsupportedKernelOperationError, k as quickHull, l as curveBounds, m as makeArc2dTangent, o as buildBinarySTL, p as intersectCurves2dFn, r as DEFAULT_STL_ANGULAR_TOLERANCE, s as addCurveToBBox, t as OcctWasmAdapter, u as curveTypeName, v as makeEllipse2d$2, w as rotateCurve2d$2, x as mirrorAtPoint, y as makeLine2d$2 } from "./occtWasmAdapter-BCCwaYkq.js";
2
2
  import { i as wasmIndex, r as vec3At } from "./bug-ClMTAJhe.js";
3
3
  // src/kernel/quality.ts
4
4
  /**
@@ -1,4 +1,4 @@
1
- const require_occtWasmAdapter = require("./occtWasmAdapter-D3qerQTq.cjs");
1
+ const require_occtWasmAdapter = require("./occtWasmAdapter-UcYZRi-w.cjs");
2
2
  const require_bug = require("./bug-CBcpIPuf.cjs");
3
3
  // src/kernel/quality.ts
4
4
  /**
@@ -1,7 +1,7 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_blueprintSketcher = require("./blueprintSketcher-BG--DxWB.cjs");
3
- const require_drawFns = require("./drawFns-d-RvC6u6.cjs");
4
- const require_textBlueprints = require("./textBlueprints-B7Vhr0xu.cjs");
2
+ const require_blueprintSketcher = require("./blueprintSketcher-Brj4lXjj.cjs");
3
+ const require_drawFns = require("./drawFns-UPbO2heB.cjs");
4
+ const require_textBlueprints = require("./textBlueprints-Dz6wNgve.cjs");
5
5
  // src/sketching.ts
6
6
  /**
7
7
  * brepjs/sketching — Sketcher, Drawing, and sketch-to-shape operations.
package/dist/sketching.js CHANGED
@@ -1,6 +1,6 @@
1
- import { n as BaseSketcher2d, t as BlueprintSketcher } from "./blueprintSketcher-C1WCI6E0.js";
2
- import { A as sketchEllipse, C as DrawingPen, D as makeBaseBox, E as deserializeDrawing, F as sketchRectangle, I as sketchRoundedRectangle, L as FaceSketcher, M as sketchHelix, N as sketchParametricFunction, O as polysideInnerRadius, P as sketchPolysides, R as Sketcher, S as drawText, T as Drawing, _ as drawPolysides, a as drawingIntersect, b as drawSingleCircle, c as rotateDrawing, d as drawFaceOutline, f as drawProjection, g as drawPointsInterpolation, h as drawParametricFunction, i as drawingFuse, j as sketchFaceOffset, k as sketchCircle, l as scaleDrawing, m as drawEllipse, n as drawingCut, o as drawingToSketchOnPlane, p as drawCircle, r as drawingFillet, s as mirrorDrawing, t as drawingChamfer, u as translateDrawing, v as drawRectangle, w as draw, x as drawSingleEllipse, y as drawRoundedRectangle } from "./drawFns-Cl1i8B_B.js";
3
- import { a as Sketches, c as compoundSketchFace, d as sketchExtrude, f as sketchFace, g as sketchWires, h as sketchSweep, l as compoundSketchLoft, m as sketchRevolve, o as Sketch, p as sketchLoft, s as compoundSketchExtrude, u as compoundSketchRevolve, y as CompoundSketch } from "./textBlueprints-CE0oxB43.js";
1
+ import { n as BaseSketcher2d, t as BlueprintSketcher } from "./blueprintSketcher-B15522Kr.js";
2
+ import { A as sketchEllipse, C as DrawingPen, D as makeBaseBox, E as deserializeDrawing, F as sketchRectangle, I as sketchRoundedRectangle, L as FaceSketcher, M as sketchHelix, N as sketchParametricFunction, O as polysideInnerRadius, P as sketchPolysides, R as Sketcher, S as drawText, T as Drawing, _ as drawPolysides, a as drawingIntersect, b as drawSingleCircle, c as rotateDrawing, d as drawFaceOutline, f as drawProjection, g as drawPointsInterpolation, h as drawParametricFunction, i as drawingFuse, j as sketchFaceOffset, k as sketchCircle, l as scaleDrawing, m as drawEllipse, n as drawingCut, o as drawingToSketchOnPlane, p as drawCircle, r as drawingFillet, s as mirrorDrawing, t as drawingChamfer, u as translateDrawing, v as drawRectangle, w as draw, x as drawSingleEllipse, y as drawRoundedRectangle } from "./drawFns-DU5fewKl.js";
3
+ import { a as Sketches, c as compoundSketchFace, d as sketchExtrude, f as sketchFace, g as sketchWires, h as sketchSweep, l as compoundSketchLoft, m as sketchRevolve, o as Sketch, p as sketchLoft, s as compoundSketchExtrude, u as compoundSketchRevolve, y as CompoundSketch } from "./textBlueprints-BYWZho_c.js";
4
4
  // src/sketching.ts
5
5
  /**
6
6
  * brepjs/sketching — Sketcher, Drawing, and sketch-to-shape operations.