brepjs 20.9.0 → 20.10.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.
- package/dist/2d.cjs +6 -6
- package/dist/2d.js +6 -6
- package/dist/{adjacencyFns-qDDFKib0.cjs → adjacencyFns-CS62XPcQ.cjs} +3 -3
- package/dist/{adjacencyFns-CRd3d1xM.js → adjacencyFns-DG9R99LR.js} +3 -3
- package/dist/{blueprint-Dr-l3Nlb.js → blueprint-B8tYa1RE.js} +5 -5
- package/dist/{blueprint-CgWpKzKK.cjs → blueprint-YK9OBMxh.cjs} +5 -5
- package/dist/{blueprintFns-DU8jUsTf.js → blueprintFns-C0x5vPm-.js} +2 -2
- package/dist/{blueprintFns-lhshdjAb.cjs → blueprintFns-DDiWI0Ol.cjs} +2 -2
- package/dist/{blueprintSketcher-ZRJzo1tb.cjs → blueprintSketcher-7v6ufdam.cjs} +3 -3
- package/dist/{blueprintSketcher-P4oIgADL.js → blueprintSketcher-DcyidOGa.js} +3 -3
- package/dist/{boolean2D-h4By3wwW.cjs → boolean2D-B21GheGE.cjs} +4 -4
- package/dist/{boolean2D-iTKFBIvC.js → boolean2D-DYAua9O_.js} +4 -4
- package/dist/brepjs.cjs +49 -91
- package/dist/brepjs.js +49 -91
- package/dist/{cameraFns-Dgx3MCGf.js → cameraFns-CAjuoPKb.js} +3 -3
- package/dist/{cameraFns-CNWY4B7i.cjs → cameraFns-HpsMe1iL.cjs} +3 -3
- package/dist/core.cjs +2 -2
- package/dist/core.js +2 -2
- package/dist/{cornerFinder-BqGipV9i.js → cornerFinder-DHg0ej_Q.js} +1 -1
- package/dist/{cornerFinder-DZORgosi.cjs → cornerFinder-DVHtBOzM.cjs} +1 -1
- package/dist/{curveFns-DqgDK9xJ.js → curveFns-BdmSrGqT.js} +1 -1
- package/dist/{curveFns-C01yujmY.cjs → curveFns-DUSOe8uJ.cjs} +1 -1
- package/dist/{drawFns-mtCQj7Qu.cjs → drawFns-Cy7P1Q-L.cjs} +12 -12
- package/dist/{drawFns-BbDx57EX.js → drawFns-X0cS9iAp.js} +12 -12
- package/dist/{faceFns-BNGMbh3P.js → faceFns-DKEm5U-p.js} +2 -2
- package/dist/{faceFns-BlYowjvU.cjs → faceFns-vVGf6osa.cjs} +2 -2
- package/dist/{healingFns-DXYEpHAx.cjs → healingFns-CW0olP8u.cjs} +21 -12
- package/dist/{healingFns-xPtXVShE.js → healingFns-C_3Zf9sr.js} +21 -12
- package/dist/{helpers-Ngw1OFee.cjs → helpers-BIpWypkW.cjs} +6 -6
- package/dist/{helpers-vd5KEdfZ.js → helpers-CcZp3tLI.js} +6 -6
- package/dist/{importFns-BwEwuqM2.cjs → importFns-DI3Q8B0Q.cjs} +2 -2
- package/dist/{importFns-DQW8EVaa.js → importFns-D_tBVKl2.js} +2 -2
- package/dist/io.cjs +2 -2
- package/dist/io.js +2 -2
- package/dist/kernel/faultyEdges.d.ts +11 -0
- package/dist/kernel/occtWasm/constructionOps.d.ts +4 -2
- package/dist/kernel/occtWasm/helpers.d.ts +5 -0
- package/dist/kernel/occtWasm/occtWasmAdapter.cjs +1 -1
- package/dist/kernel/occtWasm/occtWasmAdapter.d.ts +2 -2
- package/dist/kernel/occtWasm/occtWasmAdapter.js +1 -1
- package/dist/kernel/occtWasm/occtWasmTypes.d.ts +2 -0
- package/dist/kernel/optionalBackend.d.ts +3 -1
- package/dist/{loftFns-Cth0_MXM.js → loftFns-DIsFP0VL.js} +1 -1
- package/dist/{loftFns-DlBiqyB-.cjs → loftFns-tGsV_hHY.cjs} +1 -1
- package/dist/{measureFns-BnbD7-w7.cjs → measureFns-BoNCUOKe.cjs} +3 -3
- package/dist/{measureFns-B_DpfIE3.js → measureFns-eCuwj0im.js} +3 -3
- package/dist/measurement.cjs +2 -2
- package/dist/measurement.js +2 -2
- package/dist/{meshFns-DlGc_nS6.cjs → meshFns-0W1-80zv.cjs} +3 -3
- package/dist/{meshFns-B4L-5mVr.js → meshFns-B9jPfcB2.js} +3 -3
- package/dist/{occtWasmAdapter-Bi9GozJ9.js → occtWasmAdapter-ClvPe3OJ.js} +115 -13
- package/dist/{occtWasmAdapter-Dd9giakk.cjs → occtWasmAdapter-CsDULjij.cjs} +120 -12
- package/dist/operations.cjs +2 -2
- package/dist/operations.js +2 -2
- package/dist/{originTrackingFns-BQIWwnFh.js → originTrackingFns-BW2BaJW8.js} +2 -2
- package/dist/{originTrackingFns-DDOCQdaW.cjs → originTrackingFns-cEKFxtia.cjs} +2 -2
- package/dist/{primitiveFns-B8ab8U8_.cjs → primitiveFns-BJ-ehvvd.cjs} +4 -4
- package/dist/{primitiveFns-ChWAGjel.js → primitiveFns-BOZ7Kx0M.js} +4 -4
- package/dist/{principalBoxFns-DXNRJ_A-.cjs → principalBoxFns-B1j2sNAc.cjs} +3 -3
- package/dist/{principalBoxFns-CvAYgpY4.js → principalBoxFns-B6PZwxDM.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/quick.js +3 -2
- package/dist/{refResolveFns-Bc5nUmmk.js → refResolveFns-BxvibZPu.js} +6 -6
- package/dist/{refResolveFns-C6CYnUNd.cjs → refResolveFns-DvDeMCVU.cjs} +6 -6
- package/dist/{shapeFns-Cn0lAxbU.cjs → shapeFns-CJrIL2CG.cjs} +2 -2
- package/dist/{shapeFns-DLD8qAsI.js → shapeFns-De7CbEeQ.js} +2 -2
- package/dist/shapeRef.cjs +1 -1
- package/dist/shapeRef.js +1 -1
- package/dist/{shapeTypes-D0j6Lk3z.js → shapeTypes-BCy8JI0O.js} +5 -2
- package/dist/{shapeTypes-K0rZK5U-.cjs → shapeTypes-CNQn1x5H.cjs} +5 -2
- package/dist/sketching.cjs +3 -3
- package/dist/sketching.js +3 -3
- package/dist/{solidBuilders-DfXGia5F.cjs → solidBuilders-BN1p303l.cjs} +5 -5
- package/dist/{solidBuilders-94pT7hv6.js → solidBuilders-YbLOfWIp.js} +5 -5
- package/dist/{surfaceBuilders-DnZj4fvS.cjs → surfaceBuilders-C5lz2TNF.cjs} +3 -3
- package/dist/{surfaceBuilders-DGEXvSTe.js → surfaceBuilders-CaN-lye8.js} +3 -3
- package/dist/text.cjs +2 -2
- package/dist/text.js +2 -2
- package/dist/{textBlueprints-D4Yez18p.js → textBlueprints-BlfIkOUx.js} +7 -7
- package/dist/{textBlueprints-BUV_vedl.cjs → textBlueprints-jlqCGG4p.cjs} +7 -7
- package/dist/{textMetrics-BwFqDdvR.cjs → textMetrics-B2KxCoHk.cjs} +1 -1
- package/dist/{textMetrics-C1iq-fwi.js → textMetrics-BjhB4Zur.js} +1 -1
- package/dist/{threadFns-DS6WgBI2.cjs → threadFns-DO9SkBPb.cjs} +7 -7
- package/dist/{threadFns-DHL3t8zV.js → threadFns-DWMumhmK.js} +7 -7
- package/dist/topology.cjs +9 -9
- package/dist/topology.js +9 -9
- package/dist/{topologyQueryFns-BPJZTpIz.cjs → topologyQueryFns-BwhwOtxv.cjs} +1 -1
- package/dist/{topologyQueryFns-DtzwRKVP.js → topologyQueryFns-Clkdolgd.js} +1 -1
- package/dist/{validityTypes-DfqnKBzz.cjs → validityTypes-B_6gRPPO.cjs} +1 -1
- package/dist/{validityTypes-CqFq8m-i.js → validityTypes-txYFYYN6.js} +1 -1
- package/package.json +2 -2
package/dist/core.cjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
2
|
+
const require_shapeTypes = require("./shapeTypes-CNQn1x5H.cjs");
|
|
3
3
|
const require_bug = require("./bug-CBcpIPuf.cjs");
|
|
4
4
|
const require_errors = require("./errors-B9r_Dzs1.cjs");
|
|
5
|
-
const require_validityTypes = require("./validityTypes-
|
|
5
|
+
const require_validityTypes = require("./validityTypes-B_6gRPPO.cjs");
|
|
6
6
|
const require_constants = require("./constants-oee0S_x6.cjs");
|
|
7
7
|
const require_types = require("./types-CjF9Rofr.cjs");
|
|
8
8
|
const require_vecOps = require("./vecOps-CrGEPPQM.cjs");
|
package/dist/core.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { C as isSolid, D as getShapeKind, E as GeometryCleanupError, F as createKernelHandle, H as withScope, L as isLive, M as is3D, N as DisposalScope, P as createHandle, S as isShell, T as isWire, U as withScopeResult, W as withScopeResultAsync, _ as isCompound, b as isShape1D, i as castShape, j as is2D, v as isEdge, w as isVertex, x as isShape3D, y as isFace } from "./shapeTypes-
|
|
1
|
+
import { C as isSolid, D as getShapeKind, E as GeometryCleanupError, F as createKernelHandle, H as withScope, L as isLive, M as is3D, N as DisposalScope, P as createHandle, S as isShell, T as isWire, U as withScopeResult, W as withScopeResultAsync, _ as isCompound, b as isShape1D, i as castShape, j as is2D, v as isEdge, w as isVertex, x as isShape3D, y as isFace } from "./shapeTypes-BCy8JI0O.js";
|
|
2
2
|
import { n as bug, t as BrepBugError } from "./bug-ClMTAJhe.js";
|
|
3
3
|
import { E as ok, F as unwrapErr, I as unwrapOr, L as unwrapOrElse, M as tryCatch, N as tryCatchAsync, P as unwrap, S as map, T as match, _ as flatMap, a as moduleInitError, b as isErr, c as sketcherStateError, d as validationError, f as OK, g as err, h as collect, i as kernelError, l as typeCastError, m as andThen, n as computationError, o as queryError, r as ioError, u as unsupportedError, w as mapErr, x as isOk } from "./errors-CUsZRWJ7.js";
|
|
4
|
-
import { c as manifoldShell, f as validSolid, i as isOrientedFace, l as orientedFace, n as isClosedWire, r as isManifoldShell, s as isValidSolid, t as closedWire } from "./validityTypes-
|
|
4
|
+
import { c as manifoldShell, f as validSolid, i as isOrientedFace, l as orientedFace, n as isClosedWire, r as isManifoldShell, s as isValidSolid, t as closedWire } from "./validityTypes-txYFYYN6.js";
|
|
5
5
|
import { n as HASH_CODE_MAX, r as RAD2DEG, t as DEG2RAD } from "./constants-iraOnb2p.js";
|
|
6
6
|
import { n as toVec2, r as toVec3, t as resolveDirection } from "./types-CKXsIm9-.js";
|
|
7
7
|
import { a as vecDot, c as vecLength, d as vecNormalize, f as vecProjectToPlane, g as vecSub, h as vecScale, i as vecDistance, l as vecLengthSq, m as vecRotate, n as vecAngle, o as vecEquals, p as vecRepr, r as vecCross, s as vecIsZero, t as vecAdd, u as vecNegate } from "./vecOps-S-m9H_fe.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { t as DEG2RAD } from "./constants-iraOnb2p.js";
|
|
2
2
|
import { n as getAtOrThrow } from "./arrayAccess-BpgouNir.js";
|
|
3
|
-
import { p as distance2d, u as angle2d, v as samePoint } from "./helpers-
|
|
3
|
+
import { p as distance2d, u as angle2d, v as samePoint } from "./helpers-CcZp3tLI.js";
|
|
4
4
|
// src/query/cornerFinder.ts
|
|
5
5
|
var PI_2 = 2 * Math.PI;
|
|
6
6
|
function positiveHalfAngle(angle) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
const require_constants = require("./constants-oee0S_x6.cjs");
|
|
2
2
|
const require_arrayAccess = require("./arrayAccess-DpJYARwv.cjs");
|
|
3
|
-
const require_helpers = require("./helpers-
|
|
3
|
+
const require_helpers = require("./helpers-BIpWypkW.cjs");
|
|
4
4
|
// src/query/cornerFinder.ts
|
|
5
5
|
var PI_2 = 2 * Math.PI;
|
|
6
6
|
function positiveHalfAngle(angle) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { T as isWire, h as disposeResultShape, n as castResultShape, q as getKernel, v as isEdge } from "./shapeTypes-
|
|
1
|
+
import { T as isWire, h as disposeResultShape, n as castResultShape, q as getKernel, v as isEdge } from "./shapeTypes-BCy8JI0O.js";
|
|
2
2
|
import { E as ok, g as err, l as typeCastError } from "./errors-CUsZRWJ7.js";
|
|
3
3
|
// src/topology/curveFns.ts
|
|
4
4
|
/**
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-CNQn1x5H.cjs");
|
|
2
2
|
const require_bug = require("./bug-CBcpIPuf.cjs");
|
|
3
3
|
const require_errors = require("./errors-B9r_Dzs1.cjs");
|
|
4
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
4
|
+
const require_topologyQueryFns = require("./topologyQueryFns-BwhwOtxv.cjs");
|
|
5
5
|
const require_constants = require("./constants-oee0S_x6.cjs");
|
|
6
6
|
const require_types = require("./types-CjF9Rofr.cjs");
|
|
7
7
|
const require_vecOps = require("./vecOps-CrGEPPQM.cjs");
|
|
8
8
|
const require_planeOps = require("./planeOps-C7sRqzno.cjs");
|
|
9
|
-
const require_faceFns = require("./faceFns-
|
|
10
|
-
const require_curveFns = require("./curveFns-
|
|
9
|
+
const require_faceFns = require("./faceFns-vVGf6osa.cjs");
|
|
10
|
+
const require_curveFns = require("./curveFns-DUSOe8uJ.cjs");
|
|
11
11
|
const require_arrayAccess = require("./arrayAccess-DpJYARwv.cjs");
|
|
12
|
-
const require_surfaceBuilders = require("./surfaceBuilders-
|
|
13
|
-
const require_blueprintSketcher = require("./blueprintSketcher-
|
|
14
|
-
const require_helpers = require("./helpers-
|
|
15
|
-
const require_blueprint = require("./blueprint-
|
|
16
|
-
const require_cornerFinder = require("./cornerFinder-
|
|
17
|
-
const require_boolean2D = require("./boolean2D-
|
|
18
|
-
const require_textBlueprints = require("./textBlueprints-
|
|
19
|
-
const require_cameraFns = require("./cameraFns-
|
|
12
|
+
const require_surfaceBuilders = require("./surfaceBuilders-C5lz2TNF.cjs");
|
|
13
|
+
const require_blueprintSketcher = require("./blueprintSketcher-7v6ufdam.cjs");
|
|
14
|
+
const require_helpers = require("./helpers-BIpWypkW.cjs");
|
|
15
|
+
const require_blueprint = require("./blueprint-YK9OBMxh.cjs");
|
|
16
|
+
const require_cornerFinder = require("./cornerFinder-DVHtBOzM.cjs");
|
|
17
|
+
const require_boolean2D = require("./boolean2D-B21GheGE.cjs");
|
|
18
|
+
const require_textBlueprints = require("./textBlueprints-jlqCGG4p.cjs");
|
|
19
|
+
const require_cameraFns = require("./cameraFns-HpsMe1iL.cjs");
|
|
20
20
|
// src/2d/lib/stitching.ts
|
|
21
21
|
/**
|
|
22
22
|
* Group a flat list of curves into connected chains by matching endpoints.
|
|
@@ -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-BCy8JI0O.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-CUsZRWJ7.js";
|
|
4
|
-
import { s as getEdges } from "./topologyQueryFns-
|
|
4
|
+
import { s as getEdges } from "./topologyQueryFns-Clkdolgd.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-DgG0vHN7.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-DKEm5U-p.js";
|
|
10
|
+
import { h as offsetWire2D, i as curveIsClosed, l as curveStartPoint } from "./curveFns-BdmSrGqT.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 wrapSketchDataArray, a as Sketch, g as wrapSketchData, i as Sketches, t as textBlueprints } 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-CaN-lye8.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-DcyidOGa.js";
|
|
14
|
+
import { b as squareDistance2d, l as add2d, s as PRECISION_OFFSET, v as samePoint$1, x as subtract2d } from "./helpers-CcZp3tLI.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-B8tYa1RE.js";
|
|
16
|
+
import { t as cornerFinder } from "./cornerFinder-DHg0ej_Q.js";
|
|
17
|
+
import { c as roundedRectangleBlueprint, n as fuse2D, r as intersect2D, s as polysidesBlueprint, t as cut2D } from "./boolean2D-DYAua9O_.js";
|
|
18
|
+
import { _ as wrapSketchDataArray, a as Sketch, g as wrapSketchData, i as Sketches, t as textBlueprints } from "./textBlueprints-BlfIkOUx.js";
|
|
19
|
+
import { i as projectEdges, t as cameraFromPlane } from "./cameraFns-CAjuoPKb.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 { i as castShape, q as getKernel } from "./shapeTypes-
|
|
1
|
+
import { i as castShape, q as getKernel } from "./shapeTypes-BCy8JI0O.js";
|
|
2
2
|
import { E as ok, P as unwrap, g as err, l as typeCastError } from "./errors-CUsZRWJ7.js";
|
|
3
|
-
import { a as getCachedSurfaceType } from "./topologyQueryFns-
|
|
3
|
+
import { a as getCachedSurfaceType } from "./topologyQueryFns-Clkdolgd.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-CNQn1x5H.cjs");
|
|
2
2
|
const require_errors = require("./errors-B9r_Dzs1.cjs");
|
|
3
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
3
|
+
const require_topologyQueryFns = require("./topologyQueryFns-BwhwOtxv.cjs");
|
|
4
4
|
const require_types = require("./types-CjF9Rofr.cjs");
|
|
5
5
|
// src/topology/cast.ts
|
|
6
6
|
var TOPO_ENUM = {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
2
|
-
const require_occtWasmAdapter = require("./occtWasmAdapter-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-CNQn1x5H.cjs");
|
|
2
|
+
const require_occtWasmAdapter = require("./occtWasmAdapter-CsDULjij.cjs");
|
|
3
3
|
const require_errors = require("./errors-B9r_Dzs1.cjs");
|
|
4
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
4
|
+
const require_topologyQueryFns = require("./topologyQueryFns-BwhwOtxv.cjs");
|
|
5
5
|
const require_constants = require("./constants-oee0S_x6.cjs");
|
|
6
|
-
const require_faceFns = require("./faceFns-
|
|
7
|
-
const require_solidBuilders = require("./solidBuilders-
|
|
6
|
+
const require_faceFns = require("./faceFns-vVGf6osa.cjs");
|
|
7
|
+
const require_solidBuilders = require("./solidBuilders-BN1p303l.cjs");
|
|
8
8
|
const require_arrayAccess = require("./arrayAccess-DpJYARwv.cjs");
|
|
9
9
|
// src/topology/threeHelpers.ts
|
|
10
10
|
/**
|
|
@@ -366,15 +366,26 @@ function fillet(shape, edges, radius, { trackEvolution = true } = {}) {
|
|
|
366
366
|
const { shape: resultShape, evolution } = require_shapeTypes.getKernel().filletWithHistory(shape.wrapped, edgeShapes, kernelRadius, inputFaceHashes, require_constants.HASH_CODE_MAX);
|
|
367
367
|
return finalizeShape3D(evolution, resultShape, [shape], require_errors.BrepErrorCode.FILLET_NOT_3D, "Fillet result is not a 3D shape");
|
|
368
368
|
} catch (e) {
|
|
369
|
-
|
|
370
|
-
return require_errors.err(require_errors.kernelError("FILLET_FAILED", `Fillet operation failed: ${raw}`, e, {
|
|
371
|
-
operation: "fillet",
|
|
369
|
+
return require_errors.err(edgeTreatmentError("fillet", e, filteredEdges, {
|
|
372
370
|
edgeCount: selectedCount,
|
|
373
371
|
radius
|
|
374
372
|
}));
|
|
375
373
|
}
|
|
376
374
|
}
|
|
377
375
|
/**
|
|
376
|
+
* `FILLET_FAILED` / `CHAMFER_FAILED`, with `metadata.failedEdges` set to the
|
|
377
|
+
* edges the kernel named when it could not build them (occt-wasm 5.8+).
|
|
378
|
+
*/
|
|
379
|
+
function edgeTreatmentError(operation, e, edges, metadata) {
|
|
380
|
+
const raw = e instanceof Error ? e.message : String(e);
|
|
381
|
+
const failedEdges = require_occtWasmAdapter.faultyEdgeIndexesOf(e)?.flatMap((i) => edges[i] ?? []);
|
|
382
|
+
return require_errors.kernelError(operation === "fillet" ? "FILLET_FAILED" : "CHAMFER_FAILED", `${operation === "fillet" ? "Fillet" : "Chamfer"} operation failed: ${raw}`, e, {
|
|
383
|
+
operation,
|
|
384
|
+
...metadata,
|
|
385
|
+
...failedEdges ? { failedEdges } : {}
|
|
386
|
+
}, failedEdges && failedEdges.length > 0 ? `The ${operation} could not be built on metadata.failedEdges: use a smaller size there, or leave those edges out` : void 0);
|
|
387
|
+
}
|
|
388
|
+
/**
|
|
378
389
|
* Apply a chamfer (beveled edge) to selected edges of a 3D shape.
|
|
379
390
|
*
|
|
380
391
|
* @param shape - The shape to modify.
|
|
@@ -394,8 +405,8 @@ function chamfer(shape, edges, distance) {
|
|
|
394
405
|
if (paramErr) return paramErr;
|
|
395
406
|
const selectedEdges = edges ?? require_topologyQueryFns.getEdges(shape);
|
|
396
407
|
if (selectedEdges.length === 0) return require_errors.err(require_errors.validationError(require_errors.BrepErrorCode.CHAMFER_NO_EDGES, "No edges found for chamfer"));
|
|
408
|
+
let filteredEdges = [];
|
|
397
409
|
try {
|
|
398
|
-
let filteredEdges;
|
|
399
410
|
let kernelDistance;
|
|
400
411
|
if (typeof distance === "function") {
|
|
401
412
|
const resolved = resolveEdgeCallback$1(selectedEdges, distance);
|
|
@@ -410,9 +421,7 @@ function chamfer(shape, edges, distance) {
|
|
|
410
421
|
const { shape: resultShape, evolution } = require_shapeTypes.getKernel().chamferWithHistory(shape.wrapped, filteredEdges.map((e) => e.wrapped), kernelDistance, inputFaceHashes, require_constants.HASH_CODE_MAX);
|
|
411
422
|
return finalizeShape3D(evolution, resultShape, [shape], require_errors.BrepErrorCode.CHAMFER_NOT_3D, "Chamfer result is not a 3D shape");
|
|
412
423
|
} catch (e) {
|
|
413
|
-
|
|
414
|
-
return require_errors.err(require_errors.kernelError("CHAMFER_FAILED", `Chamfer operation failed: ${raw}`, e, {
|
|
415
|
-
operation: "chamfer",
|
|
424
|
+
return require_errors.err(edgeTreatmentError("chamfer", e, filteredEdges, {
|
|
416
425
|
edgeCount: selectedEdges.length,
|
|
417
426
|
distance
|
|
418
427
|
}));
|
|
@@ -1,10 +1,10 @@
|
|
|
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 {
|
|
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-BCy8JI0O.js";
|
|
2
|
+
import { k as isUnsupportedKernelOperationError, n as faultyEdgeIndexesOf } from "./occtWasmAdapter-ClvPe3OJ.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-CUsZRWJ7.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-Clkdolgd.js";
|
|
5
5
|
import { n as HASH_CODE_MAX } from "./constants-iraOnb2p.js";
|
|
6
|
-
import { y as downcast } from "./faceFns-
|
|
7
|
-
import { C as propagateAllMetadata, f as cut, h as fuseAll, m as fuse, p as cutAll, w as propagateMetadataByHash, x as collectInputFaceHashes } from "./solidBuilders-
|
|
6
|
+
import { y as downcast } from "./faceFns-DKEm5U-p.js";
|
|
7
|
+
import { C as propagateAllMetadata, f as cut, h as fuseAll, m as fuse, p as cutAll, w as propagateMetadataByHash, x as collectInputFaceHashes } from "./solidBuilders-YbLOfWIp.js";
|
|
8
8
|
import { t as firstOrThrow } from "./arrayAccess-BpgouNir.js";
|
|
9
9
|
// src/topology/threeHelpers.ts
|
|
10
10
|
/**
|
|
@@ -366,15 +366,26 @@ function fillet(shape, edges, radius, { trackEvolution = true } = {}) {
|
|
|
366
366
|
const { shape: resultShape, evolution } = getKernel().filletWithHistory(shape.wrapped, edgeShapes, kernelRadius, inputFaceHashes, HASH_CODE_MAX);
|
|
367
367
|
return finalizeShape3D(evolution, resultShape, [shape], BrepErrorCode.FILLET_NOT_3D, "Fillet result is not a 3D shape");
|
|
368
368
|
} catch (e) {
|
|
369
|
-
|
|
370
|
-
return err(kernelError("FILLET_FAILED", `Fillet operation failed: ${raw}`, e, {
|
|
371
|
-
operation: "fillet",
|
|
369
|
+
return err(edgeTreatmentError("fillet", e, filteredEdges, {
|
|
372
370
|
edgeCount: selectedCount,
|
|
373
371
|
radius
|
|
374
372
|
}));
|
|
375
373
|
}
|
|
376
374
|
}
|
|
377
375
|
/**
|
|
376
|
+
* `FILLET_FAILED` / `CHAMFER_FAILED`, with `metadata.failedEdges` set to the
|
|
377
|
+
* edges the kernel named when it could not build them (occt-wasm 5.8+).
|
|
378
|
+
*/
|
|
379
|
+
function edgeTreatmentError(operation, e, edges, metadata) {
|
|
380
|
+
const raw = e instanceof Error ? e.message : String(e);
|
|
381
|
+
const failedEdges = faultyEdgeIndexesOf(e)?.flatMap((i) => edges[i] ?? []);
|
|
382
|
+
return kernelError(operation === "fillet" ? "FILLET_FAILED" : "CHAMFER_FAILED", `${operation === "fillet" ? "Fillet" : "Chamfer"} operation failed: ${raw}`, e, {
|
|
383
|
+
operation,
|
|
384
|
+
...metadata,
|
|
385
|
+
...failedEdges ? { failedEdges } : {}
|
|
386
|
+
}, failedEdges && failedEdges.length > 0 ? `The ${operation} could not be built on metadata.failedEdges: use a smaller size there, or leave those edges out` : void 0);
|
|
387
|
+
}
|
|
388
|
+
/**
|
|
378
389
|
* Apply a chamfer (beveled edge) to selected edges of a 3D shape.
|
|
379
390
|
*
|
|
380
391
|
* @param shape - The shape to modify.
|
|
@@ -394,8 +405,8 @@ function chamfer(shape, edges, distance) {
|
|
|
394
405
|
if (paramErr) return paramErr;
|
|
395
406
|
const selectedEdges = edges ?? getEdges(shape);
|
|
396
407
|
if (selectedEdges.length === 0) return err(validationError(BrepErrorCode.CHAMFER_NO_EDGES, "No edges found for chamfer"));
|
|
408
|
+
let filteredEdges = [];
|
|
397
409
|
try {
|
|
398
|
-
let filteredEdges;
|
|
399
410
|
let kernelDistance;
|
|
400
411
|
if (typeof distance === "function") {
|
|
401
412
|
const resolved = resolveEdgeCallback$1(selectedEdges, distance);
|
|
@@ -410,9 +421,7 @@ function chamfer(shape, edges, distance) {
|
|
|
410
421
|
const { shape: resultShape, evolution } = getKernel().chamferWithHistory(shape.wrapped, filteredEdges.map((e) => e.wrapped), kernelDistance, inputFaceHashes, HASH_CODE_MAX);
|
|
411
422
|
return finalizeShape3D(evolution, resultShape, [shape], BrepErrorCode.CHAMFER_NOT_3D, "Chamfer result is not a 3D shape");
|
|
412
423
|
} catch (e) {
|
|
413
|
-
|
|
414
|
-
return err(kernelError("CHAMFER_FAILED", `Chamfer operation failed: ${raw}`, e, {
|
|
415
|
-
operation: "chamfer",
|
|
424
|
+
return err(edgeTreatmentError("chamfer", e, filteredEdges, {
|
|
416
425
|
edgeCount: selectedEdges.length,
|
|
417
426
|
distance
|
|
418
427
|
}));
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-CNQn1x5H.cjs");
|
|
2
2
|
const require_errors = require("./errors-B9r_Dzs1.cjs");
|
|
3
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
3
|
+
const require_topologyQueryFns = require("./topologyQueryFns-BwhwOtxv.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-vVGf6osa.cjs");
|
|
7
|
+
const require_shapeFns = require("./shapeFns-CJrIL2CG.cjs");
|
|
8
|
+
const require_curveFns = require("./curveFns-DUSOe8uJ.cjs");
|
|
9
|
+
const require_measureFns = require("./measureFns-BoNCUOKe.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-BCy8JI0O.js";
|
|
2
2
|
import { E as ok, g as err, o as queryError, x as isOk } from "./errors-CUsZRWJ7.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-Clkdolgd.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 { n as measureArea } from "./measureFns-
|
|
6
|
+
import { l as normalAt, s as getSurfaceType } from "./faceFns-DKEm5U-p.js";
|
|
7
|
+
import { a as isSameShape, n as getHashCode } from "./shapeFns-De7CbEeQ.js";
|
|
8
|
+
import { f as getCurveType, i as curveIsClosed, o as curveLength } from "./curveFns-BdmSrGqT.js";
|
|
9
|
+
import { n as measureArea } from "./measureFns-eCuwj0im.js";
|
|
10
10
|
// src/utils/vec2d.ts
|
|
11
11
|
/** Precision for curve intersection and parameter operations. */
|
|
12
12
|
var PRECISION_INTERSECTION = 1e-9;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-CNQn1x5H.cjs");
|
|
2
2
|
const require_bug = require("./bug-CBcpIPuf.cjs");
|
|
3
3
|
const require_errors = require("./errors-B9r_Dzs1.cjs");
|
|
4
4
|
const require_arrayAccess = require("./arrayAccess-DpJYARwv.cjs");
|
|
5
|
-
const require_blueprint = require("./blueprint-
|
|
5
|
+
const require_blueprint = require("./blueprint-YK9OBMxh.cjs");
|
|
6
6
|
// src/io/objExportFns.ts
|
|
7
7
|
/** Read a vec3 from a typed array at the given vertex index. */
|
|
8
8
|
function vec3At(arr, i) {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { n as castResultShape, q as getKernel } from "./shapeTypes-
|
|
1
|
+
import { n as castResultShape, q as getKernel } from "./shapeTypes-BCy8JI0O.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-CUsZRWJ7.js";
|
|
4
4
|
import { n as getAtOrThrow } from "./arrayAccess-BpgouNir.js";
|
|
5
|
-
import { c as make2dBezierCurve, h as make2dThreePointArc, p as make2dSegmentCurve, t as Blueprint } from "./blueprint-
|
|
5
|
+
import { c as make2dBezierCurve, h as make2dThreePointArc, p as make2dSegmentCurve, t as Blueprint } from "./blueprint-B8tYa1RE.js";
|
|
6
6
|
// src/io/objExportFns.ts
|
|
7
7
|
/** Read a vec3 from a typed array at the given vertex index. */
|
|
8
8
|
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-0W1-80zv.cjs");
|
|
3
|
+
const require_importFns = require("./importFns-DI3Q8B0Q.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 importSVG, c as blueprintToDXF, d as exportGltf, f as exportOBJ, i as exportSTEPConfigured, l as exportDXF, n as importSTEP, o as importSVGPathD, r as importSTL, s as exportThreeMF, t as importIGES, u as exportGlb } from "./importFns-
|
|
1
|
+
import { n as exportSTEP, r as exportSTL, t as exportIGES } from "./meshFns-B9jPfcB2.js";
|
|
2
|
+
import { a as importSVG, c as blueprintToDXF, d as exportGltf, f as exportOBJ, i as exportSTEPConfigured, l as exportDXF, n as importSTEP, o as importSVGPathD, r as importSTL, s as exportThreeMF, t as importIGES, u as exportGlb } from "./importFns-D_tBVKl2.js";
|
|
3
3
|
export { blueprintToDXF, exportDXF, exportGlb, exportGltf, exportIGES, exportOBJ, exportSTEP, exportSTEPConfigured, exportSTL, exportThreeMF, importIGES, importSTEP, importSTL, importSVG, importSVGPathD };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A fillet or chamfer the kernel could not build, naming the edges it failed
|
|
3
|
+
* on. The indexes point into the edges array passed to the kernel method, so
|
|
4
|
+
* the caller can map them back to its own edge handles without retrying edge
|
|
5
|
+
* by edge.
|
|
6
|
+
*/
|
|
7
|
+
export declare class FaultyEdgesError extends Error {
|
|
8
|
+
constructor(message: string, faultyEdgeIndexes: readonly number[], options?: ErrorOptions);
|
|
9
|
+
}
|
|
10
|
+
/** The failing edges' indexes carried by a {@link FaultyEdgesError}, or `undefined`. */
|
|
11
|
+
export declare function faultyEdgeIndexesOf(error: unknown): readonly number[] | undefined;
|
|
@@ -9,8 +9,9 @@ export declare function makeLineEdge(k: OcctKernelWasm, p1: [number, number, num
|
|
|
9
9
|
export declare function makeCircleEdge(k: OcctKernelWasm, center: [number, number, number], normal: [number, number, number], radius: number): KernelShape;
|
|
10
10
|
export declare function makeCircleArc(k: OcctKernelWasm, center: [number, number, number], normal: [number, number, number], radius: number, startAngle: number, endAngle: number): KernelShape;
|
|
11
11
|
export declare function makeArcEdge(k: OcctKernelWasm, p1: [number, number, number], p2: [number, number, number], p3: [number, number, number]): KernelShape;
|
|
12
|
-
|
|
13
|
-
export declare function
|
|
12
|
+
type Vec3 = [number, number, number];
|
|
13
|
+
export declare function makeEllipseEdge(k: OcctKernelWasm, center: Vec3, normal: Vec3, majorRadius: number, minorRadius: number, xDir?: Vec3): KernelShape;
|
|
14
|
+
export declare function makeEllipseArc(k: OcctKernelWasm, center: Vec3, normal: Vec3, majorRadius: number, minorRadius: number, startAngle: number, endAngle: number, xDir?: Vec3): KernelShape;
|
|
14
15
|
export declare function makeBezierEdge(k: OcctKernelWasm, Module: OcctWasmModule, points: [number, number, number][]): KernelShape;
|
|
15
16
|
export declare function makeTangentArc(k: OcctKernelWasm, startPoint: [number, number, number], startTangent: [number, number, number], endPoint: [number, number, number]): KernelShape;
|
|
16
17
|
export declare function makeHelixWire(k: OcctKernelWasm, pitch: number, height: number, radius: number, center?: [number, number, number], direction?: [number, number, number]): KernelShape;
|
|
@@ -35,3 +36,4 @@ export declare function createVector3d(x: number, y: number, z: number): KernelT
|
|
|
35
36
|
export declare function createAxis1(cx: number, cy: number, cz: number, dx: number, dy: number, dz: number): KernelType;
|
|
36
37
|
export declare function createAxis2(ox: number, oy: number, oz: number, zx: number, zy: number, zz: number, xx?: number, xy?: number, xz?: number): KernelType;
|
|
37
38
|
export declare function createAxis3(ox: number, oy: number, oz: number, zx: number, zy: number, zz: number, xx?: number, xy?: number, xz?: number): KernelType;
|
|
39
|
+
export {};
|
|
@@ -6,6 +6,11 @@ export declare function handle(type: ShapeType, id: number): OcctWasmHandle;
|
|
|
6
6
|
export declare function isOcctWasmHandle(shape: unknown): shape is OcctWasmHandle;
|
|
7
7
|
/** Extract the u32 id from a handle. */
|
|
8
8
|
export declare function unwrap(shape: KernelShape): number;
|
|
9
|
+
/**
|
|
10
|
+
* Run a raw fillet/chamfer call, turning the facade's ` [faulty edges: 3,7]`
|
|
11
|
+
* message suffix (arena ids, occt-wasm 5.8+) into indexes into `edges`.
|
|
12
|
+
*/
|
|
13
|
+
export declare function reportingFaultyEdges<T>(edges: readonly KernelShape[], run: () => T): T;
|
|
9
14
|
/** Map a WASM shape type string to our ShapeType enum. */
|
|
10
15
|
export declare function mapShapeType(wasmType: string): ShapeType;
|
|
11
16
|
/** Wrap a WASM u32 result as a typed handle, querying the kernel for type. */
|
|
@@ -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-CsDULjij.cjs");
|
|
3
3
|
exports.OcctWasmAdapter = require_occtWasmAdapter.OcctWasmAdapter;
|
|
@@ -92,8 +92,8 @@ export declare class OcctWasmAdapter implements KernelAdapter {
|
|
|
92
92
|
makeCircleEdge(center: [number, number, number], normal: [number, number, number], radius: number): KernelShape;
|
|
93
93
|
makeCircleArc(center: [number, number, number], normal: [number, number, number], radius: number, startAngle: number, endAngle: number): KernelShape;
|
|
94
94
|
makeArcEdge(p1: [number, number, number], p2: [number, number, number], p3: [number, number, number]): KernelShape;
|
|
95
|
-
makeEllipseEdge(center: [number, number, number], normal: [number, number, number], majorRadius: number, minorRadius: number,
|
|
96
|
-
makeEllipseArc(center: [number, number, number], normal: [number, number, number], majorRadius: number, minorRadius: number, startAngle: number, endAngle: number,
|
|
95
|
+
makeEllipseEdge(center: [number, number, number], normal: [number, number, number], majorRadius: number, minorRadius: number, xDir?: [number, number, number]): KernelShape;
|
|
96
|
+
makeEllipseArc(center: [number, number, number], normal: [number, number, number], majorRadius: number, minorRadius: number, startAngle: number, endAngle: number, xDir?: [number, number, number]): KernelShape;
|
|
97
97
|
makeBezierEdge(points: [number, number, number][]): KernelShape;
|
|
98
98
|
makeTangentArc(startPoint: [number, number, number], startTangent: [number, number, number], endPoint: [number, number, number]): KernelShape;
|
|
99
99
|
makeHelixWire(pitch: number, height: number, radius: number, center?: [number, number, number], direction?: [number, number, number], _leftHanded?: boolean): KernelShape;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { t as OcctWasmAdapter } from "../../occtWasmAdapter-
|
|
1
|
+
export { t as OcctWasmAdapter } from "../../occtWasmAdapter-ClvPe3OJ.js";
|
|
@@ -167,6 +167,8 @@ export interface OcctKernelWasm {
|
|
|
167
167
|
makeArcEdge(x1: number, y1: number, z1: number, x2: number, y2: number, z2: number, x3: number, y3: number, z3: number): number;
|
|
168
168
|
makeEllipseEdge(cx: number, cy: number, cz: number, nx: number, ny: number, nz: number, majorRadius: number, minorRadius: number): number;
|
|
169
169
|
makeEllipseArc(cx: number, cy: number, cz: number, nx: number, ny: number, nz: number, majorRadius: number, minorRadius: number, startAngle: number, endAngle: number): number;
|
|
170
|
+
/** occt-wasm 5.8+: like makeEllipseArc with the major axis along (xx, xy, xz). */
|
|
171
|
+
makeEllipseArcOriented?(cx: number, cy: number, cz: number, nx: number, ny: number, nz: number, xx: number, xy: number, xz: number, majorRadius: number, minorRadius: number, startAngle: number, endAngle: number): number;
|
|
170
172
|
makeBezierEdge(flatPoints: EmVectorDouble): number;
|
|
171
173
|
makeTangentArc(x1: number, y1: number, z1: number, tx: number, ty: number, tz: number, x2: number, y2: number, z2: number): number;
|
|
172
174
|
makeHelixWire(px: number, py: number, pz: number, dx: number, dy: number, dz: number, pitch: number, height: number, radius: number): number;
|
|
@@ -10,6 +10,8 @@
|
|
|
10
10
|
* comment regresses the moment a consumer's Vite pre-bundles brepjs and reflows
|
|
11
11
|
* the comment off the specifier (#1726); the `@vite-ignore` here only suppresses
|
|
12
12
|
* Vite's "cannot be analyzed" dev warning and its placement no longer affects
|
|
13
|
-
* correctness.
|
|
13
|
+
* correctness. `webpackIgnore` does the same for webpack, which otherwise
|
|
14
|
+
* reports a "Critical dependency" on every compile and replaces the import
|
|
15
|
+
* with an empty context that can never resolve.
|
|
14
16
|
*/
|
|
15
17
|
export declare function importOptionalBackend(specifier: string): Promise<unknown>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { G as _usingCtx, T as isWire, h as disposeResultShape, n as castResultShape, q as getKernel, x as isShape3D } from "./shapeTypes-
|
|
1
|
+
import { G as _usingCtx, T as isWire, h as disposeResultShape, n as castResultShape, q as getKernel, x as isShape3D } from "./shapeTypes-BCy8JI0O.js";
|
|
2
2
|
import { E as ok, b as isErr, d as validationError, g as err, i as kernelError, l as typeCastError, t as BrepErrorCode } from "./errors-CUsZRWJ7.js";
|
|
3
3
|
import { r as toVec3 } from "./types-CKXsIm9-.js";
|
|
4
4
|
import { c as vecLength, t as vecAdd } from "./vecOps-S-m9H_fe.js";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-CNQn1x5H.cjs");
|
|
2
2
|
const require_errors = require("./errors-B9r_Dzs1.cjs");
|
|
3
3
|
const require_types = require("./types-CjF9Rofr.cjs");
|
|
4
4
|
const require_vecOps = require("./vecOps-CrGEPPQM.cjs");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-CNQn1x5H.cjs");
|
|
2
2
|
const require_errors = require("./errors-B9r_Dzs1.cjs");
|
|
3
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
4
|
-
const require_faceFns = require("./faceFns-
|
|
3
|
+
const require_topologyQueryFns = require("./topologyQueryFns-BwhwOtxv.cjs");
|
|
4
|
+
const require_faceFns = require("./faceFns-vVGf6osa.cjs");
|
|
5
5
|
// src/measurement/measureCache.ts
|
|
6
6
|
var cache = /* @__PURE__ */ new WeakMap();
|
|
7
7
|
function getCachedMeasurement(shape, key) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { q as getKernel } from "./shapeTypes-
|
|
1
|
+
import { q as getKernel } from "./shapeTypes-BCy8JI0O.js";
|
|
2
2
|
import { E as ok, d as validationError, g as err, t as BrepErrorCode } from "./errors-CUsZRWJ7.js";
|
|
3
|
-
import { E as kernelCallRaw } from "./topologyQueryFns-
|
|
4
|
-
import { m as uvBounds } from "./faceFns-
|
|
3
|
+
import { E as kernelCallRaw } from "./topologyQueryFns-Clkdolgd.js";
|
|
4
|
+
import { m as uvBounds } from "./faceFns-DKEm5U-p.js";
|
|
5
5
|
// src/measurement/measureCache.ts
|
|
6
6
|
var cache = /* @__PURE__ */ new WeakMap();
|
|
7
7
|
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-BoNCUOKe.cjs");
|
|
3
|
+
const require_principalBoxFns = require("./principalBoxFns-B1j2sNAc.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 { 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-
|
|
2
|
-
import { t as principalBoundingBox } from "./principalBoxFns-
|
|
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-eCuwj0im.js";
|
|
2
|
+
import { t as principalBoundingBox } from "./principalBoxFns-B6PZwxDM.js";
|
|
3
3
|
export { createDistanceQuery, measureArea, measureDistance, measureDistanceProps, measureLength, measureLinearProps, measureSurfaceProps, measureVolume, measureVolumeProps, principalBoundingBox };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-CNQn1x5H.cjs");
|
|
2
2
|
const require_errors = require("./errors-B9r_Dzs1.cjs");
|
|
3
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
4
|
-
const require_originTrackingFns = require("./originTrackingFns-
|
|
3
|
+
const require_topologyQueryFns = require("./topologyQueryFns-BwhwOtxv.cjs");
|
|
4
|
+
const require_originTrackingFns = require("./originTrackingFns-cEKFxtia.cjs");
|
|
5
5
|
// src/topology/meshCache.ts
|
|
6
6
|
/**
|
|
7
7
|
* Build a parameter key for the inner cache map (excludes shape identity).
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { q as getKernel, ut as qualityDeflection } from "./shapeTypes-
|
|
1
|
+
import { q as getKernel, ut as qualityDeflection } from "./shapeTypes-BCy8JI0O.js";
|
|
2
2
|
import { E as ok, g as err, r as ioError } from "./errors-CUsZRWJ7.js";
|
|
3
|
-
import { d as getSolids, n as getBounds } from "./topologyQueryFns-
|
|
4
|
-
import { t as getFaceOrigins } from "./originTrackingFns-
|
|
3
|
+
import { d as getSolids, n as getBounds } from "./topologyQueryFns-Clkdolgd.js";
|
|
4
|
+
import { t as getFaceOrigins } from "./originTrackingFns-BW2BaJW8.js";
|
|
5
5
|
// src/topology/meshCache.ts
|
|
6
6
|
/**
|
|
7
7
|
* Build a parameter key for the inner cache map (excludes shape identity).
|