brepjs 18.27.0 → 18.29.0
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/{blueprint-BRsNfnfQ.cjs → blueprint-79MQJVZa.cjs} +5 -5
- package/dist/{blueprint-CQ04Ov5Z.js → blueprint-CUvDkWLs.js} +5 -5
- package/dist/{blueprintFns-DpPZNhFx.js → blueprintFns-Ce-Mzufq.js} +2 -2
- package/dist/{blueprintFns-C5DCLCtZ.cjs → blueprintFns-DX7ftQu1.cjs} +2 -2
- package/dist/{blueprintSketcher-DaF5OR4M.cjs → blueprintSketcher-CoefmhkD.cjs} +3 -3
- package/dist/{blueprintSketcher-OwXVDMOb.js → blueprintSketcher-DiJ7nX5P.js} +3 -3
- package/dist/{boolean2D-BQKMy6dN.js → boolean2D-B-6u7Td3.js} +4 -4
- package/dist/{boolean2D-gwOq0VXi.cjs → boolean2D-ByEkLCB7.cjs} +4 -4
- package/dist/{booleanFns-cmeKRsth.cjs → booleanFns-2zKQEuA8.cjs} +4 -4
- package/dist/{booleanFns-CuXl5XQP.js → booleanFns-B-saLmi4.js} +4 -4
- package/dist/brepjs.cjs +24 -24
- package/dist/brepjs.js +24 -24
- package/dist/{cameraFns-LurBny3f.cjs → cameraFns-C0uWLB4t.cjs} +2 -2
- package/dist/{cameraFns-DC2ShyXC.js → cameraFns-ILz-I1EN.js} +2 -2
- package/dist/core.cjs +1 -1
- package/dist/core.js +1 -1
- package/dist/{cornerFinder-BjjFVnDq.cjs → cornerFinder-DheJjEdJ.cjs} +1 -1
- package/dist/{cornerFinder-CF8fVEx2.js → cornerFinder-DnbKeXpc.js} +1 -1
- package/dist/{curveFns-BR8gQOAc.cjs → curveFns-BW6fpApo.cjs} +1 -1
- package/dist/{curveFns-Cimni2kq.js → curveFns-Dp2RyxrR.js} +1 -1
- package/dist/{drawFns-Bh1LGuSX.js → drawFns-CJamg2C6.js} +12 -12
- package/dist/{drawFns-btYAn61y.cjs → drawFns-rCnf1L3r.cjs} +12 -12
- package/dist/{extrudeFns-BmF17qhf.js → extrudeFns-CMGE0i5l.js} +1 -1
- package/dist/{extrudeFns-CLrrRprF.cjs → extrudeFns-zngMBHOx.cjs} +1 -1
- package/dist/{faceFns-BFEUkmn7.cjs → faceFns-C8A9sCkb.cjs} +2 -2
- package/dist/{faceFns-D9UAkqPb.js → faceFns-DFDKI39R.js} +2 -2
- package/dist/{helpers-BnF1MObz.cjs → helpers-D-mko0qh.cjs} +6 -6
- package/dist/{helpers-DnrXynu0.js → helpers-POBaax19.js} +6 -6
- package/dist/{historyFns-DGDKVD6-.js → historyFns-CbT3UJYn.js} +4 -4
- package/dist/{historyFns-BX9Bu5NT.cjs → historyFns-D0K337z6.cjs} +4 -4
- package/dist/{importFns-BMN4KCmX.cjs → importFns-B1ym1wuL.cjs} +2 -2
- package/dist/{importFns-B9RUaVsc.js → importFns-CwNl9Ll2.js} +2 -2
- package/dist/io.cjs +2 -2
- package/dist/io.js +2 -2
- package/dist/kernel/brepkit/brepkitWasmTypes.d.ts +17 -11
- package/dist/kernel/brepkit/constructionOps.d.ts +1 -1
- package/dist/kernel/brepkit/geometryOps.d.ts +8 -2
- package/dist/{measureFns-CaOR1TEA.cjs → measureFns-B7x2vp6b.cjs} +3 -3
- package/dist/{measureFns-CiCx5o_s.js → measureFns-CeEybpyd.js} +3 -3
- package/dist/measurement.cjs +1 -1
- package/dist/measurement.js +1 -1
- package/dist/{meshFns-k-gSXquL.js → meshFns-BtNBXH5S.js} +2 -2
- package/dist/{meshFns-CIdP0f35.cjs → meshFns-By5mtdo9.cjs} +2 -2
- package/dist/operations.cjs +2 -2
- package/dist/operations.js +2 -2
- package/dist/{primitiveFns-OvPYb4CU.js → primitiveFns-DfsjF4Kj.js} +7 -7
- package/dist/{primitiveFns-Ds2LNkol.cjs → primitiveFns-IzSRaAG-.cjs} +7 -7
- 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/{shapeFns-ByuSx62n.js → shapeFns-Cf79IuMn.js} +2 -2
- package/dist/{shapeFns-BD6oYLMM.cjs → shapeFns-DPjMiDcX.cjs} +2 -2
- package/dist/shapeRef.cjs +1 -1
- package/dist/shapeRef.js +1 -1
- package/dist/{shapeRefFns-CybMlSCu.cjs → shapeRefFns-hCaw9c68.cjs} +4 -4
- package/dist/{shapeRefFns-Bv3Jj1vz.js → shapeRefFns-sE77hIRw.js} +4 -4
- package/dist/{shapeTypes-BdIQ-d5X.js → shapeTypes-DUC23pOr.js} +27 -24
- package/dist/{shapeTypes-D6hfaPZq.cjs → shapeTypes-q3dLIqqs.cjs} +27 -24
- package/dist/sketching.cjs +3 -3
- package/dist/sketching.js +3 -3
- package/dist/{solidBuilders-DAHTAqeh.cjs → solidBuilders-BoeIWGQs.cjs} +2 -2
- package/dist/{solidBuilders-TJZOIga_.js → solidBuilders-CwwLuRz8.js} +2 -2
- package/dist/{surfaceBuilders-CzRFME5_.cjs → surfaceBuilders-BJX_D1VO.cjs} +2 -2
- package/dist/{surfaceBuilders-rNgtRqTR.js → surfaceBuilders-CRTJ3eLf.js} +2 -2
- package/dist/text.cjs +2 -2
- package/dist/text.js +2 -2
- package/dist/{textBlueprints-D7gWCZ88.cjs → textBlueprints-CuPkJa3W.cjs} +7 -7
- package/dist/{textBlueprints-C9eKTxef.js → textBlueprints-OEB7VKBv.js} +7 -7
- package/dist/{textMetrics-B5SN90x5.cjs → textMetrics-boJWbnQk.cjs} +1 -1
- package/dist/{textMetrics-0y73spLE.js → textMetrics-lTkakQKC.js} +1 -1
- package/dist/topology.cjs +7 -7
- package/dist/topology.js +7 -7
- package/dist/{topologyQueryFns-Ds2H75YB.js → topologyQueryFns-BELdxJ8R.js} +1 -1
- package/dist/{topologyQueryFns-hG0APAJN.cjs → topologyQueryFns-C38cIHle.cjs} +1 -1
- package/package.json +2 -2
|
@@ -6237,9 +6237,15 @@ function projectEdges(bk, shape, _cameraOrigin, _cameraDirection, _cameraXAxis)
|
|
|
6237
6237
|
function getNurbsCurveData(_bk, _edge) {
|
|
6238
6238
|
return null;
|
|
6239
6239
|
}
|
|
6240
|
-
/**
|
|
6241
|
-
|
|
6242
|
-
|
|
6240
|
+
/**
|
|
6241
|
+
* Read-only B-Spline/NURBS surface data for a face.
|
|
6242
|
+
*
|
|
6243
|
+
* Type-gated: analytic faces (plane, cylinder, cone, sphere, torus) return
|
|
6244
|
+
* `null`; only intrinsically free-form faces yield a record. The kernel emits
|
|
6245
|
+
* distinct knots paired with multiplicities, matching {@link NurbsSurfaceData}.
|
|
6246
|
+
*/
|
|
6247
|
+
function getNurbsSurfaceData(bk, face) {
|
|
6248
|
+
return JSON.parse(bk.getNurbsSurfaceDataParity(unwrap(face, "face")));
|
|
6243
6249
|
}
|
|
6244
6250
|
/** Co-located factory: returns the geometry-query slice of {@link KernelAdapter} bound to `bk`. */
|
|
6245
6251
|
function makeGeometryOps(bk) {
|
|
@@ -6867,13 +6873,10 @@ function makeWire(bk, edges) {
|
|
|
6867
6873
|
}
|
|
6868
6874
|
return wireHandle(bk.makeWire(edgeIds, true));
|
|
6869
6875
|
}
|
|
6870
|
-
function makeFace(bk, wire,
|
|
6876
|
+
function makeFace(bk, wire, planar) {
|
|
6871
6877
|
const h = wire;
|
|
6872
|
-
|
|
6873
|
-
|
|
6874
|
-
return faceHandle(bk.makeFaceFromWire(wireId));
|
|
6875
|
-
}
|
|
6876
|
-
return faceHandle(bk.makeFaceFromWire(unwrap(wire, "wire")));
|
|
6878
|
+
const wireId = h.type === "edge" ? bk.makeWire([h.id], true) : unwrap(wire, "wire");
|
|
6879
|
+
return faceHandle(planar ? bk.makePlanarFaceFromWire(wireId) : bk.makeFaceFromWire(wireId));
|
|
6877
6880
|
}
|
|
6878
6881
|
function makeBox(bk, width, height, depth) {
|
|
6879
6882
|
return solidHandle(bk.makeBox(width, height, depth));
|
|
@@ -7076,7 +7079,7 @@ function solidFromShell(bk, shell) {
|
|
|
7076
7079
|
return solidHandle(bk.solidFromShell(unwrap(shell, "shell")));
|
|
7077
7080
|
}
|
|
7078
7081
|
function makeNonPlanarFace(bk, wire) {
|
|
7079
|
-
return makeFace(bk, wire,
|
|
7082
|
+
return makeFace(bk, wire, false);
|
|
7080
7083
|
}
|
|
7081
7084
|
function addHolesInFace(bk, face, holeWires) {
|
|
7082
7085
|
const wireIds = holeWires.map((w) => unwrap(w, "wire"));
|
|
@@ -7086,7 +7089,7 @@ function removeHolesFromFace(bk, face) {
|
|
|
7086
7089
|
return faceHandle(bk.removeHolesFromFace(unwrap(face, "face")));
|
|
7087
7090
|
}
|
|
7088
7091
|
function makeFaceOnSurface(bk, _surface, wire) {
|
|
7089
|
-
return makeFace(bk, wire,
|
|
7092
|
+
return makeFace(bk, wire, false);
|
|
7090
7093
|
}
|
|
7091
7094
|
function bsplineSurface(bk, points, rows, cols) {
|
|
7092
7095
|
const coords = [];
|
|
@@ -9375,13 +9378,13 @@ function makeMeasureOps(bk) {
|
|
|
9375
9378
|
//#endregion
|
|
9376
9379
|
//#region src/kernel/brepkit/meshOps.ts
|
|
9377
9380
|
function mesh(bk, shape, options) {
|
|
9378
|
-
if (options.angularTolerance > 0) warnOnce("mesh-angular", "mesh angularTolerance is not supported; only linear deflection is used.");
|
|
9379
9381
|
const h = unwrap(shape);
|
|
9380
9382
|
const bkHandle = shape;
|
|
9381
9383
|
const deflection = options.tolerance || .01;
|
|
9384
|
+
const angularTol = options.angularTolerance > 0 ? options.angularTolerance : void 0;
|
|
9382
9385
|
let result;
|
|
9383
|
-
if (bkHandle.type === "solid") result = meshSolid(bk, h, deflection, !!options.includeUVs);
|
|
9384
|
-
else if (bkHandle.type === "face") result = meshSingleFace(bk, h, deflection, 0);
|
|
9386
|
+
if (bkHandle.type === "solid") result = meshSolid(bk, h, deflection, !!options.includeUVs, angularTol);
|
|
9387
|
+
else if (bkHandle.type === "face") result = meshSingleFace(bk, h, deflection, 0, angularTol);
|
|
9385
9388
|
else throw new Error(`brepkit: cannot mesh shape of type '${bkHandle.type}'`);
|
|
9386
9389
|
if (options.skipNormals) result.normals = new Float32Array(0);
|
|
9387
9390
|
if (!options.includeUVs) result.uvs = new Float32Array(0);
|
|
@@ -9417,12 +9420,12 @@ function hasTriangulation(_bk, _shape) {
|
|
|
9417
9420
|
return false;
|
|
9418
9421
|
}
|
|
9419
9422
|
/** Tessellate a solid with per-face groups for brepjs mesh format. */
|
|
9420
|
-
function meshSolid(bk, solidId, deflection, includeUVs) {
|
|
9423
|
+
function meshSolid(bk, solidId, deflection, includeUVs, angularTolerance) {
|
|
9421
9424
|
try {
|
|
9422
|
-
return meshSolidGrouped(bk, solidId, deflection, includeUVs);
|
|
9425
|
+
return meshSolidGrouped(bk, solidId, deflection, includeUVs, angularTolerance);
|
|
9423
9426
|
} catch (e) {
|
|
9424
9427
|
console.warn(`brepkit: tessellateSolidGrouped failed (solidId=${solidId}), falling back to per-face:`, e);
|
|
9425
|
-
return meshSolidPerFace(bk, solidId, deflection);
|
|
9428
|
+
return meshSolidPerFace(bk, solidId, deflection, angularTolerance);
|
|
9426
9429
|
}
|
|
9427
9430
|
}
|
|
9428
9431
|
/**
|
|
@@ -9432,8 +9435,8 @@ function meshSolid(bk, solidId, deflection, includeUVs) {
|
|
|
9432
9435
|
* When `includeUVs` is true, makes an additional `tessellateSolidUV` call
|
|
9433
9436
|
* to populate real surface parametrization coordinates.
|
|
9434
9437
|
*/
|
|
9435
|
-
function meshSolidGrouped(bk, solidId, deflection, includeUVs) {
|
|
9436
|
-
const json = bk.tessellateSolidGrouped(solidId, deflection);
|
|
9438
|
+
function meshSolidGrouped(bk, solidId, deflection, includeUVs, angularTolerance) {
|
|
9439
|
+
const json = bk.tessellateSolidGrouped(solidId, deflection, angularTolerance);
|
|
9437
9440
|
const data = JSON.parse(json);
|
|
9438
9441
|
const faceIds = toArray(bk.getSolidFaces(solidId));
|
|
9439
9442
|
const groupCount = data.faceOffsets.length - 1;
|
|
@@ -9453,7 +9456,7 @@ function meshSolidGrouped(bk, solidId, deflection, includeUVs) {
|
|
|
9453
9456
|
if (includeUVs) {
|
|
9454
9457
|
const expectedUvLen = data.positions.length / 3 * 2;
|
|
9455
9458
|
try {
|
|
9456
|
-
const uvJson = bk.tessellateSolidUV(solidId, deflection);
|
|
9459
|
+
const uvJson = bk.tessellateSolidUV(solidId, deflection, angularTolerance);
|
|
9457
9460
|
const uvData = JSON.parse(uvJson);
|
|
9458
9461
|
if (uvData.uvs.length === expectedUvLen) uvs = new Float32Array(uvData.uvs);
|
|
9459
9462
|
else uvs = new Float32Array(expectedUvLen);
|
|
@@ -9470,7 +9473,7 @@ function meshSolidGrouped(bk, solidId, deflection, includeUVs) {
|
|
|
9470
9473
|
};
|
|
9471
9474
|
}
|
|
9472
9475
|
/** Per-face tessellation fallback -- N WASM calls, one per face. */
|
|
9473
|
-
function meshSolidPerFace(bk, solidId, deflection) {
|
|
9476
|
+
function meshSolidPerFace(bk, solidId, deflection, angularTolerance) {
|
|
9474
9477
|
const faceIds = toArray(bk.getSolidFaces(solidId));
|
|
9475
9478
|
const allVertices = [];
|
|
9476
9479
|
const allNormals = [];
|
|
@@ -9479,7 +9482,7 @@ function meshSolidPerFace(bk, solidId, deflection) {
|
|
|
9479
9482
|
const faceGroups = [];
|
|
9480
9483
|
let vertexOffset = 0;
|
|
9481
9484
|
for (const faceId of faceIds) try {
|
|
9482
|
-
const faceMesh = bk.tessellateFace(faceId, deflection);
|
|
9485
|
+
const faceMesh = bk.tessellateFace(faceId, deflection, angularTolerance);
|
|
9483
9486
|
const positions = faceMesh.positions;
|
|
9484
9487
|
const normals = faceMesh.normals;
|
|
9485
9488
|
const indices = faceMesh.indices;
|
|
@@ -9508,8 +9511,8 @@ function meshSolidPerFace(bk, solidId, deflection) {
|
|
|
9508
9511
|
};
|
|
9509
9512
|
}
|
|
9510
9513
|
/** Tessellate a single face and return brepjs mesh format. */
|
|
9511
|
-
function meshSingleFace(bk, faceId, deflection, faceHash) {
|
|
9512
|
-
const faceMesh = bk.tessellateFace(faceId, deflection);
|
|
9514
|
+
function meshSingleFace(bk, faceId, deflection, faceHash, angularTolerance) {
|
|
9515
|
+
const faceMesh = bk.tessellateFace(faceId, deflection, angularTolerance);
|
|
9513
9516
|
const positions = faceMesh.positions;
|
|
9514
9517
|
const normals = faceMesh.normals;
|
|
9515
9518
|
const indices = faceMesh.indices;
|
package/dist/sketching.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_textBlueprints = require("./textBlueprints-
|
|
3
|
-
const require_blueprintSketcher = require("./blueprintSketcher-
|
|
4
|
-
const require_drawFns = require("./drawFns-
|
|
2
|
+
const require_textBlueprints = require("./textBlueprints-CuPkJa3W.cjs");
|
|
3
|
+
const require_blueprintSketcher = require("./blueprintSketcher-CoefmhkD.cjs");
|
|
4
|
+
const require_drawFns = require("./drawFns-rCnf1L3r.cjs");
|
|
5
5
|
//#region src/sketching.ts
|
|
6
6
|
/**
|
|
7
7
|
* brepjs/sketching — Sketcher, Drawing, and sketch-to-shape operations.
|
package/dist/sketching.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { n as BaseSketcher2d, t as BlueprintSketcher } from "./blueprintSketcher-
|
|
2
|
-
import { A as sketchEllipse, C as DrawingPen, D as makeBaseBox, E as deserializeDrawing, F as sketchRectangle, I as sketchRoundedRectangle, L as FaceSketcher, M as sketchHelix, N as sketchParametricFunction, O as polysideInnerRadius, P as sketchPolysides, R as Sketcher, S as drawText, T as Drawing, _ as drawPolysides, a as drawingIntersect, b as drawSingleCircle, c as rotateDrawing, d as drawFaceOutline, f as drawProjection, g as drawPointsInterpolation, h as drawParametricFunction, i as drawingFuse, j as sketchFaceOffset, k as sketchCircle, l as scaleDrawing, m as drawEllipse, n as drawingCut, o as drawingToSketchOnPlane, p as drawCircle, r as drawingFillet, s as mirrorDrawing, t as drawingChamfer, u as translateDrawing, v as drawRectangle, w as draw, x as drawSingleEllipse, y as drawRoundedRectangle } from "./drawFns-
|
|
3
|
-
import { a as Sketch, c as compoundSketchLoft, d as sketchFace, f as sketchLoft, h as sketchWires, i as Sketches, l as compoundSketchRevolve, m as sketchSweep, o as compoundSketchExtrude, p as sketchRevolve, s as compoundSketchFace, u as sketchExtrude, v as CompoundSketch } from "./textBlueprints-
|
|
1
|
+
import { n as BaseSketcher2d, t as BlueprintSketcher } from "./blueprintSketcher-DiJ7nX5P.js";
|
|
2
|
+
import { A as sketchEllipse, C as DrawingPen, D as makeBaseBox, E as deserializeDrawing, F as sketchRectangle, I as sketchRoundedRectangle, L as FaceSketcher, M as sketchHelix, N as sketchParametricFunction, O as polysideInnerRadius, P as sketchPolysides, R as Sketcher, S as drawText, T as Drawing, _ as drawPolysides, a as drawingIntersect, b as drawSingleCircle, c as rotateDrawing, d as drawFaceOutline, f as drawProjection, g as drawPointsInterpolation, h as drawParametricFunction, i as drawingFuse, j as sketchFaceOffset, k as sketchCircle, l as scaleDrawing, m as drawEllipse, n as drawingCut, o as drawingToSketchOnPlane, p as drawCircle, r as drawingFillet, s as mirrorDrawing, t as drawingChamfer, u as translateDrawing, v as drawRectangle, w as draw, x as drawSingleEllipse, y as drawRoundedRectangle } from "./drawFns-CJamg2C6.js";
|
|
3
|
+
import { a as Sketch, c as compoundSketchLoft, d as sketchFace, f as sketchLoft, h as sketchWires, i as Sketches, l as compoundSketchRevolve, m as sketchSweep, o as compoundSketchExtrude, p as sketchRevolve, s as compoundSketchFace, u as sketchExtrude, v as CompoundSketch } from "./textBlueprints-OEB7VKBv.js";
|
|
4
4
|
//#region src/sketching.ts
|
|
5
5
|
/**
|
|
6
6
|
* brepjs/sketching — Sketcher, Drawing, and sketch-to-shape operations.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-q3dLIqqs.cjs");
|
|
2
2
|
const require_errors = require("./errors-DxoD7zgx.cjs");
|
|
3
|
-
const require_faceFns = require("./faceFns-
|
|
3
|
+
const require_faceFns = require("./faceFns-C8A9sCkb.cjs");
|
|
4
4
|
//#region src/topology/shapeUtils.ts
|
|
5
5
|
/**
|
|
6
6
|
* Shape assembly utilities — welding and sewing operations.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Z as getKernel, _ as isSolid, c as createSolid, g as isShell, h as isShape3D, i as createCompound, l as createVertex } from "./shapeTypes-
|
|
1
|
+
import { Z as getKernel, _ as isSolid, c as createSolid, g as isShell, h as isShape3D, i as createCompound, l as createVertex } from "./shapeTypes-DUC23pOr.js";
|
|
2
2
|
import { A as ok, R as unwrap, b as err, l as typeCastError, v as andThen } from "./errors-BJSTLaDI.js";
|
|
3
|
-
import { _ as downcast, g as cast } from "./faceFns-
|
|
3
|
+
import { _ as downcast, g as cast } from "./faceFns-DFDKI39R.js";
|
|
4
4
|
//#region src/topology/shapeUtils.ts
|
|
5
5
|
/**
|
|
6
6
|
* Shape assembly utilities — welding and sewing operations.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-q3dLIqqs.cjs");
|
|
2
2
|
const require_errors = require("./errors-DxoD7zgx.cjs");
|
|
3
|
-
const require_faceFns = require("./faceFns-
|
|
3
|
+
const require_faceFns = require("./faceFns-C8A9sCkb.cjs");
|
|
4
4
|
//#region src/utils/range.ts
|
|
5
5
|
/** Generate an array of integers `[0, 1, …, len - 1]`. */
|
|
6
6
|
function range(len) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Z as getKernel, a as createEdge, o as createFace, p as isFace, u as createWire, w as isPlanarFace } from "./shapeTypes-
|
|
1
|
+
import { Z as getKernel, a as createEdge, o as createFace, p as isFace, u as createWire, w as isPlanarFace } from "./shapeTypes-DUC23pOr.js";
|
|
2
2
|
import { A as ok, b as err, d as validationError, i as kernelError, v as andThen } from "./errors-BJSTLaDI.js";
|
|
3
|
-
import { g as cast, l as outerWire } from "./faceFns-
|
|
3
|
+
import { g as cast, l as outerWire } from "./faceFns-DFDKI39R.js";
|
|
4
4
|
//#region src/utils/range.ts
|
|
5
5
|
/** Generate an array of integers `[0, 1, …, len - 1]`. */
|
|
6
6
|
function range(len) {
|
package/dist/text.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_textBlueprints = require("./textBlueprints-
|
|
3
|
-
const require_textMetrics = require("./textMetrics-
|
|
2
|
+
const require_textBlueprints = require("./textBlueprints-CuPkJa3W.cjs");
|
|
3
|
+
const require_textMetrics = require("./textMetrics-boJWbnQk.cjs");
|
|
4
4
|
exports.fontMetrics = require_textMetrics.fontMetrics;
|
|
5
5
|
exports.getFont = require_textBlueprints.getFont;
|
|
6
6
|
exports.loadFont = require_textBlueprints.loadFont;
|
package/dist/text.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { n as getFont, r as loadFont, t as textBlueprints } from "./textBlueprints-
|
|
2
|
-
import { n as textMetrics, r as sketchText, t as fontMetrics } from "./textMetrics-
|
|
1
|
+
import { n as getFont, r as loadFont, t as textBlueprints } from "./textBlueprints-OEB7VKBv.js";
|
|
2
|
+
import { n as textMetrics, r as sketchText, t as fontMetrics } from "./textMetrics-lTkakQKC.js";
|
|
3
3
|
export { fontMetrics, getFont, loadFont, sketchText, textBlueprints, textMetrics };
|
|
@@ -29,18 +29,18 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
29
29
|
enumerable: true
|
|
30
30
|
}) : target, mod));
|
|
31
31
|
//#endregion
|
|
32
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
32
|
+
const require_shapeTypes = require("./shapeTypes-q3dLIqqs.cjs");
|
|
33
33
|
const require_errors = require("./errors-DxoD7zgx.cjs");
|
|
34
34
|
const require_types = require("./types-KjA8tY4Y.cjs");
|
|
35
35
|
const require_vecOps = require("./vecOps-CCnJt-yH.cjs");
|
|
36
36
|
const require_planeOps = require("./planeOps-C6wxugvC.cjs");
|
|
37
|
-
const require_faceFns = require("./faceFns-
|
|
38
|
-
const require_curveFns = require("./curveFns-
|
|
37
|
+
const require_faceFns = require("./faceFns-C8A9sCkb.cjs");
|
|
38
|
+
const require_curveFns = require("./curveFns-BW6fpApo.cjs");
|
|
39
39
|
const require_arrayAccess = require("./arrayAccess-e4H9cBfh.cjs");
|
|
40
|
-
const require_surfaceBuilders = require("./surfaceBuilders-
|
|
41
|
-
const require_blueprintSketcher = require("./blueprintSketcher-
|
|
42
|
-
const require_solidBuilders = require("./solidBuilders-
|
|
43
|
-
const require_extrudeFns = require("./extrudeFns-
|
|
40
|
+
const require_surfaceBuilders = require("./surfaceBuilders-BJX_D1VO.cjs");
|
|
41
|
+
const require_blueprintSketcher = require("./blueprintSketcher-CoefmhkD.cjs");
|
|
42
|
+
const require_solidBuilders = require("./solidBuilders-BoeIWGQs.cjs");
|
|
43
|
+
const require_extrudeFns = require("./extrudeFns-zngMBHOx.cjs");
|
|
44
44
|
let opentype_js = require("opentype.js");
|
|
45
45
|
opentype_js = __toESM(opentype_js, 1);
|
|
46
46
|
//#region src/operations/loftFns.ts
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { Z as getKernel, h as isShape3D, o as createFace, p as isFace, t as castShape, u as createWire } from "./shapeTypes-
|
|
1
|
+
import { Z as getKernel, h as isShape3D, o as createFace, p as isFace, t as castShape, u as createWire } from "./shapeTypes-DUC23pOr.js";
|
|
2
2
|
import { A as ok, R as unwrap, T as isOk, b as err, d as validationError, h as bug, i as kernelError, l as typeCastError, r as ioError, t as BrepErrorCode } from "./errors-BJSTLaDI.js";
|
|
3
3
|
import { r as toVec3 } from "./types-D24Y27N0.js";
|
|
4
4
|
import { d as vecNormalize, h as vecScale, r as vecCross } from "./vecOps-SKPRvPH-.js";
|
|
5
5
|
import { n as createPlane } from "./planeOps-CblVcWbn.js";
|
|
6
|
-
import { _ as downcast, g as cast } from "./faceFns-
|
|
7
|
-
import { c as curveStartPoint, l as curveTangentAt } from "./curveFns-
|
|
6
|
+
import { _ as downcast, g as cast } from "./faceFns-DFDKI39R.js";
|
|
7
|
+
import { c as curveStartPoint, l as curveTangentAt } from "./curveFns-Dp2RyxrR.js";
|
|
8
8
|
import { n as getAtOrThrow, t as firstOrThrow } from "./arrayAccess-DrUGPADn.js";
|
|
9
|
-
import { i as makeNewFaceWithinFace, r as makeFace, t as addHolesInFace } from "./surfaceBuilders-
|
|
10
|
-
import { r as organiseBlueprints, t as BlueprintSketcher } from "./blueprintSketcher-
|
|
11
|
-
import { o as makeSolid, t as makeCompound } from "./solidBuilders-
|
|
12
|
-
import { c as sweep, i as complexExtrude, l as twistExtrude, r as revolve, t as extrude } from "./extrudeFns-
|
|
9
|
+
import { i as makeNewFaceWithinFace, r as makeFace, t as addHolesInFace } from "./surfaceBuilders-CRTJ3eLf.js";
|
|
10
|
+
import { r as organiseBlueprints, t as BlueprintSketcher } from "./blueprintSketcher-DiJ7nX5P.js";
|
|
11
|
+
import { o as makeSolid, t as makeCompound } from "./solidBuilders-CwwLuRz8.js";
|
|
12
|
+
import { c as sweep, i as complexExtrude, l as twistExtrude, r as revolve, t as extrude } from "./extrudeFns-CMGE0i5l.js";
|
|
13
13
|
import opentype from "opentype.js";
|
|
14
14
|
//#region src/operations/loftFns.ts
|
|
15
15
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { A as ok, b as err, d as validationError, t as BrepErrorCode } from "./errors-BJSTLaDI.js";
|
|
2
|
-
import { g as wrapSketchData, i as Sketches, n as getFont, t as textBlueprints, v as CompoundSketch } from "./textBlueprints-
|
|
2
|
+
import { g as wrapSketchData, i as Sketches, n as getFont, t as textBlueprints, v as CompoundSketch } from "./textBlueprints-OEB7VKBv.js";
|
|
3
3
|
//#region src/text/sketchText.ts
|
|
4
4
|
/**
|
|
5
5
|
* Render text as 3D sketch outlines on a plane.
|
package/dist/topology.cjs
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
3
|
-
const require_faceFns = require("./faceFns-
|
|
4
|
-
const require_shapeFns = require("./shapeFns-
|
|
5
|
-
const require_curveFns = require("./curveFns-
|
|
6
|
-
const require_meshFns = require("./meshFns-
|
|
7
|
-
const require_booleanFns = require("./booleanFns-
|
|
8
|
-
const require_primitiveFns = require("./primitiveFns-
|
|
2
|
+
const require_topologyQueryFns = require("./topologyQueryFns-C38cIHle.cjs");
|
|
3
|
+
const require_faceFns = require("./faceFns-C8A9sCkb.cjs");
|
|
4
|
+
const require_shapeFns = require("./shapeFns-DPjMiDcX.cjs");
|
|
5
|
+
const require_curveFns = require("./curveFns-BW6fpApo.cjs");
|
|
6
|
+
const require_meshFns = require("./meshFns-By5mtdo9.cjs");
|
|
7
|
+
const require_booleanFns = require("./booleanFns-2zKQEuA8.cjs");
|
|
8
|
+
const require_primitiveFns = require("./primitiveFns-IzSRaAG-.cjs");
|
|
9
9
|
exports.addHoles = require_primitiveFns.addHoles;
|
|
10
10
|
exports.adjacentFaces = require_primitiveFns.adjacentFaces;
|
|
11
11
|
exports.approximateCurve = require_curveFns.approximateCurve;
|
package/dist/topology.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { d as invalidateShapeCache, f as iterEdges, g as vertexPosition, h as iterWires, l as getVertices, m as iterVertices, n as getBounds, o as getEdges, p as iterFaces, s as getFaces, u as getWires } from "./topologyQueryFns-
|
|
2
|
-
import { _ as downcast, a as flipFaceOrientation, b as iterTopo, c as normalAt, d as projectPointOnFace, g as cast, h as asTopo, i as faceOrientation, l as outerWire, m as uvCoordinates, n as faceCenter, o as getSurfaceType, p as uvBounds, r as faceGeomType, s as innerWires, t as classifyPointOnFace, u as pointOnSurface, v as fromBREP, x as shapeType, y as isCompSolid } from "./faceFns-
|
|
3
|
-
import { a as isSameShape, i as isEqualShape, n as getHashCode } from "./shapeFns-
|
|
4
|
-
import { a as curveLength, c as curveStartPoint, d as getCurveType, f as getOrientation, i as curveIsPeriodic, l as curveTangentAt, m as offsetWire2D, n as curveEndPoint, o as curvePeriod, p as interpolateCurve, r as curveIsClosed, s as curvePointAt, t as approximateCurve, u as flipOrientation } from "./curveFns-
|
|
5
|
-
import { c as createMeshCache, n as exportSTEP, r as exportSTL, s as clearMeshCache, t as exportIGES } from "./meshFns-
|
|
6
|
-
import { a as fuseAll, r as cutAll } from "./booleanFns-
|
|
7
|
-
import { $ as fuseAllBisect, A as fixShape, C as threePointArc, D as wireLoop, E as wire, G as chamferWithEvolution, I as solidFromShell, J as fuseWithEvolution, K as cutWithEvolution, M as healFace, N as healSolid, O as autoHeal, P as healWire, Q as cutAllBisect, S as tangentArc, T as vertex, U as variableFillet, W as positionOnCurve, X as shellWithEvolution, Y as intersectWithEvolution, Z as checkBoolean, _ as polygon, a as circle, at as sharedEdges, b as sphere, c as cylinder, ct as chamferDistAngle, d as ellipsoid, et as getNurbsCurveData, f as face, ft as toLineGeometryData, g as offsetFace, h as line, i as bsplineApprox, it as facesOfEdge, k as fixSelfIntersection, l as ellipse, lt as toBufferGeometryData, m as helix, n as bezier, nt as adjacentFaces, o as compound, ot as verticesOfEdge, p as filledFace, q as filletWithEvolution, r as box, rt as edgesOfFace, s as cone, st as wiresOfFace, t as addHoles, tt as getNurbsSurfaceData, u as ellipseArc, ut as toGroupedBufferGeometryData, v as sewShells, w as torus, x as subFace, y as solid } from "./primitiveFns-
|
|
1
|
+
import { d as invalidateShapeCache, f as iterEdges, g as vertexPosition, h as iterWires, l as getVertices, m as iterVertices, n as getBounds, o as getEdges, p as iterFaces, s as getFaces, u as getWires } from "./topologyQueryFns-BELdxJ8R.js";
|
|
2
|
+
import { _ as downcast, a as flipFaceOrientation, b as iterTopo, c as normalAt, d as projectPointOnFace, g as cast, h as asTopo, i as faceOrientation, l as outerWire, m as uvCoordinates, n as faceCenter, o as getSurfaceType, p as uvBounds, r as faceGeomType, s as innerWires, t as classifyPointOnFace, u as pointOnSurface, v as fromBREP, x as shapeType, y as isCompSolid } from "./faceFns-DFDKI39R.js";
|
|
3
|
+
import { a as isSameShape, i as isEqualShape, n as getHashCode } from "./shapeFns-Cf79IuMn.js";
|
|
4
|
+
import { a as curveLength, c as curveStartPoint, d as getCurveType, f as getOrientation, i as curveIsPeriodic, l as curveTangentAt, m as offsetWire2D, n as curveEndPoint, o as curvePeriod, p as interpolateCurve, r as curveIsClosed, s as curvePointAt, t as approximateCurve, u as flipOrientation } from "./curveFns-Dp2RyxrR.js";
|
|
5
|
+
import { c as createMeshCache, n as exportSTEP, r as exportSTL, s as clearMeshCache, t as exportIGES } from "./meshFns-BtNBXH5S.js";
|
|
6
|
+
import { a as fuseAll, r as cutAll } from "./booleanFns-B-saLmi4.js";
|
|
7
|
+
import { $ as fuseAllBisect, A as fixShape, C as threePointArc, D as wireLoop, E as wire, G as chamferWithEvolution, I as solidFromShell, J as fuseWithEvolution, K as cutWithEvolution, M as healFace, N as healSolid, O as autoHeal, P as healWire, Q as cutAllBisect, S as tangentArc, T as vertex, U as variableFillet, W as positionOnCurve, X as shellWithEvolution, Y as intersectWithEvolution, Z as checkBoolean, _ as polygon, a as circle, at as sharedEdges, b as sphere, c as cylinder, ct as chamferDistAngle, d as ellipsoid, et as getNurbsCurveData, f as face, ft as toLineGeometryData, g as offsetFace, h as line, i as bsplineApprox, it as facesOfEdge, k as fixSelfIntersection, l as ellipse, lt as toBufferGeometryData, m as helix, n as bezier, nt as adjacentFaces, o as compound, ot as verticesOfEdge, p as filledFace, q as filletWithEvolution, r as box, rt as edgesOfFace, s as cone, st as wiresOfFace, t as addHoles, tt as getNurbsSurfaceData, u as ellipseArc, ut as toGroupedBufferGeometryData, v as sewShells, w as torus, x as subFace, y as solid } from "./primitiveFns-DfsjF4Kj.js";
|
|
8
8
|
export { addHoles, adjacentFaces, approximateCurve, asTopo, autoHeal, bezier, box, bsplineApprox, cast, chamferDistAngle as chamferDistAngleShape, chamferWithEvolution, checkBoolean, circle, classifyPointOnFace, clearMeshCache, compound, cone, createMeshCache, curveEndPoint, curveIsClosed, curveIsPeriodic, curveLength, curvePeriod, curvePointAt, curveStartPoint, curveTangentAt, cutAll, cutAllBisect, cutWithEvolution, cylinder, fromBREP as deserializeShape, downcast, edgesOfFace, ellipse, ellipseArc, ellipsoid, exportIGES, exportSTEP, exportSTL, face, faceCenter, faceGeomType, faceOrientation, facesOfEdge, filledFace, filletWithEvolution, fixSelfIntersection, fixShape, flipFaceOrientation, flipOrientation, fuseAll, fuseAllBisect, fuseWithEvolution, getBounds, getCurveType, getEdges, getFaces, getHashCode, getNurbsCurveData, getNurbsSurfaceData, getOrientation, getSurfaceType, getVertices, getWires, healFace, healSolid, healWire, helix, innerWires, interpolateCurve, intersectWithEvolution, invalidateShapeCache, isCompSolid, isEqualShape, isSameShape, iterEdges, iterFaces, iterTopo, iterVertices, iterWires, line, normalAt, offsetFace, offsetWire2D, outerWire, pointOnSurface, polygon, positionOnCurve, projectPointOnFace, sewShells, shapeType, sharedEdges, shellWithEvolution, solid, solidFromShell, sphere, subFace, tangentArc, threePointArc, toBufferGeometryData, toGroupedBufferGeometryData, toLineGeometryData, torus, uvBounds, uvCoordinates, variableFillet, vertex, vertexPosition, verticesOfEdge, wire, wireLoop, wiresOfFace };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { N as getOrQueryType, R as DisposalScope, Y as _usingCtx, Z as getKernel, r as castShapeWithKnownType, t as castShape } from "./shapeTypes-
|
|
1
|
+
import { N as getOrQueryType, R as DisposalScope, Y as _usingCtx, Z as getKernel, r as castShapeWithKnownType, t as castShape } from "./shapeTypes-DUC23pOr.js";
|
|
2
2
|
import { A as ok, b as err, f as getSuggestionForCode, p as translateKernelError } from "./errors-BJSTLaDI.js";
|
|
3
3
|
//#region src/core/kernelCall.ts
|
|
4
4
|
function buildError(kind, code, message, cause, suggestion) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-q3dLIqqs.cjs");
|
|
2
2
|
const require_errors = require("./errors-DxoD7zgx.cjs");
|
|
3
3
|
//#region src/core/kernelCall.ts
|
|
4
4
|
function buildError(kind, code, message, cause, suggestion) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "brepjs",
|
|
3
|
-
"version": "18.
|
|
3
|
+
"version": "18.29.0",
|
|
4
4
|
"description": "Web CAD library with pluggable geometry kernel",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"cad",
|
|
@@ -248,7 +248,7 @@
|
|
|
248
248
|
"@types/opentype.js": "1.3.9",
|
|
249
249
|
"@vitest/coverage-v8": "4.1.6",
|
|
250
250
|
"brepjs-opencascade": "*",
|
|
251
|
-
"brepkit-wasm": "2.
|
|
251
|
+
"brepkit-wasm": "2.99.0",
|
|
252
252
|
"eslint": "10.4.0",
|
|
253
253
|
"fast-check": "4.8.0",
|
|
254
254
|
"husky": "9.1.7",
|