brepjs 20.13.4 → 20.13.6
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/2d.cjs +6 -6
- package/dist/2d.js +6 -6
- package/dist/{adjacencyFns-DjblerpV.cjs → adjacencyFns-BLtq-nUN.cjs} +3 -3
- package/dist/{adjacencyFns-Ce4lxSWp.js → adjacencyFns-C1Hxy0tk.js} +3 -3
- package/dist/{blueprint-CeIbNzdp.js → blueprint-BzI6waZa.js} +5 -5
- package/dist/{blueprint-D4YxCDeX.cjs → blueprint-DlpFhHbU.cjs} +5 -5
- package/dist/{blueprintFns-fc9ZUSqe.cjs → blueprintFns-Cc9OyvKE.cjs} +2 -2
- package/dist/{blueprintFns-DEeIBzwN.js → blueprintFns-HFd0lu9A.js} +2 -2
- package/dist/{blueprintSketcher-BQ6ApvaQ.js → blueprintSketcher-BrQee61I.js} +3 -3
- package/dist/{blueprintSketcher-DID7kq5g.cjs → blueprintSketcher-DUT3-Cuo.cjs} +3 -3
- package/dist/{boolean2D-BsrkJbMe.cjs → boolean2D-BC0TwxyB.cjs} +4 -4
- package/dist/{boolean2D-QMPt29HH.js → boolean2D-CvBeghsg.js} +4 -4
- package/dist/{booleanFns-BuxgJmu2.js → booleanFns-Dtg2jqzi.js} +5 -5
- package/dist/{booleanFns-CQIepT9X.cjs → booleanFns-Dti1CK1F.cjs} +5 -5
- package/dist/brepjs.cjs +30 -30
- package/dist/brepjs.js +30 -30
- package/dist/{cameraFns-DL3zo3ol.cjs → cameraFns--Ab792oE.cjs} +3 -3
- package/dist/{cameraFns-s8km1l0J.js → cameraFns-CXONX5Da.js} +3 -3
- package/dist/core/disposal.d.ts +4 -1
- package/dist/core.cjs +2 -2
- package/dist/core.js +2 -2
- package/dist/{cornerFinder-D7P4vdaD.js → cornerFinder-C7f43oKE.js} +1 -1
- package/dist/{cornerFinder-uPZDWiyt.cjs → cornerFinder-DUzrQsfW.cjs} +1 -1
- package/dist/{curveFns-CQtl1RzI.js → curveFns-Dzgl3_MC.js} +1 -1
- package/dist/{curveFns-DkG5mlUj.cjs → curveFns-QaNfJzko.cjs} +1 -1
- package/dist/{drawFns-CSYj0D8x.cjs → drawFns-BRXk9fLg.cjs} +12 -12
- package/dist/{drawFns-BKnz1pa1.js → drawFns-WvF0fehK.js} +12 -12
- package/dist/{faceFns-f8AWRrzK.js → faceFns-BG1CBQUM.js} +2 -2
- package/dist/{faceFns-C_iC_WkC.cjs → faceFns-dj_c8LVc.cjs} +2 -2
- package/dist/{healingFns-W4_K9hXo.cjs → healingFns-BSNNLyXP.cjs} +12 -14
- package/dist/{healingFns-BRXArH8z.js → healingFns-CfkUEqcL.js} +12 -14
- package/dist/{helpers-m-lbbfaz.cjs → helpers-6Emek9dE.cjs} +6 -6
- package/dist/{helpers-COdYBjWD.js → helpers-DolHn2_s.js} +6 -6
- package/dist/{importFns-Kr02P3cy.cjs → importFns-CZb21dj7.cjs} +5 -5
- package/dist/{importFns-D8U3wLhV.js → importFns-D1AxkVC3.js} +5 -5
- package/dist/io.cjs +2 -2
- package/dist/io.js +2 -2
- package/dist/kernel/brepkit/brepkitWasmTypes.d.ts +17 -19
- package/dist/kernel/brepkit/constructionOps.d.ts +1 -1
- package/dist/kernel/brepkit/helpers.d.ts +25 -4
- package/dist/kernel/brepkit/modifierOps.d.ts +3 -3
- package/dist/kernel/occtWasm/occtWasmAdapter.cjs +1 -1
- package/dist/kernel/occtWasm/occtWasmAdapter.js +1 -1
- package/dist/{loftFns-CVk6mzZj.cjs → loftFns-BD0na-M4.cjs} +4 -4
- package/dist/{loftFns-MN9TgyG4.js → loftFns-Cua-MamP.js} +4 -4
- package/dist/{measureFns-9aeYKFiR.cjs → measureFns-FrNeGmXh.cjs} +4 -4
- package/dist/{measureFns-9GzKgCdl.js → measureFns-WGYWWnQ1.js} +4 -4
- package/dist/measurement.cjs +2 -2
- package/dist/measurement.js +2 -2
- package/dist/{meshFns-BwsjspzI.cjs → meshFns-Dy1a9wl_.cjs} +4 -4
- package/dist/{meshFns-un9EDg7X.js → meshFns-Lie8oAac.js} +4 -4
- package/dist/{occtWasmAdapter-4YnvqZOW.cjs → occtWasmAdapter-B9ZXx36v.cjs} +1 -1
- package/dist/{occtWasmAdapter-CGsnjMOe.js → occtWasmAdapter-CGkZIHyM.js} +1 -1
- package/dist/operations/sweepFns.d.ts +3 -3
- package/dist/operations.cjs +2 -2
- package/dist/operations.js +2 -2
- package/dist/{primitiveFns-CIPm9vsq.cjs → primitiveFns-Dpn3ZtUE.cjs} +5 -5
- package/dist/{primitiveFns-BICas2bb.js → primitiveFns-w-ST-RDJ.js} +5 -5
- package/dist/{principalBoxFns-CQZRNYI3.cjs → principalBoxFns-3ZURcOFP.cjs} +3 -3
- package/dist/{principalBoxFns-DQytdykp.js → principalBoxFns-CjfJnZfH.js} +3 -3
- package/dist/projection.cjs +1 -1
- package/dist/projection.js +1 -1
- package/dist/query.cjs +2 -2
- package/dist/query.js +2 -2
- package/dist/{refResolveFns-DNnNqpyn.cjs → refResolveFns-ROMmhWfH.cjs} +6 -6
- package/dist/{refResolveFns-CpPBZkjT.js → refResolveFns-Yy1n2BHJ.js} +6 -6
- package/dist/{shapeFns-D6-l0Nwn.js → shapeFns-BRRrZc1X.js} +2 -2
- package/dist/{shapeFns-Dr_0yhYg.cjs → shapeFns-CljM3iMI.cjs} +2 -2
- package/dist/shapeRef.cjs +1 -1
- package/dist/shapeRef.js +1 -1
- package/dist/{shapeTypes-B23U9msC.cjs → shapeTypes-DEe6gtTR.cjs} +460 -89
- package/dist/{shapeTypes-CSWkqhe9.js → shapeTypes-w2wyXEis.js} +460 -89
- package/dist/sketching.cjs +3 -3
- package/dist/sketching.js +3 -3
- package/dist/{solidBuilders-CQ1oQdBY.js → solidBuilders-BxIYXIv-.js} +3 -3
- package/dist/{solidBuilders-DIlNbnwK.cjs → solidBuilders-yQFZe6jf.cjs} +3 -3
- package/dist/{surfaceBuilders-ZW6W8S1a.js → surfaceBuilders-BZ7BW8I0.js} +3 -3
- package/dist/{surfaceBuilders-BV-QYvCL.cjs → surfaceBuilders-dWcQ_BpM.cjs} +3 -3
- package/dist/text.cjs +2 -2
- package/dist/text.js +2 -2
- package/dist/{textBlueprints-CwsfEEBS.js → textBlueprints-CxhhPEaF.js} +8 -8
- package/dist/{textBlueprints-DYrv0GjE.cjs → textBlueprints-Tx73Xex5.cjs} +8 -8
- package/dist/{textMetrics-gC0qYCN1.cjs → textMetrics-9q5S5II9.cjs} +1 -1
- package/dist/{textMetrics-B_WRck8_.js → textMetrics-B5dKPalE.js} +1 -1
- package/dist/{threadFns-srKixiXB.cjs → threadFns-BnNo5eND.cjs} +7 -7
- package/dist/{threadFns-D9m_ywSR.js → threadFns-Dfu2jV41.js} +7 -7
- package/dist/topology/apiTypes.d.ts +0 -3
- package/dist/topology/modifierFns.d.ts +4 -6
- package/dist/topology.cjs +9 -9
- package/dist/topology.js +9 -9
- package/dist/{topologyQueryFns-D8Du44mm.js → topologyQueryFns-CTl4cWYD.js} +1 -1
- package/dist/{topologyQueryFns-DJJoFJPW.cjs → topologyQueryFns-I_m8o-s7.cjs} +1 -1
- package/dist/{validityTypes-DSzSU07u.js → validityTypes-C2K0Eepw.js} +1 -1
- package/dist/{validityTypes-BkX2hYwP.cjs → validityTypes-DgknRAAp.cjs} +1 -1
- package/package.json +2 -2
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { G as _usingCtx, N as DisposalScope, c as createEdge, l as createFace, p as createWire, q as getKernel } from "./shapeTypes-
|
|
1
|
+
import { G as _usingCtx, N as DisposalScope, c as createEdge, l as createFace, p as createWire, q as getKernel } from "./shapeTypes-w2wyXEis.js";
|
|
2
2
|
import { i as wasmIndex, n as bug } from "./bug-ClMTAJhe.js";
|
|
3
3
|
import { P as unwrap, s as safeIndex } from "./errors-BTccWbtE.js";
|
|
4
|
-
import { s as getEdges } from "./topologyQueryFns-
|
|
4
|
+
import { s as getEdges } from "./topologyQueryFns-CTl4cWYD.js";
|
|
5
5
|
import { t as DEG2RAD } from "./constants-iraOnb2p.js";
|
|
6
6
|
import { r as toVec3 } from "./types-CKXsIm9-.js";
|
|
7
7
|
import { d as vecNormalize, g as vecSub, h as vecScale, m as vecRotate, r as vecCross } from "./vecOps-S-m9H_fe.js";
|
|
8
8
|
import { a as planeToWorld, o as resolvePlane } from "./planeOps-D3yDuMux.js";
|
|
9
|
-
import { d as pointOnSurface, l as normalAt, m as uvBounds, r as faceCenter, u as outerWire, v as copyShape, y as downcast } from "./faceFns-
|
|
10
|
-
import { h as offsetWire2D, i as curveIsClosed, l as curveStartPoint } from "./curveFns-
|
|
9
|
+
import { d as pointOnSurface, l as normalAt, m as uvBounds, r as faceCenter, u as outerWire, v as copyShape, y as downcast } from "./faceFns-BG1CBQUM.js";
|
|
10
|
+
import { h as offsetWire2D, i as curveIsClosed, l as curveStartPoint } from "./curveFns-Dzgl3_MC.js";
|
|
11
11
|
import { n as getAtOrThrow, r as lastOrThrow, t as firstOrThrow } from "./arrayAccess-BpgouNir.js";
|
|
12
|
-
import { c as makeBSplineApproximation, d as makeCircle, f as makeEllipse, m as makeHelix, r as makeFace, s as assembleWire } from "./surfaceBuilders-
|
|
13
|
-
import { a as Blueprints, c as make2dOffset, i as CompoundBlueprint, l as intersectCurves, n as BaseSketcher2d, o as chamferCurves, s as filletCurves, u as Flatbush } from "./blueprintSketcher-
|
|
14
|
-
import { b as squareDistance2d, l as add2d, s as PRECISION_OFFSET, v as samePoint$1, x as subtract2d } from "./helpers-
|
|
15
|
-
import { _ as approximateAsSvgCompatibleCurve, a as edgeToCurve, f as make2dInerpolatedBSplineCurve, i as curvesAsEdgesOnPlane, l as make2dCircle, p as make2dSegmentCurve, s as make2dArcFromCenter, t as Blueprint, u as make2dEllipse, v as Curve2D, x as BoundingBox2d, y as deserializeCurve2D } from "./blueprint-
|
|
16
|
-
import { t as cornerFinder } from "./cornerFinder-
|
|
17
|
-
import { c as roundedRectangleBlueprint, n as fuse2D, r as intersect2D, s as polysidesBlueprint, t as cut2D } from "./boolean2D-
|
|
18
|
-
import { _ as wrapSketchData, a as Sketches, o as Sketch, t as textBlueprints, v as wrapSketchDataArray } from "./textBlueprints-
|
|
19
|
-
import { i as projectEdges, t as cameraFromPlane } from "./cameraFns-
|
|
12
|
+
import { c as makeBSplineApproximation, d as makeCircle, f as makeEllipse, m as makeHelix, r as makeFace, s as assembleWire } from "./surfaceBuilders-BZ7BW8I0.js";
|
|
13
|
+
import { a as Blueprints, c as make2dOffset, i as CompoundBlueprint, l as intersectCurves, n as BaseSketcher2d, o as chamferCurves, s as filletCurves, u as Flatbush } from "./blueprintSketcher-BrQee61I.js";
|
|
14
|
+
import { b as squareDistance2d, l as add2d, s as PRECISION_OFFSET, v as samePoint$1, x as subtract2d } from "./helpers-DolHn2_s.js";
|
|
15
|
+
import { _ as approximateAsSvgCompatibleCurve, a as edgeToCurve, f as make2dInerpolatedBSplineCurve, i as curvesAsEdgesOnPlane, l as make2dCircle, p as make2dSegmentCurve, s as make2dArcFromCenter, t as Blueprint, u as make2dEllipse, v as Curve2D, x as BoundingBox2d, y as deserializeCurve2D } from "./blueprint-BzI6waZa.js";
|
|
16
|
+
import { t as cornerFinder } from "./cornerFinder-C7f43oKE.js";
|
|
17
|
+
import { c as roundedRectangleBlueprint, n as fuse2D, r as intersect2D, s as polysidesBlueprint, t as cut2D } from "./boolean2D-CvBeghsg.js";
|
|
18
|
+
import { _ as wrapSketchData, a as Sketches, o as Sketch, t as textBlueprints, v as wrapSketchDataArray } from "./textBlueprints-CxhhPEaF.js";
|
|
19
|
+
import { i as projectEdges, t as cameraFromPlane } from "./cameraFns-CXONX5Da.js";
|
|
20
20
|
// src/2d/lib/stitching.ts
|
|
21
21
|
/**
|
|
22
22
|
* Group a flat list of curves into connected chains by matching endpoints.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { O as getOrQueryType, i as castShape, q as getKernel } from "./shapeTypes-
|
|
1
|
+
import { O as getOrQueryType, i as castShape, q as getKernel } from "./shapeTypes-w2wyXEis.js";
|
|
2
2
|
import { E as ok, P as unwrap, g as err, l as typeCastError } from "./errors-BTccWbtE.js";
|
|
3
|
-
import { a as getCachedSurfaceType } from "./topologyQueryFns-
|
|
3
|
+
import { a as getCachedSurfaceType } from "./topologyQueryFns-CTl4cWYD.js";
|
|
4
4
|
import { r as toVec3 } from "./types-CKXsIm9-.js";
|
|
5
5
|
// src/topology/cast.ts
|
|
6
6
|
var TOPO_ENUM = {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-DEe6gtTR.cjs");
|
|
2
2
|
const require_errors = require("./errors-O_blYTWT.cjs");
|
|
3
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
3
|
+
const require_topologyQueryFns = require("./topologyQueryFns-I_m8o-s7.cjs");
|
|
4
4
|
const require_types = require("./types-CjF9Rofr.cjs");
|
|
5
5
|
// src/topology/cast.ts
|
|
6
6
|
var TOPO_ENUM = {
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
2
|
-
const require_occtWasmAdapter = require("./occtWasmAdapter-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-DEe6gtTR.cjs");
|
|
2
|
+
const require_occtWasmAdapter = require("./occtWasmAdapter-B9ZXx36v.cjs");
|
|
3
3
|
const require_errors = require("./errors-O_blYTWT.cjs");
|
|
4
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
4
|
+
const require_topologyQueryFns = require("./topologyQueryFns-I_m8o-s7.cjs");
|
|
5
5
|
const require_constants = require("./constants-oee0S_x6.cjs");
|
|
6
|
-
const require_faceFns = require("./faceFns-
|
|
7
|
-
const require_booleanFns = require("./booleanFns-
|
|
8
|
-
const require_shapeFns = require("./shapeFns-
|
|
6
|
+
const require_faceFns = require("./faceFns-dj_c8LVc.cjs");
|
|
7
|
+
const require_booleanFns = require("./booleanFns-Dti1CK1F.cjs");
|
|
8
|
+
const require_shapeFns = require("./shapeFns-CljM3iMI.cjs");
|
|
9
9
|
const require_arrayAccess = require("./arrayAccess-DpJYARwv.cjs");
|
|
10
|
-
const require_adjacencyFns = require("./adjacencyFns-
|
|
10
|
+
const require_adjacencyFns = require("./adjacencyFns-BLtq-nUN.cjs");
|
|
11
11
|
// src/topology/threeHelpers.ts
|
|
12
12
|
/**
|
|
13
13
|
* Convert a ShapeMesh into BufferGeometry-compatible typed arrays.
|
|
@@ -377,8 +377,7 @@ function fillet(shape, edges, radius, { trackEvolution = true } = {}) {
|
|
|
377
377
|
}
|
|
378
378
|
/**
|
|
379
379
|
* `UNSUPPORTED_CAPABILITY` for a fillet the kernel cannot build as asked (a
|
|
380
|
-
*
|
|
381
|
-
* `UnsupportedKernelOperationError`.
|
|
380
|
+
* multi-point variable radius), from its `UnsupportedKernelOperationError`.
|
|
382
381
|
*/
|
|
383
382
|
function filletUnsupportedError(e) {
|
|
384
383
|
const kernelId = require_shapeTypes.getKernel().kernelId;
|
|
@@ -386,7 +385,7 @@ function filletUnsupportedError(e) {
|
|
|
386
385
|
return require_errors.unsupportedError(require_errors.BrepErrorCode.UNSUPPORTED_CAPABILITY, `fillet: the ${kernelId} kernel cannot build this fillet (${raw})`, e, {
|
|
387
386
|
kernel: kernelId,
|
|
388
387
|
operation: "fillet"
|
|
389
|
-
}, "Use
|
|
388
|
+
}, "Use a constant or linear (start, end) radius per edge");
|
|
390
389
|
}
|
|
391
390
|
/**
|
|
392
391
|
* `FILLET_FAILED` / `CHAMFER_FAILED`, with `metadata.failedEdges` set to the
|
|
@@ -596,10 +595,9 @@ function draft(shape, faces, pullDirection, neutralPlane, angle) {
|
|
|
596
595
|
* The radius varies along the edge according to the provided spec points.
|
|
597
596
|
* Each point specifies a normalized parameter (0 = start, 1 = end) and radius.
|
|
598
597
|
*
|
|
599
|
-
* **Cross-kernel note:** occt-wasm
|
|
600
|
-
*
|
|
601
|
-
*
|
|
602
|
-
* kernel does not implement it.
|
|
598
|
+
* **Cross-kernel note:** occt-wasm and brepkit build a constant or linear
|
|
599
|
+
* (start/end, <=2-point) profile and return `UNSUPPORTED_CAPABILITY` for one of
|
|
600
|
+
* more points. The opencascade.js kernel does not implement it.
|
|
603
601
|
*/
|
|
604
602
|
function variableFillet(shape, edge, radii) {
|
|
605
603
|
if (radii.length === 0) return require_errors.err(require_errors.validationError(require_errors.BrepErrorCode.VARIABLE_FILLET_FAILED, "radii must contain at least one radius spec"));
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { C as isSolid, D as getShapeKind, T as isWire, Y as getKernelCapabilities, h as disposeResultShape, i as castShape, m as disposeDowncastSource, n as castResultShape, q as getKernel, r as castResultShapeWithKnownType, x as isShape3D, y as isFace } from "./shapeTypes-
|
|
2
|
-
import { j as isUnsupportedKernelOperationError, n as faultyEdgeIndexesOf } from "./occtWasmAdapter-
|
|
1
|
+
import { C as isSolid, D as getShapeKind, T as isWire, Y as getKernelCapabilities, h as disposeResultShape, i as castShape, m as disposeDowncastSource, n as castResultShape, q as getKernel, r as castResultShapeWithKnownType, x as isShape3D, y as isFace } from "./shapeTypes-w2wyXEis.js";
|
|
2
|
+
import { j as isUnsupportedKernelOperationError, n as faultyEdgeIndexesOf } from "./occtWasmAdapter-CGkZIHyM.js";
|
|
3
3
|
import { E as ok, b as isErr, d as validationError, g as err, i as kernelError, l as typeCastError, t as BrepErrorCode, u as unsupportedError, x as isOk } from "./errors-BTccWbtE.js";
|
|
4
|
-
import { C as subShapeHashes, O as getSuggestionForCode, c as getFaces, i as getCachedIsValid, m as invalidateShapeCache, p as getWires, s as getEdges } from "./topologyQueryFns-
|
|
4
|
+
import { C as subShapeHashes, O as getSuggestionForCode, c as getFaces, i as getCachedIsValid, m as invalidateShapeCache, p as getWires, s as getEdges } from "./topologyQueryFns-CTl4cWYD.js";
|
|
5
5
|
import { n as HASH_CODE_MAX } from "./constants-iraOnb2p.js";
|
|
6
|
-
import { y as downcast } from "./faceFns-
|
|
7
|
-
import { a as fuse, f as collectInputFaceHashes, h as propagateMetadataByHash, i as cutAll, m as propagateAllMetadata, n as copyAsBooleanResult, o as fuseAll, r as cut } from "./booleanFns-
|
|
8
|
-
import { a as isSameShape } from "./shapeFns-
|
|
6
|
+
import { y as downcast } from "./faceFns-BG1CBQUM.js";
|
|
7
|
+
import { a as fuse, f as collectInputFaceHashes, h as propagateMetadataByHash, i as cutAll, m as propagateAllMetadata, n as copyAsBooleanResult, o as fuseAll, r as cut } from "./booleanFns-Dtg2jqzi.js";
|
|
8
|
+
import { a as isSameShape } from "./shapeFns-BRRrZc1X.js";
|
|
9
9
|
import { t as firstOrThrow } from "./arrayAccess-BpgouNir.js";
|
|
10
|
-
import { i as facesOfEdge } from "./adjacencyFns-
|
|
10
|
+
import { i as facesOfEdge } from "./adjacencyFns-C1Hxy0tk.js";
|
|
11
11
|
// src/topology/threeHelpers.ts
|
|
12
12
|
/**
|
|
13
13
|
* Convert a ShapeMesh into BufferGeometry-compatible typed arrays.
|
|
@@ -377,8 +377,7 @@ function fillet(shape, edges, radius, { trackEvolution = true } = {}) {
|
|
|
377
377
|
}
|
|
378
378
|
/**
|
|
379
379
|
* `UNSUPPORTED_CAPABILITY` for a fillet the kernel cannot build as asked (a
|
|
380
|
-
*
|
|
381
|
-
* `UnsupportedKernelOperationError`.
|
|
380
|
+
* multi-point variable radius), from its `UnsupportedKernelOperationError`.
|
|
382
381
|
*/
|
|
383
382
|
function filletUnsupportedError(e) {
|
|
384
383
|
const kernelId = getKernel().kernelId;
|
|
@@ -386,7 +385,7 @@ function filletUnsupportedError(e) {
|
|
|
386
385
|
return unsupportedError(BrepErrorCode.UNSUPPORTED_CAPABILITY, `fillet: the ${kernelId} kernel cannot build this fillet (${raw})`, e, {
|
|
387
386
|
kernel: kernelId,
|
|
388
387
|
operation: "fillet"
|
|
389
|
-
}, "Use
|
|
388
|
+
}, "Use a constant or linear (start, end) radius per edge");
|
|
390
389
|
}
|
|
391
390
|
/**
|
|
392
391
|
* `FILLET_FAILED` / `CHAMFER_FAILED`, with `metadata.failedEdges` set to the
|
|
@@ -596,10 +595,9 @@ function draft(shape, faces, pullDirection, neutralPlane, angle) {
|
|
|
596
595
|
* The radius varies along the edge according to the provided spec points.
|
|
597
596
|
* Each point specifies a normalized parameter (0 = start, 1 = end) and radius.
|
|
598
597
|
*
|
|
599
|
-
* **Cross-kernel note:** occt-wasm
|
|
600
|
-
*
|
|
601
|
-
*
|
|
602
|
-
* kernel does not implement it.
|
|
598
|
+
* **Cross-kernel note:** occt-wasm and brepkit build a constant or linear
|
|
599
|
+
* (start/end, <=2-point) profile and return `UNSUPPORTED_CAPABILITY` for one of
|
|
600
|
+
* more points. The opencascade.js kernel does not implement it.
|
|
603
601
|
*/
|
|
604
602
|
function variableFillet(shape, edge, radii) {
|
|
605
603
|
if (radii.length === 0) return err(validationError(BrepErrorCode.VARIABLE_FILLET_FAILED, "radii must contain at least one radius spec"));
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-DEe6gtTR.cjs");
|
|
2
2
|
const require_errors = require("./errors-O_blYTWT.cjs");
|
|
3
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
3
|
+
const require_topologyQueryFns = require("./topologyQueryFns-I_m8o-s7.cjs");
|
|
4
4
|
const require_constants = require("./constants-oee0S_x6.cjs");
|
|
5
5
|
const require_vecOps = require("./vecOps-CrGEPPQM.cjs");
|
|
6
|
-
const require_faceFns = require("./faceFns-
|
|
7
|
-
const require_shapeFns = require("./shapeFns-
|
|
8
|
-
const require_curveFns = require("./curveFns-
|
|
9
|
-
const require_measureFns = require("./measureFns-
|
|
6
|
+
const require_faceFns = require("./faceFns-dj_c8LVc.cjs");
|
|
7
|
+
const require_shapeFns = require("./shapeFns-CljM3iMI.cjs");
|
|
8
|
+
const require_curveFns = require("./curveFns-QaNfJzko.cjs");
|
|
9
|
+
const require_measureFns = require("./measureFns-FrNeGmXh.cjs");
|
|
10
10
|
// src/utils/vec2d.ts
|
|
11
11
|
/** Precision for curve intersection and parameter operations. */
|
|
12
12
|
var PRECISION_INTERSECTION = 1e-9;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { q as getKernel, y as isFace } from "./shapeTypes-
|
|
1
|
+
import { q as getKernel, y as isFace } from "./shapeTypes-w2wyXEis.js";
|
|
2
2
|
import { E as ok, g as err, o as queryError, x as isOk } from "./errors-BTccWbtE.js";
|
|
3
|
-
import { c as getFaces, f as getVertices, p as getWires, s as getEdges } from "./topologyQueryFns-
|
|
3
|
+
import { c as getFaces, f as getVertices, p as getWires, s as getEdges } from "./topologyQueryFns-CTl4cWYD.js";
|
|
4
4
|
import { t as DEG2RAD } from "./constants-iraOnb2p.js";
|
|
5
5
|
import { a as vecDot, d as vecNormalize } from "./vecOps-S-m9H_fe.js";
|
|
6
|
-
import { l as normalAt, s as getSurfaceType } from "./faceFns-
|
|
7
|
-
import { a as isSameShape, n as getHashCode } from "./shapeFns-
|
|
8
|
-
import { f as getCurveType, i as curveIsClosed, o as curveLength } from "./curveFns-
|
|
9
|
-
import { r as measureArea } from "./measureFns-
|
|
6
|
+
import { l as normalAt, s as getSurfaceType } from "./faceFns-BG1CBQUM.js";
|
|
7
|
+
import { a as isSameShape, n as getHashCode } from "./shapeFns-BRRrZc1X.js";
|
|
8
|
+
import { f as getCurveType, i as curveIsClosed, o as curveLength } from "./curveFns-Dzgl3_MC.js";
|
|
9
|
+
import { r as measureArea } from "./measureFns-WGYWWnQ1.js";
|
|
10
10
|
// src/utils/vec2d.ts
|
|
11
11
|
/** Precision for curve intersection and parameter operations. */
|
|
12
12
|
var PRECISION_INTERSECTION = 1e-9;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-DEe6gtTR.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-
|
|
4
|
+
const require_topologyQueryFns = require("./topologyQueryFns-I_m8o-s7.cjs");
|
|
5
5
|
const require_constants = require("./constants-oee0S_x6.cjs");
|
|
6
|
-
const require_solidBuilders = require("./solidBuilders-
|
|
7
|
-
const require_meshFns = require("./meshFns-
|
|
6
|
+
const require_solidBuilders = require("./solidBuilders-yQFZe6jf.cjs");
|
|
7
|
+
const require_meshFns = require("./meshFns-Dy1a9wl_.cjs");
|
|
8
8
|
const require_arrayAccess = require("./arrayAccess-DpJYARwv.cjs");
|
|
9
|
-
const require_blueprint = require("./blueprint-
|
|
9
|
+
const require_blueprint = require("./blueprint-DlpFhHbU.cjs");
|
|
10
10
|
// src/io/objExportFns.ts
|
|
11
11
|
/** Read a vec3 from a typed array at the given vertex index. */
|
|
12
12
|
function vec3At(arr, i) {
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { C as isSolid, G as _usingCtx, S as isShell, _ as isCompound, n as castResultShape, q as getKernel } from "./shapeTypes-
|
|
1
|
+
import { C as isSolid, G as _usingCtx, S as isShell, _ as isCompound, n as castResultShape, q as getKernel } from "./shapeTypes-w2wyXEis.js";
|
|
2
2
|
import { i as wasmIndex, r as vec3At$1 } from "./bug-ClMTAJhe.js";
|
|
3
3
|
import { E as ok, g as err, r as ioError, t as BrepErrorCode } from "./errors-BTccWbtE.js";
|
|
4
|
-
import { S as subShapeCount, c as getFaces, u as getShells } from "./topologyQueryFns-
|
|
4
|
+
import { S as subShapeCount, c as getFaces, u as getShells } from "./topologyQueryFns-CTl4cWYD.js";
|
|
5
5
|
import { n as HASH_CODE_MAX } from "./constants-iraOnb2p.js";
|
|
6
|
-
import { t as makeCompound } from "./solidBuilders-
|
|
7
|
-
import { u as igesUnsupportedError } from "./meshFns-
|
|
6
|
+
import { t as makeCompound } from "./solidBuilders-BxIYXIv-.js";
|
|
7
|
+
import { u as igesUnsupportedError } from "./meshFns-Lie8oAac.js";
|
|
8
8
|
import { n as getAtOrThrow } from "./arrayAccess-BpgouNir.js";
|
|
9
|
-
import { c as make2dBezierCurve, h as make2dThreePointArc, p as make2dSegmentCurve, t as Blueprint } from "./blueprint-
|
|
9
|
+
import { c as make2dBezierCurve, h as make2dThreePointArc, p as make2dSegmentCurve, t as Blueprint } from "./blueprint-BzI6waZa.js";
|
|
10
10
|
// src/io/objExportFns.ts
|
|
11
11
|
/** Read a vec3 from a typed array at the given vertex index. */
|
|
12
12
|
function vec3At(arr, i) {
|
package/dist/io.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_meshFns = require("./meshFns-
|
|
3
|
-
const require_importFns = require("./importFns-
|
|
2
|
+
const require_meshFns = require("./meshFns-Dy1a9wl_.cjs");
|
|
3
|
+
const require_importFns = require("./importFns-CZb21dj7.cjs");
|
|
4
4
|
exports.blueprintToDXF = require_importFns.blueprintToDXF;
|
|
5
5
|
exports.exportDXF = require_importFns.exportDXF;
|
|
6
6
|
exports.exportGlb = require_importFns.exportGlb;
|
package/dist/io.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { n as exportSTEP, r as exportSTL, t as exportIGES } from "./meshFns-
|
|
2
|
-
import { a as exportSTEPConfigured, c as exportThreeMF, d as exportGlb, f as exportGltf, l as blueprintToDXF, n as importSTEP, o as importSVG, p as exportOBJ, r as importSTL, s as importSVGPathD, t as importIGES, u as exportDXF } from "./importFns-
|
|
1
|
+
import { n as exportSTEP, r as exportSTL, t as exportIGES } from "./meshFns-Lie8oAac.js";
|
|
2
|
+
import { a as exportSTEPConfigured, c as exportThreeMF, d as exportGlb, f as exportGltf, l as blueprintToDXF, n as importSTEP, o as importSVG, p as exportOBJ, r as importSTL, s as importSVGPathD, t as importIGES, u as exportDXF } from "./importFns-D1AxkVC3.js";
|
|
3
3
|
export { blueprintToDXF, exportDXF, exportGlb, exportGltf, exportIGES, exportOBJ, exportSTEP, exportSTEPConfigured, exportSTL, exportThreeMF, importIGES, importSTEP, importSTL, importSVG, importSVGPathD };
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* Type-safe interface for the brepkit WASM kernel (`BrepKernel`).
|
|
3
3
|
*
|
|
4
4
|
* AUTO-GENERATED by `npm run sync:brepkit-types`.
|
|
5
|
-
* Synced against `brepkit-wasm@
|
|
5
|
+
* Synced against `brepkit-wasm@4.6.9`.
|
|
6
6
|
*
|
|
7
7
|
* Methods not yet referenced in the adapter layer are tagged `@unwired`.
|
|
8
8
|
*
|
|
@@ -82,19 +82,12 @@ export interface BrepkitKernel {
|
|
|
82
82
|
addHolesToFace(face: number, holeWireHandles: Uint32Array | number[]): number;
|
|
83
83
|
removeHolesFromFace(face: number): number;
|
|
84
84
|
reverseShape(id: number): number;
|
|
85
|
+
/** @unwired */
|
|
85
86
|
fuse(a: number, b: number): number;
|
|
87
|
+
/** @unwired */
|
|
86
88
|
cut(a: number, b: number): number;
|
|
89
|
+
/** @unwired */
|
|
87
90
|
intersect(a: number, b: number): number;
|
|
88
|
-
/** brepkit-wasm >= 3.2: boolean with post-processing (simplify = unify co-surface fragments). */
|
|
89
|
-
fuseWithOptions?(a: number, b: number, simplify: boolean): number;
|
|
90
|
-
cutWithOptions?(a: number, b: number, simplify: boolean): number;
|
|
91
|
-
intersectWithOptions?(a: number, b: number, simplify: boolean): number;
|
|
92
|
-
/**
|
|
93
|
-
* brepkit-wasm >= 3.2: process-wide count of booleans that used the mesh
|
|
94
|
-
* (co-refinement) fallback. Snapshot around a chain; growth means at least
|
|
95
|
-
* one approximate, possibly non-watertight result.
|
|
96
|
-
*/
|
|
97
|
-
meshFallbackCount?(): number;
|
|
98
91
|
compoundCut(target: number, toolIds: Uint32Array | number[]): number;
|
|
99
92
|
convexHull(coords: Float64Array | number[]): number;
|
|
100
93
|
section(solid: number, px: number, py: number, pz: number, nx: number, ny: number, nz: number): Uint32Array;
|
|
@@ -302,34 +295,39 @@ export interface BrepkitKernel {
|
|
|
302
295
|
/** @unwired */
|
|
303
296
|
convertToElementary(solid: number): number;
|
|
304
297
|
copyFace(face: number): number;
|
|
298
|
+
cutWithOptions(a: number, b: number, simplify: boolean): number;
|
|
305
299
|
/** @unwired */
|
|
306
300
|
deserializeSolid(data: Uint8Array): number;
|
|
307
301
|
/** @unwired */
|
|
308
302
|
detectCoincidentFaces(a: number, b: number): string;
|
|
309
303
|
/** @unwired */
|
|
310
304
|
filletWithEvolution(solid: number, edgeHandles: Uint32Array | number[], radius: number): string;
|
|
311
|
-
/** @unwired */
|
|
312
305
|
fuseAll(solidHandles: Uint32Array | number[]): number;
|
|
306
|
+
fuseWithOptions(a: number, b: number, simplify: boolean): number;
|
|
313
307
|
getNurbsCurveData(edge: number): string;
|
|
308
|
+
getNurbsSurfaceDataParity(face: number): string;
|
|
314
309
|
/** @unwired */
|
|
315
310
|
getNurbsSurfaceData(face: number): string;
|
|
316
|
-
|
|
311
|
+
getSolidPieces(solid: number): Uint32Array;
|
|
317
312
|
getSolidShells(solid: number): Uint32Array;
|
|
318
|
-
/** @unwired */
|
|
319
313
|
guidedSweep(face: number, spineDegree: number, spineKnots: Float64Array | number[], spineControlPoints: Float64Array | number[], spineWeights: Float64Array | number[], auxDegree: number, auxKnots: Float64Array | number[], auxControlPoints: Float64Array | number[], auxWeights: Float64Array | number[]): number;
|
|
320
|
-
|
|
314
|
+
intersectWithOptions(a: number, b: number, simplify: boolean): number;
|
|
321
315
|
/** @unwired */
|
|
322
316
|
makeCircleEdgeWithRef(cx: number, cy: number, cz: number, nx: number, ny: number, nz: number, radius: number, rx: number, ry: number, rz: number): number;
|
|
317
|
+
makeCircleEdge(cx: number, cy: number, cz: number, nx: number, ny: number, nz: number, radius: number): number;
|
|
323
318
|
makeEllipseArc3d(startX: number, startY: number, startZ: number, endX: number, endY: number, endZ: number, centerX: number, centerY: number, centerZ: number, axisX: number, axisY: number, axisZ: number, refX: number, refY: number, refZ: number, semiMajor: number, semiMinor: number): number;
|
|
324
|
-
makeEllipseEdge(cx: number, cy: number, cz: number, nx: number, ny: number, nz: number, semiMajor: number, semiMinor: number): number;
|
|
325
319
|
makeEllipseEdgeWithRef(cx: number, cy: number, cz: number, nx: number, ny: number, nz: number, semiMajor: number, semiMinor: number, rx: number, ry: number, rz: number): number;
|
|
320
|
+
makeEllipseEdge(cx: number, cy: number, cz: number, nx: number, ny: number, nz: number, semiMajor: number, semiMinor: number): number;
|
|
326
321
|
makePlanarFaceFromWire(wire: number): number;
|
|
327
322
|
/** @unwired */
|
|
323
|
+
meshFallbackCount(): number;
|
|
324
|
+
/** @unwired */
|
|
328
325
|
minkowskiSum(solidA: number, solidB: number): number;
|
|
329
326
|
/** @unwired */
|
|
330
327
|
multiSectionSweep(faceHandles: Uint32Array | number[], params: Float64Array | number[], spineDegree: number, spineKnots: Float64Array | number[], spineControlPoints: Float64Array | number[], spineWeights: Float64Array | number[], ruled: boolean): number;
|
|
331
328
|
offsetWire2DWithJoin(wire: number, distance: number, joinType: string): number;
|
|
332
329
|
projectEdges(solid: number, originX: number, originY: number, originZ: number, dirX: number, dirY: number, dirZ: number, xAxisX: number, xAxisY: number, xAxisZ: number, hiddenLines: boolean, deflection: number): string;
|
|
330
|
+
projectSolidsEdges(solids: Uint32Array | number[], originX: number, originY: number, originZ: number, dirX: number, dirY: number, dirZ: number, xAxisX: number, xAxisY: number, xAxisZ: number, hiddenLines: boolean, deflection: number): string;
|
|
333
331
|
/** @unwired */
|
|
334
332
|
serializeSolid(solid: number): Uint8Array;
|
|
335
333
|
/** @unwired */
|
|
@@ -337,11 +335,11 @@ export interface BrepkitKernel {
|
|
|
337
335
|
/** @unwired */
|
|
338
336
|
toBrepJson(solid: number): string;
|
|
339
337
|
transformFace(face: number, matrix: Float64Array | number[]): void;
|
|
340
|
-
/** @future Not in brepkit-wasm
|
|
338
|
+
/** @future Not in brepkit-wasm 4.6.9. Referenced with feature detection in adapter. */
|
|
341
339
|
copyEdge?(edge: number): number;
|
|
342
|
-
/** @future Not in brepkit-wasm
|
|
340
|
+
/** @future Not in brepkit-wasm 4.6.9. Referenced with feature detection in adapter. */
|
|
343
341
|
transformEdge?(edge: number, matrix: Float64Array | number[]): void;
|
|
344
|
-
/** @future Not in brepkit-wasm
|
|
342
|
+
/** @future Not in brepkit-wasm 4.6.9. Referenced with feature detection in adapter. */
|
|
345
343
|
validateSolidDetails?(solid: number): string;
|
|
346
344
|
/** Release the entire arena. */
|
|
347
345
|
free(): void;
|
|
@@ -25,7 +25,7 @@ export declare function makeEllipseEdge(bk: BrepkitKernel, center: [number, numb
|
|
|
25
25
|
export declare function makeEllipseArc(bk: BrepkitKernel, center: [number, number, number], normal: [number, number, number], majorRadius: number, minorRadius: number, startAngle: number, endAngle: number, xDir?: [number, number, number]): KernelShape;
|
|
26
26
|
export declare function makeBezierEdge(bk: BrepkitKernel, points: [number, number, number][]): KernelShape;
|
|
27
27
|
export declare function makeTangentArc(bk: BrepkitKernel, startPoint: [number, number, number], startTangent: [number, number, number], endPoint: [number, number, number]): KernelShape;
|
|
28
|
-
export declare function makeHelixWire(bk: BrepkitKernel, pitch: number, height: number, radius: number, center?: [number, number, number],
|
|
28
|
+
export declare function makeHelixWire(bk: BrepkitKernel, pitch: number, height: number, radius: number, center?: [number, number, number], direction?: [number, number, number], leftHanded?: boolean): KernelShape;
|
|
29
29
|
export declare function makeWireFromMixed(bk: BrepkitKernel, items: KernelShape[]): KernelShape;
|
|
30
30
|
export declare function makeCompound(bk: BrepkitKernel, shapes: KernelShape[]): KernelShape;
|
|
31
31
|
export declare function makeBoxFromCorners(bk: BrepkitKernel, p1: [number, number, number], p2: [number, number, number]): KernelShape;
|
|
@@ -54,11 +54,25 @@ export declare function unwrapSolidsForExport(bk: BrepkitKernel, shape: KernelSh
|
|
|
54
54
|
/** Euclidean distance between two 3D points. */
|
|
55
55
|
export declare function dist3(x1: number, y1: number, z1: number, x2: number, y2: number, z2: number): number;
|
|
56
56
|
type Point = [number, number, number];
|
|
57
|
+
interface ConicFrame {
|
|
58
|
+
readonly center: Point;
|
|
59
|
+
readonly u: Point;
|
|
60
|
+
readonly v: Point;
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* The frame of an analytic circle or ellipse edge, evaluated at t as
|
|
64
|
+
* center + U·cos t + V·sin t, recovered from its points at 0, π/2 and π.
|
|
65
|
+
* A NURBS edge that happens to be a circle reports CIRCLE too but runs over
|
|
66
|
+
* its knots, so it gets no frame; only an analytic edge has no NURBS data.
|
|
67
|
+
*/
|
|
68
|
+
export declare function conicFrame(bk: BrepkitKernel, edgeId: number): ConicFrame | undefined;
|
|
69
|
+
export declare function edgeEnds(bk: BrepkitKernel, edgeId: number): [Point, Point];
|
|
57
70
|
/**
|
|
58
|
-
* The curve parameters an edge spans. brepkit reports a circle or
|
|
59
|
-
* domain as the whole [0, 2π] even for an arc
|
|
60
|
-
*
|
|
61
|
-
*
|
|
71
|
+
* The curve parameters an edge spans. brepkit before 4.5.10 reports a circle or
|
|
72
|
+
* ellipse edge's domain as the whole [0, 2π] even for an arc, so an arc's span
|
|
73
|
+
* is read off the curve's frame on every kernel: it runs counterclockwise about
|
|
74
|
+
* the curve's axis from the angle of its start vertex to that of its end vertex
|
|
75
|
+
* (brepkit's own `circle_param_range`).
|
|
62
76
|
*/
|
|
63
77
|
export declare function edgeParamRange(bk: BrepkitKernel, edgeId: number): [number, number];
|
|
64
78
|
/**
|
|
@@ -89,6 +103,13 @@ export declare const DEFAULT_SEGMENTS = 32;
|
|
|
89
103
|
export declare function nextSyntheticId(): number;
|
|
90
104
|
/** JS-side storage for compound children (wires, faces, edges). */
|
|
91
105
|
export declare const syntheticCompounds: Map<number, BrepkitHandle[]>;
|
|
106
|
+
/** A solid's piece ids, from `split` the first time they are asked for. */
|
|
107
|
+
export declare function cachedSolidPieces(bk: BrepkitKernel, solidId: number, split: () => readonly number[]): readonly number[];
|
|
108
|
+
/**
|
|
109
|
+
* Forget one solid's pieces after the kernel changes it in place, or every
|
|
110
|
+
* solid's after the arena rolls back and its ids can name new entities.
|
|
111
|
+
*/
|
|
112
|
+
export declare function forgetSolidPieces(bk: BrepkitKernel, solidId?: number): void;
|
|
92
113
|
/** Emit a console.warn once per key per session. */
|
|
93
114
|
export declare function warnOnce(key: string, message: string): void;
|
|
94
115
|
/** Check if a BooleanOptions object sets an option brepkit still ignores. */
|
|
@@ -3,9 +3,9 @@ import { KernelShape } from '../types.js';
|
|
|
3
3
|
export declare function fillet(bk: BrepkitKernel, shape: KernelShape, edges: KernelShape[], radius: number | [number, number] | ((edge: KernelShape) => number | [number, number])): KernelShape;
|
|
4
4
|
/**
|
|
5
5
|
* A variable fillet spec on one edge: `{ edge: hashCode, radii: [{ param, radius }] }`
|
|
6
|
-
* from variableFillet, or `{ edgeId, startRadius, endRadius }`.
|
|
7
|
-
*
|
|
8
|
-
*
|
|
6
|
+
* from variableFillet, or `{ edgeId, startRadius, endRadius }`. Like occt-wasm, a
|
|
7
|
+
* profile runs linearly from its first radius to its last, so one of more than two
|
|
8
|
+
* points is unsupported rather than flattened to a line.
|
|
9
9
|
*/
|
|
10
10
|
export declare function filletVariable(bk: BrepkitKernel, shape: KernelShape, spec: string): KernelShape;
|
|
11
11
|
export declare function chamfer(bk: BrepkitKernel, shape: KernelShape, edges: KernelShape[], distance: number | [number, number] | ((edge: KernelShape) => number | [number, number])): KernelShape;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_occtWasmAdapter = require("../../occtWasmAdapter-
|
|
2
|
+
const require_occtWasmAdapter = require("../../occtWasmAdapter-B9ZXx36v.cjs");
|
|
3
3
|
exports.OcctWasmAdapter = require_occtWasmAdapter.OcctWasmAdapter;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { t as OcctWasmAdapter } from "../../occtWasmAdapter-
|
|
1
|
+
export { t as OcctWasmAdapter } from "../../occtWasmAdapter-CGkZIHyM.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
2
|
-
const require_occtWasmAdapter = require("./occtWasmAdapter-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-DEe6gtTR.cjs");
|
|
2
|
+
const require_occtWasmAdapter = require("./occtWasmAdapter-B9ZXx36v.cjs");
|
|
3
3
|
const require_errors = require("./errors-O_blYTWT.cjs");
|
|
4
4
|
const require_types = require("./types-CjF9Rofr.cjs");
|
|
5
5
|
const require_vecOps = require("./vecOps-CrGEPPQM.cjs");
|
|
@@ -82,13 +82,13 @@ function castSweepShellTuple(result) {
|
|
|
82
82
|
endWire
|
|
83
83
|
]);
|
|
84
84
|
}
|
|
85
|
-
/** `UNSUPPORTED_CAPABILITY` for a sweep option the kernel cannot build (a
|
|
85
|
+
/** `UNSUPPORTED_CAPABILITY` for a sweep option the kernel cannot build (a scaling law on brepkit). */
|
|
86
86
|
function sweepUnsupportedError(kernelId, e) {
|
|
87
87
|
const raw = e instanceof Error ? e.message : String(e);
|
|
88
88
|
return require_errors.unsupportedError(require_errors.BrepErrorCode.UNSUPPORTED_CAPABILITY, `sweep: the ${kernelId} kernel cannot build this sweep (${raw})`, e, {
|
|
89
89
|
kernel: kernelId,
|
|
90
90
|
operation: "sweep"
|
|
91
|
-
}, "Drop the
|
|
91
|
+
}, "Drop the scaling law, or use the occt-wasm kernel");
|
|
92
92
|
}
|
|
93
93
|
function sweep(wire, spine, config = {}, shellMode = false) {
|
|
94
94
|
if (config.mode === "simple" && !shellMode) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { G as _usingCtx, T as isWire, h as disposeResultShape, n as castResultShape, q as getKernel, x as isShape3D } from "./shapeTypes-
|
|
2
|
-
import { j as isUnsupportedKernelOperationError } from "./occtWasmAdapter-
|
|
1
|
+
import { G as _usingCtx, T as isWire, h as disposeResultShape, n as castResultShape, q as getKernel, x as isShape3D } from "./shapeTypes-w2wyXEis.js";
|
|
2
|
+
import { j as isUnsupportedKernelOperationError } from "./occtWasmAdapter-CGkZIHyM.js";
|
|
3
3
|
import { E as ok, b as isErr, d as validationError, g as err, i as kernelError, l as typeCastError, t as BrepErrorCode, u as unsupportedError } from "./errors-BTccWbtE.js";
|
|
4
4
|
import { r as toVec3 } from "./types-CKXsIm9-.js";
|
|
5
5
|
import { c as vecLength, t as vecAdd } from "./vecOps-S-m9H_fe.js";
|
|
@@ -82,13 +82,13 @@ function castSweepShellTuple(result) {
|
|
|
82
82
|
endWire
|
|
83
83
|
]);
|
|
84
84
|
}
|
|
85
|
-
/** `UNSUPPORTED_CAPABILITY` for a sweep option the kernel cannot build (a
|
|
85
|
+
/** `UNSUPPORTED_CAPABILITY` for a sweep option the kernel cannot build (a scaling law on brepkit). */
|
|
86
86
|
function sweepUnsupportedError(kernelId, e) {
|
|
87
87
|
const raw = e instanceof Error ? e.message : String(e);
|
|
88
88
|
return unsupportedError(BrepErrorCode.UNSUPPORTED_CAPABILITY, `sweep: the ${kernelId} kernel cannot build this sweep (${raw})`, e, {
|
|
89
89
|
kernel: kernelId,
|
|
90
90
|
operation: "sweep"
|
|
91
|
-
}, "Drop the
|
|
91
|
+
}, "Drop the scaling law, or use the occt-wasm kernel");
|
|
92
92
|
}
|
|
93
93
|
function sweep(wire, spine, config = {}, shellMode = false) {
|
|
94
94
|
if (config.mode === "simple" && !shellMode) {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
2
|
-
const require_occtWasmAdapter = require("./occtWasmAdapter-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-DEe6gtTR.cjs");
|
|
2
|
+
const require_occtWasmAdapter = require("./occtWasmAdapter-B9ZXx36v.cjs");
|
|
3
3
|
const require_errors = require("./errors-O_blYTWT.cjs");
|
|
4
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
5
|
-
const require_faceFns = require("./faceFns-
|
|
4
|
+
const require_topologyQueryFns = require("./topologyQueryFns-I_m8o-s7.cjs");
|
|
5
|
+
const require_faceFns = require("./faceFns-dj_c8LVc.cjs");
|
|
6
6
|
// src/measurement/measureCache.ts
|
|
7
7
|
var cache = /* @__PURE__ */ new WeakMap();
|
|
8
8
|
function getCachedMeasurement(shape, key) {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { q as getKernel } from "./shapeTypes-
|
|
2
|
-
import { j as isUnsupportedKernelOperationError } from "./occtWasmAdapter-
|
|
1
|
+
import { q as getKernel } from "./shapeTypes-w2wyXEis.js";
|
|
2
|
+
import { j as isUnsupportedKernelOperationError } from "./occtWasmAdapter-CGkZIHyM.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-
|
|
5
|
-
import { m as uvBounds } from "./faceFns-
|
|
4
|
+
import { E as kernelCallRaw } from "./topologyQueryFns-CTl4cWYD.js";
|
|
5
|
+
import { m as uvBounds } from "./faceFns-BG1CBQUM.js";
|
|
6
6
|
// src/measurement/measureCache.ts
|
|
7
7
|
var cache = /* @__PURE__ */ new WeakMap();
|
|
8
8
|
function getCachedMeasurement(shape, key) {
|
package/dist/measurement.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_measureFns = require("./measureFns-
|
|
3
|
-
const require_principalBoxFns = require("./principalBoxFns-
|
|
2
|
+
const require_measureFns = require("./measureFns-FrNeGmXh.cjs");
|
|
3
|
+
const require_principalBoxFns = require("./principalBoxFns-3ZURcOFP.cjs");
|
|
4
4
|
exports.createDistanceQuery = require_measureFns.createDistanceQuery;
|
|
5
5
|
exports.measureArea = require_measureFns.measureArea;
|
|
6
6
|
exports.measureDistance = require_measureFns.measureDistance;
|
package/dist/measurement.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
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-
|
|
2
|
-
import { t as principalBoundingBox } from "./principalBoxFns-
|
|
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-WGYWWnQ1.js";
|
|
2
|
+
import { t as principalBoundingBox } from "./principalBoxFns-CjfJnZfH.js";
|
|
3
3
|
export { createDistanceQuery, measureArea, measureDistance, measureDistanceProps, measureLength, measureLinearProps, measureSurfaceProps, measureVolume, measureVolumeProps, principalBoundingBox };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
2
|
-
const require_occtWasmAdapter = require("./occtWasmAdapter-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-DEe6gtTR.cjs");
|
|
2
|
+
const require_occtWasmAdapter = require("./occtWasmAdapter-B9ZXx36v.cjs");
|
|
3
3
|
const require_errors = require("./errors-O_blYTWT.cjs");
|
|
4
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
5
|
-
const require_solidBuilders = require("./solidBuilders-
|
|
4
|
+
const require_topologyQueryFns = require("./topologyQueryFns-I_m8o-s7.cjs");
|
|
5
|
+
const require_solidBuilders = require("./solidBuilders-yQFZe6jf.cjs");
|
|
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
|
-
import { q as getKernel, ut as qualityDeflection } from "./shapeTypes-
|
|
2
|
-
import { j as isUnsupportedKernelOperationError } from "./occtWasmAdapter-
|
|
1
|
+
import { q as getKernel, ut as qualityDeflection } from "./shapeTypes-w2wyXEis.js";
|
|
2
|
+
import { j as isUnsupportedKernelOperationError } from "./occtWasmAdapter-CGkZIHyM.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-
|
|
5
|
-
import { d as getFaceOrigins } from "./solidBuilders-
|
|
4
|
+
import { d as getSolids, n as getBounds } from "./topologyQueryFns-CTl4cWYD.js";
|
|
5
|
+
import { d as getFaceOrigins } from "./solidBuilders-BxIYXIv-.js";
|
|
6
6
|
// src/topology/meshCache.ts
|
|
7
7
|
/**
|
|
8
8
|
* Build a parameter key for the inner cache map (excludes shape identity).
|
|
@@ -3920,7 +3920,7 @@ function filletVariable(k, shape, spec) {
|
|
|
3920
3920
|
if (parsed.edgeId !== void 0 && parsed.startRadius !== void 0 && parsed.endRadius !== void 0) return runFilletVariable(k, unwrap(shape), parsed.edgeId, parsed.startRadius, parsed.endRadius);
|
|
3921
3921
|
if (parsed.edge !== void 0 && Array.isArray(parsed.radii) && parsed.radii.length > 0) {
|
|
3922
3922
|
const radii = parsed.radii;
|
|
3923
|
-
if (radii.length > 2) throw new UnsupportedKernelOperationError("occt-wasm: filletVariable supports only a linear (<=2-point) radius profile
|
|
3923
|
+
if (radii.length > 2) throw new UnsupportedKernelOperationError("occt-wasm: filletVariable supports only a linear (<=2-point) radius profile");
|
|
3924
3924
|
const startRadius = radii[0].radius;
|
|
3925
3925
|
const endRadius = radii[radii.length - 1].radius;
|
|
3926
3926
|
const shapeId = unwrap(shape);
|
|
@@ -3920,7 +3920,7 @@ function filletVariable(k, shape, spec) {
|
|
|
3920
3920
|
if (parsed.edgeId !== void 0 && parsed.startRadius !== void 0 && parsed.endRadius !== void 0) return runFilletVariable(k, unwrap(shape), parsed.edgeId, parsed.startRadius, parsed.endRadius);
|
|
3921
3921
|
if (parsed.edge !== void 0 && Array.isArray(parsed.radii) && parsed.radii.length > 0) {
|
|
3922
3922
|
const radii = parsed.radii;
|
|
3923
|
-
if (radii.length > 2) throw new UnsupportedKernelOperationError("occt-wasm: filletVariable supports only a linear (<=2-point) radius profile
|
|
3923
|
+
if (radii.length > 2) throw new UnsupportedKernelOperationError("occt-wasm: filletVariable supports only a linear (<=2-point) radius profile");
|
|
3924
3924
|
const startRadius = radii[0].radius;
|
|
3925
3925
|
const endRadius = radii[radii.length - 1].radius;
|
|
3926
3926
|
const shapeId = unwrap(shape);
|