brepjs 18.75.1 → 18.77.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/README.md +22 -22
- package/dist/2d.cjs +6 -6
- package/dist/2d.js +6 -6
- package/dist/{blueprint-DiaBfB57.cjs → blueprint-BE93BNYE.cjs} +5 -5
- package/dist/{blueprint-OgMkiq7a.js → blueprint-BVe9JU-L.js} +5 -5
- package/dist/{blueprintFns-uYr43qo4.cjs → blueprintFns-B_7kKwEZ.cjs} +2 -2
- package/dist/{blueprintFns-C3EQ12Ix.js → blueprintFns-DWinspVK.js} +2 -2
- package/dist/{blueprintSketcher-CZqT7_gf.cjs → blueprintSketcher-D75tuXkF.cjs} +3 -3
- package/dist/{blueprintSketcher-Bp3oMzVW.js → blueprintSketcher-DL-wgnVs.js} +3 -3
- package/dist/{boolean2D-4fXjKx5f.cjs → boolean2D-C4Txi8U1.cjs} +4 -4
- package/dist/{boolean2D-DXti_c7k.js → boolean2D-OtHT7POp.js} +4 -4
- package/dist/{booleanFns-DxnTjP19.cjs → booleanFns-CFa3bgbG.cjs} +4 -4
- package/dist/{booleanFns-Cu-J1THp.js → booleanFns-D7Xgt-Og.js} +4 -4
- package/dist/brepjs.cjs +32 -25
- package/dist/brepjs.js +32 -26
- package/dist/{cameraFns-Ctxe8ev-.js → cameraFns-DCXqzH_m.js} +2 -2
- package/dist/{cameraFns-G2lc5c9M.cjs → cameraFns-DfSRnD1k.cjs} +2 -2
- package/dist/core.cjs +1 -1
- package/dist/core.js +1 -1
- package/dist/{cornerFinder-CmXx269_.js → cornerFinder-DPkLU1Of.js} +1 -1
- package/dist/{cornerFinder-CAoT1uIs.cjs → cornerFinder-KuLU-4pQ.cjs} +1 -1
- package/dist/{curveFns-C7t4yHtQ.js → curveFns-B4KEYU1M.js} +60 -2
- package/dist/{curveFns-DQlllRhs.cjs → curveFns-C0oCmjV2.cjs} +65 -1
- package/dist/{drawFns-B7l3h4FX.js → drawFns-BBoTkSta.js} +12 -12
- package/dist/{drawFns-SddAG_uY.cjs → drawFns-DNokXs9U.cjs} +12 -12
- package/dist/{extrudeFns-b7JHaMsv.cjs → extrudeFns-BJSW3EaV.cjs} +1 -1
- package/dist/{extrudeFns-msxcCUm2.js → extrudeFns-CSWqlW-n.js} +1 -1
- package/dist/{faceFns-BJ0mbRh5.js → faceFns-BJ2hzXJp.js} +2 -2
- package/dist/{faceFns-CZvemlPW.cjs → faceFns-p0lyVuyw.cjs} +2 -2
- package/dist/{helpers-CYSAsvRe.js → helpers-C78MY-s6.js} +6 -6
- package/dist/{helpers-CRBTGZO7.cjs → helpers-DTBDjbdR.cjs} +6 -6
- package/dist/{historyFns-xUNAdUYV.cjs → historyFns-4ggYGJB2.cjs} +4 -4
- package/dist/{historyFns-BV5sQxft.js → historyFns-Ck2tXVAL.js} +4 -4
- package/dist/{importFns-BY0rgGAN.cjs → importFns-CUAiLgt_.cjs} +2 -2
- package/dist/{importFns-eHSyuIJF.js → importFns-Rv22QSn6.js} +2 -2
- package/dist/index.d.ts +1 -1
- package/dist/io.cjs +2 -2
- package/dist/io.js +2 -2
- package/dist/kernel/occt/geometryQueryOps.d.ts +5 -1
- package/dist/kernel/occtWasm/occtWasmAdapter.cjs +1 -1
- package/dist/kernel/occtWasm/occtWasmAdapter.js +1 -1
- package/dist/kernel/occtWasm/surfaceOps.d.ts +5 -1
- package/dist/{measureFns-DYeTPyHr.js → measureFns-C8c6xRUE.js} +3 -3
- package/dist/{measureFns-CRS3U8gj.cjs → measureFns-DnxobCbD.cjs} +3 -3
- package/dist/measurement.cjs +1 -1
- package/dist/measurement.js +1 -1
- package/dist/{meshFns-CvmTzMPL.cjs → meshFns-BawS1xNA.cjs} +3 -3
- package/dist/{meshFns-CLQL2D95.js → meshFns-CuYzpojl.js} +3 -3
- package/dist/{occtWasmAdapter-m4Nua92H.js → occtWasmAdapter-BrTkhQYK.js} +83 -6
- package/dist/{occtWasmAdapter-DdghAlnN.cjs → occtWasmAdapter-W86SRBpi.cjs} +83 -6
- package/dist/operations.cjs +2 -2
- package/dist/operations.js +2 -2
- package/dist/{primitiveFns-B6Q6lx9-.js → primitiveFns-DWIzRvTY.js} +7 -7
- package/dist/{primitiveFns-FudrSXrp.cjs → primitiveFns-ItlGYe3M.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-CQmd2W5F.cjs → shapeFns-D5WNrq3s.cjs} +2 -2
- package/dist/{shapeFns-CQRGTifg.js → shapeFns-DZ6poxP7.js} +2 -2
- package/dist/shapeRef.cjs +1 -1
- package/dist/shapeRef.js +1 -1
- package/dist/{shapeRefFns-DoPplxoN.cjs → shapeRefFns-BOWP8n4j.cjs} +4 -4
- package/dist/{shapeRefFns-DvIvS0do.js → shapeRefFns-ClsyeZp4.js} +4 -4
- package/dist/{shapeTypes-C4cMKLoj.cjs → shapeTypes-CxSqNvHA.cjs} +55 -26
- package/dist/{shapeTypes-VCBsDI43.js → shapeTypes-CyTY0prh.js} +55 -26
- package/dist/sketching.cjs +3 -3
- package/dist/sketching.js +3 -3
- package/dist/{solidBuilders-DBsHetmI.js → solidBuilders-BtEFUFQ9.js} +2 -2
- package/dist/{solidBuilders-B0Hzin8a.cjs → solidBuilders-diw2zyyN.cjs} +2 -2
- package/dist/{surfaceBuilders-QK_Cnn_u.cjs → surfaceBuilders-CPHOXRLE.cjs} +2 -2
- package/dist/{surfaceBuilders-DllH3kXs.js → surfaceBuilders-Do0rypyD.js} +2 -2
- package/dist/text.cjs +2 -2
- package/dist/text.js +2 -2
- package/dist/{textBlueprints-C9ne8G24.js → textBlueprints-CYc0xi6l.js} +7 -7
- package/dist/{textBlueprints-BxbCj29U.cjs → textBlueprints-D31dKTZS.cjs} +7 -7
- package/dist/{textMetrics-DRfvY1yT.cjs → textMetrics-CjbXCzpg.cjs} +1 -1
- package/dist/{textMetrics-Ddpxhy0z.js → textMetrics-DfxB-y9A.js} +1 -1
- package/dist/topology/curveFns.d.ts +12 -0
- package/dist/topology/index.d.ts +1 -1
- package/dist/topology.cjs +8 -7
- package/dist/topology.d.ts +1 -1
- package/dist/topology.js +8 -8
- package/dist/{topologyQueryFns-BtfhAVY2.js → topologyQueryFns-BomrmBie.js} +1 -1
- package/dist/{topologyQueryFns-Bj5wpC75.cjs → topologyQueryFns-Dzxrwn-E.cjs} +1 -1
- package/package.json +1 -1
|
@@ -1842,13 +1842,90 @@ function deriveCylinder(k, face) {
|
|
|
1842
1842
|
isDirect: (shapeOrientation(k, face) === "reversed" ? -1 : 1) * dotV(n1, subV(p1, origin)) > 0
|
|
1843
1843
|
};
|
|
1844
1844
|
}
|
|
1845
|
-
/**
|
|
1845
|
+
/** Circumcenter of three points (the center of the unique circle through them). */
|
|
1846
|
+
function circumcenter(a, p, q) {
|
|
1847
|
+
const ab = subV(p, a);
|
|
1848
|
+
const ac = subV(q, a);
|
|
1849
|
+
const m = crossV(ab, ac);
|
|
1850
|
+
const mSq = dotV(m, m);
|
|
1851
|
+
if (mSq < 1e-18) return null;
|
|
1852
|
+
const abSq = dotV(ab, ab);
|
|
1853
|
+
const acSq = dotV(ac, ac);
|
|
1854
|
+
const dxm = crossV([
|
|
1855
|
+
abSq * ac[0] - acSq * ab[0],
|
|
1856
|
+
abSq * ac[1] - acSq * ab[1],
|
|
1857
|
+
abSq * ac[2] - acSq * ab[2]
|
|
1858
|
+
], m);
|
|
1859
|
+
const inv = 1 / (2 * mSq);
|
|
1860
|
+
return [
|
|
1861
|
+
a[0] + dxm[0] * inv,
|
|
1862
|
+
a[1] + dxm[1] * inv,
|
|
1863
|
+
a[2] + dxm[2] * inv
|
|
1864
|
+
];
|
|
1865
|
+
}
|
|
1866
|
+
/** Center of the iso-v circle at height v (three u-samples → circumcenter). */
|
|
1867
|
+
function isoCircleCenter(k, face, uMin, uMax, v) {
|
|
1868
|
+
return circumcenter(pointOnSurface(k, face, uMin + .1 * (uMax - uMin), v), pointOnSurface(k, face, uMin + .45 * (uMax - uMin), v), pointOnSurface(k, face, uMin + .8 * (uMax - uMin), v));
|
|
1869
|
+
}
|
|
1870
|
+
/**
|
|
1871
|
+
* Axis of a surface of revolution (cone, torus, general revolution) by sampling.
|
|
1872
|
+
* occt-wasm exposes no analytic accessor for these. Their U parameter is the
|
|
1873
|
+
* angle of revolution, so the iso-v curve at a fixed v is a circle centered on
|
|
1874
|
+
* the axis; two such centers at different heights span the axis.
|
|
1875
|
+
*
|
|
1876
|
+
* Samples three v-levels and uses the farthest-apart pair of centers. Two levels
|
|
1877
|
+
* suffice for a cone or general revolution (v is monotonic along the axis), but
|
|
1878
|
+
* a torus parameterizes v as the tube angle: on a v-symmetric partial torus (a
|
|
1879
|
+
* half-torus, v in [0, pi]) two symmetric samples land at equal heights and
|
|
1880
|
+
* their centers coincide. A third level breaks that symmetry. Avoids the v
|
|
1881
|
+
* extremes so a cone apex (a degenerate zero-radius circle) is not sampled.
|
|
1882
|
+
*/
|
|
1883
|
+
function deriveAxisBySampling(k, face) {
|
|
1884
|
+
const b = uvBounds(k, face);
|
|
1885
|
+
const centers = [
|
|
1886
|
+
.2,
|
|
1887
|
+
.5,
|
|
1888
|
+
.8
|
|
1889
|
+
].map((f) => isoCircleCenter(k, face, b.uMin, b.uMax, b.vMin + f * (b.vMax - b.vMin))).filter((c) => c !== null);
|
|
1890
|
+
if (centers.length < 2) return null;
|
|
1891
|
+
let best = null;
|
|
1892
|
+
let bestLen = 1e-9;
|
|
1893
|
+
for (let i = 0; i < centers.length; i++) for (let j = i + 1; j < centers.length; j++) {
|
|
1894
|
+
const ci = centers[i];
|
|
1895
|
+
const cj = centers[j];
|
|
1896
|
+
if (!ci || !cj) continue;
|
|
1897
|
+
const d = subV(cj, ci);
|
|
1898
|
+
const len = lenV(d);
|
|
1899
|
+
if (len > bestLen) {
|
|
1900
|
+
bestLen = len;
|
|
1901
|
+
best = {
|
|
1902
|
+
origin: ci,
|
|
1903
|
+
direction: [
|
|
1904
|
+
d[0] / len,
|
|
1905
|
+
d[1] / len,
|
|
1906
|
+
d[2] / len
|
|
1907
|
+
]
|
|
1908
|
+
};
|
|
1909
|
+
}
|
|
1910
|
+
}
|
|
1911
|
+
return best;
|
|
1912
|
+
}
|
|
1913
|
+
/**
|
|
1914
|
+
* Axis of symmetry (point on axis + unit direction) for an analytic face that
|
|
1915
|
+
* has one. Cylinders use the exact normal-cross derivation; cones, tori, and
|
|
1916
|
+
* surfaces of revolution fall back to circle-center sampling. Null otherwise.
|
|
1917
|
+
*/
|
|
1846
1918
|
function getSurfaceAxis(k, face) {
|
|
1847
|
-
const
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1919
|
+
const type = surfaceType(k, face);
|
|
1920
|
+
if (type === "cylinder") {
|
|
1921
|
+
const cyl = deriveCylinder(k, face);
|
|
1922
|
+
return cyl ? {
|
|
1923
|
+
origin: cyl.origin,
|
|
1924
|
+
direction: cyl.direction
|
|
1925
|
+
} : null;
|
|
1926
|
+
}
|
|
1927
|
+
if (type === "cone" || type === "torus" || type === "revolution") return deriveAxisBySampling(k, face);
|
|
1928
|
+
return null;
|
|
1852
1929
|
}
|
|
1853
1930
|
/** Cylinder radius + handedness for a cylindrical surface. Null for non-cylinders. */
|
|
1854
1931
|
function getSurfaceCylinderData(k, surface) {
|
package/dist/operations.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_historyFns = require("./historyFns-
|
|
3
|
-
const require_extrudeFns = require("./extrudeFns-
|
|
2
|
+
const require_historyFns = require("./historyFns-4ggYGJB2.cjs");
|
|
3
|
+
const require_extrudeFns = require("./extrudeFns-BJSW3EaV.cjs");
|
|
4
4
|
exports.addChild = require_historyFns.addChild;
|
|
5
5
|
exports.addStep = require_historyFns.addStep;
|
|
6
6
|
exports.circularPattern = require_historyFns.circularPattern;
|
package/dist/operations.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { C as walkAssembly, D as exportAssemblySTEP, E as linearPattern, O as createAssembly, S as updateNode, T as gridPattern, _ as collectShapes, a as findStep, b as findNode, c as registerOperation, d as replayHistory, g as addChild, h as undoLast, l as registerShape, m as stepsFrom, n as createHistory, o as getShape, p as stepCount, r as createRegistry, s as modifyStep, t as addStep, u as replayFrom, v as countNodes, w as circularPattern, x as removeChild, y as createAssemblyNode } from "./historyFns-
|
|
2
|
-
import { c as sweep, i as complexExtrude, l as twistExtrude, s as supportExtrude } from "./extrudeFns-
|
|
1
|
+
import { C as walkAssembly, D as exportAssemblySTEP, E as linearPattern, O as createAssembly, S as updateNode, T as gridPattern, _ as collectShapes, a as findStep, b as findNode, c as registerOperation, d as replayHistory, g as addChild, h as undoLast, l as registerShape, m as stepsFrom, n as createHistory, o as getShape, p as stepCount, r as createRegistry, s as modifyStep, t as addStep, u as replayFrom, v as countNodes, w as circularPattern, x as removeChild, y as createAssemblyNode } from "./historyFns-Ck2tXVAL.js";
|
|
2
|
+
import { c as sweep, i as complexExtrude, l as twistExtrude, s as supportExtrude } from "./extrudeFns-CSWqlW-n.js";
|
|
3
3
|
export { addChild, addStep, circularPattern, collectShapes, complexExtrude, countNodes, createAssembly, createAssemblyNode, createHistory, createRegistry, exportAssemblySTEP, findNode, findStep, getShape as getHistoryShape, gridPattern, linearPattern, modifyStep, registerOperation, registerShape, removeChild, replayFrom, replayHistory, stepCount, stepsFrom, supportExtrude, sweep, twistExtrude, undoLast, updateNode, walkAssembly };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { Z as getKernel, _ as isSolid, c as createSolid, h as isShape3D, p as isFace, r as castShapeWithKnownType, t as castShape, x as isClosedWire, y as isWire } from "./shapeTypes-
|
|
1
|
+
import { Z as getKernel, _ as isSolid, c as createSolid, h as isShape3D, p as isFace, r as castShapeWithKnownType, t as castShape, x as isClosedWire, y as isWire } from "./shapeTypes-CyTY0prh.js";
|
|
2
2
|
import { A as ok, T as isOk, b as err, d as validationError, i as kernelError, l as typeCastError, t as BrepErrorCode, v as andThen, w as isErr } from "./errors-DNWJsfVU.js";
|
|
3
|
-
import { c as getFaces, i as getCachedIsValid, l as getOrCreateCache, m as invalidateShapeCache, p as getWires, s as getEdges } from "./topologyQueryFns-
|
|
3
|
+
import { c as getFaces, i as getCachedIsValid, l as getOrCreateCache, m as invalidateShapeCache, p as getWires, s as getEdges } from "./topologyQueryFns-BomrmBie.js";
|
|
4
4
|
import { n as HASH_CODE_MAX, t as DEG2RAD } from "./constants-ITRzCnCp.js";
|
|
5
|
-
import { v as downcast } from "./faceFns-
|
|
6
|
-
import { _ as propagateAllMetadata, g as collectInputFaceHashes, h as translate } from "./shapeFns-
|
|
5
|
+
import { v as downcast } from "./faceFns-BJ2hzXJp.js";
|
|
6
|
+
import { _ as propagateAllMetadata, g as collectInputFaceHashes, h as translate } from "./shapeFns-DZ6poxP7.js";
|
|
7
7
|
import { t as firstOrThrow } from "./arrayAccess-DrUGPADn.js";
|
|
8
|
-
import { _ as makeThreePointArc, a as makeNonPlanarFace, c as makeBSplineApproximation, d as makeCircle, f as makeEllipse, g as makeTangentArc, h as makeLine, i as makeNewFaceWithinFace, m as makeHelix, o as makePolygon, p as makeEllipseArc, r as makeFace, s as assembleWire, t as addHolesInFace, u as makeBezierCurve } from "./surfaceBuilders-
|
|
9
|
-
import { a as fuseAll, i as fuse, n as cut, r as cutAll } from "./booleanFns-
|
|
10
|
-
import { a as makeOffset, c as makeTorus, i as makeEllipsoid, l as makeVertex, n as makeCone, o as makeSolid, r as makeCylinder, s as makeSphere, t as makeCompound, u as weldShellsAndFaces } from "./solidBuilders-
|
|
8
|
+
import { _ as makeThreePointArc, a as makeNonPlanarFace, c as makeBSplineApproximation, d as makeCircle, f as makeEllipse, g as makeTangentArc, h as makeLine, i as makeNewFaceWithinFace, m as makeHelix, o as makePolygon, p as makeEllipseArc, r as makeFace, s as assembleWire, t as addHolesInFace, u as makeBezierCurve } from "./surfaceBuilders-Do0rypyD.js";
|
|
9
|
+
import { a as fuseAll, i as fuse, n as cut, r as cutAll } from "./booleanFns-D7Xgt-Og.js";
|
|
10
|
+
import { a as makeOffset, c as makeTorus, i as makeEllipsoid, l as makeVertex, n as makeCone, o as makeSolid, r as makeCylinder, s as makeSphere, t as makeCompound, u as weldShellsAndFaces } from "./solidBuilders-BtEFUFQ9.js";
|
|
11
11
|
//#region src/topology/threeHelpers.ts
|
|
12
12
|
/**
|
|
13
13
|
* Convert a ShapeMesh into BufferGeometry-compatible typed arrays.
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-CxSqNvHA.cjs");
|
|
2
2
|
const require_errors = require("./errors-CXJtc4I7.cjs");
|
|
3
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
3
|
+
const require_topologyQueryFns = require("./topologyQueryFns-Dzxrwn-E.cjs");
|
|
4
4
|
const require_constants = require("./constants-BOVyEYGH.cjs");
|
|
5
|
-
const require_faceFns = require("./faceFns-
|
|
6
|
-
const require_shapeFns = require("./shapeFns-
|
|
5
|
+
const require_faceFns = require("./faceFns-p0lyVuyw.cjs");
|
|
6
|
+
const require_shapeFns = require("./shapeFns-D5WNrq3s.cjs");
|
|
7
7
|
const require_arrayAccess = require("./arrayAccess-e4H9cBfh.cjs");
|
|
8
|
-
const require_surfaceBuilders = require("./surfaceBuilders-
|
|
9
|
-
const require_booleanFns = require("./booleanFns-
|
|
10
|
-
const require_solidBuilders = require("./solidBuilders-
|
|
8
|
+
const require_surfaceBuilders = require("./surfaceBuilders-CPHOXRLE.cjs");
|
|
9
|
+
const require_booleanFns = require("./booleanFns-CFa3bgbG.cjs");
|
|
10
|
+
const require_solidBuilders = require("./solidBuilders-diw2zyyN.cjs");
|
|
11
11
|
//#region src/topology/threeHelpers.ts
|
|
12
12
|
/**
|
|
13
13
|
* Convert a ShapeMesh into BufferGeometry-compatible typed arrays.
|
package/dist/projection.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_cameraFns = require("./cameraFns-
|
|
2
|
+
const require_cameraFns = require("./cameraFns-DfSRnD1k.cjs");
|
|
3
3
|
exports.PROJECTION_PLANES = require_cameraFns.PROJECTION_PLANES;
|
|
4
4
|
exports.cameraFromPlane = require_cameraFns.cameraFromPlane;
|
|
5
5
|
exports.cameraLookAt = require_cameraFns.cameraLookAt;
|
package/dist/projection.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as makeProjectedEdges, i as projectEdges, n as cameraLookAt, o as PROJECTION_PLANES, r as createCamera, s as isProjectionPlane, t as cameraFromPlane } from "./cameraFns-
|
|
1
|
+
import { a as makeProjectedEdges, i as projectEdges, n as cameraLookAt, o as PROJECTION_PLANES, r as createCamera, s as isProjectionPlane, t as cameraFromPlane } from "./cameraFns-DCXqzH_m.js";
|
|
2
2
|
export { PROJECTION_PLANES, cameraFromPlane, cameraLookAt, createCamera, isProjectionPlane, makeProjectedEdges, projectEdges };
|
package/dist/query.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_helpers = require("./helpers-
|
|
3
|
-
const require_cornerFinder = require("./cornerFinder-
|
|
2
|
+
const require_helpers = require("./helpers-DTBDjbdR.cjs");
|
|
3
|
+
const require_cornerFinder = require("./cornerFinder-KuLU-4pQ.cjs");
|
|
4
4
|
exports.cornerFinder = require_cornerFinder.cornerFinder;
|
|
5
5
|
exports.edgeFinder = require_helpers.edgeFinder;
|
|
6
6
|
exports.faceFinder = require_helpers.faceFinder;
|
package/dist/query.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { n as edgeFinder, r as faceFinder, t as getSingleFace } from "./helpers-
|
|
2
|
-
import { t as cornerFinder } from "./cornerFinder-
|
|
1
|
+
import { n as edgeFinder, r as faceFinder, t as getSingleFace } from "./helpers-C78MY-s6.js";
|
|
2
|
+
import { t as cornerFinder } from "./cornerFinder-DPkLU1Of.js";
|
|
3
3
|
export { cornerFinder, edgeFinder, faceFinder, getSingleFace };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
const require_shapeTypes = require("./shapeTypes-
|
|
1
|
+
const require_shapeTypes = require("./shapeTypes-CxSqNvHA.cjs");
|
|
2
2
|
const require_errors = require("./errors-CXJtc4I7.cjs");
|
|
3
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
3
|
+
const require_topologyQueryFns = require("./topologyQueryFns-Dzxrwn-E.cjs");
|
|
4
4
|
const require_constants = require("./constants-BOVyEYGH.cjs");
|
|
5
5
|
//#region src/topology/metadata/originTrackingFns.ts
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { Z as getKernel, t as castShape } from "./shapeTypes-
|
|
1
|
+
import { Z as getKernel, t as castShape } from "./shapeTypes-CyTY0prh.js";
|
|
2
2
|
import { A as ok, b as err, d as validationError, t as BrepErrorCode } from "./errors-DNWJsfVU.js";
|
|
3
|
-
import { C as kernelCall, c as getFaces, l as getOrCreateCache, r as getCacheEntry, w as kernelCallRaw } from "./topologyQueryFns-
|
|
3
|
+
import { C as kernelCall, c as getFaces, l as getOrCreateCache, r as getCacheEntry, w as kernelCallRaw } from "./topologyQueryFns-BomrmBie.js";
|
|
4
4
|
import { n as HASH_CODE_MAX, t as DEG2RAD } from "./constants-ITRzCnCp.js";
|
|
5
5
|
//#region src/topology/metadata/originTrackingFns.ts
|
|
6
6
|
/**
|
package/dist/shapeRef.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_shapeRefFns = require("./shapeRefFns-
|
|
2
|
+
const require_shapeRefFns = require("./shapeRefFns-BOWP8n4j.cjs");
|
|
3
3
|
exports.assignRoles = require_shapeRefFns.assignRoles;
|
|
4
4
|
exports.captureHint = require_shapeRefFns.captureHint;
|
|
5
5
|
exports.createRef = require_shapeRefFns.createRef;
|
package/dist/shapeRef.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as updateRoles, i as resolveRef, n as captureHint, o as defaultScorer, r as createRef, t as assignRoles } from "./shapeRefFns-
|
|
1
|
+
import { a as updateRoles, i as resolveRef, n as captureHint, o as defaultScorer, r as createRef, t as assignRoles } from "./shapeRefFns-ClsyeZp4.js";
|
|
2
2
|
export { assignRoles, captureHint, createRef, defaultScorer, resolveRef, updateRoles };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
const require_vec3 = require("./vec3-CFwOI0ZI.cjs");
|
|
2
|
-
const require_topologyQueryFns = require("./topologyQueryFns-
|
|
3
|
-
const require_faceFns = require("./faceFns-
|
|
4
|
-
const require_shapeFns = require("./shapeFns-
|
|
5
|
-
const require_measureFns = require("./measureFns-
|
|
2
|
+
const require_topologyQueryFns = require("./topologyQueryFns-Dzxrwn-E.cjs");
|
|
3
|
+
const require_faceFns = require("./faceFns-p0lyVuyw.cjs");
|
|
4
|
+
const require_shapeFns = require("./shapeFns-D5WNrq3s.cjs");
|
|
5
|
+
const require_measureFns = require("./measureFns-DnxobCbD.cjs");
|
|
6
6
|
//#region src/topology/shapeRef/scoring.ts
|
|
7
7
|
/**
|
|
8
8
|
* Default face scorer combining surface type, normal alignment, centroid proximity,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { n as wasmIndex } from "./vec3-Dpha8d5k.js";
|
|
2
|
-
import { c as getFaces } from "./topologyQueryFns-
|
|
3
|
-
import { i as faceGeomType, l as normalAt, r as faceCenter } from "./faceFns-
|
|
4
|
-
import { n as getHashCode } from "./shapeFns-
|
|
5
|
-
import { n as measureArea } from "./measureFns-
|
|
2
|
+
import { c as getFaces } from "./topologyQueryFns-BomrmBie.js";
|
|
3
|
+
import { i as faceGeomType, l as normalAt, r as faceCenter } from "./faceFns-BJ2hzXJp.js";
|
|
4
|
+
import { n as getHashCode } from "./shapeFns-DZ6poxP7.js";
|
|
5
|
+
import { n as measureArea } from "./measureFns-C8c6xRUE.js";
|
|
6
6
|
//#region src/topology/shapeRef/scoring.ts
|
|
7
7
|
/**
|
|
8
8
|
* Default face scorer combining surface type, normal alignment, centroid proximity,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_occtWasmAdapter = require("./occtWasmAdapter-
|
|
1
|
+
const require_occtWasmAdapter = require("./occtWasmAdapter-W86SRBpi.cjs");
|
|
2
2
|
const require_vec3 = require("./vec3-CFwOI0ZI.cjs");
|
|
3
3
|
const require_errors = require("./errors-CXJtc4I7.cjs");
|
|
4
4
|
//#region src/kernel/quality.ts
|
|
@@ -2886,33 +2886,61 @@ function getSurfaceCylinderData$1(oc, surface) {
|
|
|
2886
2886
|
adaptor.delete();
|
|
2887
2887
|
return result;
|
|
2888
2888
|
}
|
|
2889
|
-
/**
|
|
2889
|
+
/**
|
|
2890
|
+
* Extract the `gp_Ax1` axis of an analytic surface adaptor by type index, or
|
|
2891
|
+
* null. GeomAbs_SurfaceType: 1 = Cylinder, 2 = Cone, 4 = Torus, 7 =
|
|
2892
|
+
* SurfaceOfRevolution. gp_Cone / gp_Torus are not bound in the shipped
|
|
2893
|
+
* opencascade.js build, so their accessors throw; that is treated as "no axis".
|
|
2894
|
+
*/
|
|
2895
|
+
function surfaceAxisAx1(adaptor, typeIdx) {
|
|
2896
|
+
let prim = null;
|
|
2897
|
+
try {
|
|
2898
|
+
if (typeIdx === 7) return adaptor.AxeOfRevolution();
|
|
2899
|
+
if (typeIdx === 1) prim = adaptor.Cylinder();
|
|
2900
|
+
else if (typeIdx === 2) prim = adaptor.Cone();
|
|
2901
|
+
else if (typeIdx === 4) prim = adaptor.Torus();
|
|
2902
|
+
else return null;
|
|
2903
|
+
const axis = prim.Axis();
|
|
2904
|
+
prim.delete();
|
|
2905
|
+
return axis;
|
|
2906
|
+
} catch {
|
|
2907
|
+
prim?.delete?.();
|
|
2908
|
+
return null;
|
|
2909
|
+
}
|
|
2910
|
+
}
|
|
2911
|
+
/**
|
|
2912
|
+
* Get the axis of symmetry (point on axis + unit direction) for an analytic
|
|
2913
|
+
* face that has one: cylinder, cone, torus, or surface of revolution. Null
|
|
2914
|
+
* otherwise (plane, sphere, free-form).
|
|
2915
|
+
*/
|
|
2890
2916
|
function getSurfaceAxis$1(oc, face) {
|
|
2891
2917
|
const adaptor = new oc.BRepAdaptor_Surface_2(face, false);
|
|
2892
2918
|
try {
|
|
2893
2919
|
const typeVal = adaptor.GetType();
|
|
2894
|
-
|
|
2895
|
-
|
|
2896
|
-
|
|
2897
|
-
|
|
2898
|
-
|
|
2899
|
-
|
|
2900
|
-
|
|
2901
|
-
|
|
2902
|
-
|
|
2903
|
-
|
|
2904
|
-
|
|
2905
|
-
|
|
2906
|
-
|
|
2907
|
-
|
|
2908
|
-
|
|
2909
|
-
|
|
2910
|
-
|
|
2911
|
-
|
|
2912
|
-
|
|
2913
|
-
|
|
2914
|
-
|
|
2915
|
-
|
|
2920
|
+
const axis = surfaceAxisAx1(adaptor, typeof typeVal === "number" ? typeVal : Number(typeVal?.value ?? typeVal));
|
|
2921
|
+
if (!axis) return null;
|
|
2922
|
+
let loc = null;
|
|
2923
|
+
let dir = null;
|
|
2924
|
+
try {
|
|
2925
|
+
loc = axis.Location();
|
|
2926
|
+
dir = axis.Direction();
|
|
2927
|
+
return {
|
|
2928
|
+
origin: [
|
|
2929
|
+
loc.X(),
|
|
2930
|
+
loc.Y(),
|
|
2931
|
+
loc.Z()
|
|
2932
|
+
],
|
|
2933
|
+
direction: [
|
|
2934
|
+
dir.X(),
|
|
2935
|
+
dir.Y(),
|
|
2936
|
+
dir.Z()
|
|
2937
|
+
]
|
|
2938
|
+
};
|
|
2939
|
+
} finally {
|
|
2940
|
+
loc?.delete?.();
|
|
2941
|
+
dir?.delete?.();
|
|
2942
|
+
axis.delete();
|
|
2943
|
+
}
|
|
2916
2944
|
} finally {
|
|
2917
2945
|
adaptor.delete();
|
|
2918
2946
|
}
|
|
@@ -6022,8 +6050,9 @@ function getSurfaceCylinderData(bk, surface) {
|
|
|
6022
6050
|
}
|
|
6023
6051
|
function getSurfaceAxis(bk, face) {
|
|
6024
6052
|
const params = JSON.parse(bk.getAnalyticSurfaceParams(unwrap$1(face, "face")));
|
|
6025
|
-
|
|
6026
|
-
|
|
6053
|
+
const point = params.type === "cylinder" ? params.origin : params.type === "cone" ? params.apex : null;
|
|
6054
|
+
if (!point || !params.axis) return null;
|
|
6055
|
+
const [ox, oy, oz] = point;
|
|
6027
6056
|
const [ax, ay, az] = params.axis;
|
|
6028
6057
|
const len = Math.hypot(ax, ay, az);
|
|
6029
6058
|
if (len < 1e-12) return null;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { C as translateCurve2d$2, E as EXACT_BREP_CAPABILITIES, S as tangentCurve2d, _ as mirrorAcrossAxis, a as buildBinarySTL, b as scaleCurve2d$2, c as curveBounds, d as evaluateCurve2d$2, f as intersectCurves2dFn, g as makeLine2d$2, h as makeEllipse2d$2, i as buildAsciiSTL, l as curveTypeName, m as makeCircle2d$2, n as DEFAULT_STL_ANGULAR_TOLERANCE, o as addCurveToBBox, p as makeBezier2d$2, r as DEFAULT_STL_TOLERANCE, s as createBBox2d, t as OcctWasmAdapter, u as deserializeCurve2d$2, v as mirrorAtPoint, w as quickHull, x as serializeCurve2d$2, y as rotateCurve2d$2 } from "./occtWasmAdapter-
|
|
1
|
+
import { C as translateCurve2d$2, E as EXACT_BREP_CAPABILITIES, S as tangentCurve2d, _ as mirrorAcrossAxis, a as buildBinarySTL, b as scaleCurve2d$2, c as curveBounds, d as evaluateCurve2d$2, f as intersectCurves2dFn, g as makeLine2d$2, h as makeEllipse2d$2, i as buildAsciiSTL, l as curveTypeName, m as makeCircle2d$2, n as DEFAULT_STL_ANGULAR_TOLERANCE, o as addCurveToBBox, p as makeBezier2d$2, r as DEFAULT_STL_TOLERANCE, s as createBBox2d, t as OcctWasmAdapter, u as deserializeCurve2d$2, v as mirrorAtPoint, w as quickHull, x as serializeCurve2d$2, y as rotateCurve2d$2 } from "./occtWasmAdapter-BrTkhQYK.js";
|
|
2
2
|
import { n as wasmIndex, t as vec3At } from "./vec3-Dpha8d5k.js";
|
|
3
3
|
import { A as ok, b as err } from "./errors-DNWJsfVU.js";
|
|
4
4
|
//#region src/kernel/quality.ts
|
|
@@ -2886,33 +2886,61 @@ function getSurfaceCylinderData$1(oc, surface) {
|
|
|
2886
2886
|
adaptor.delete();
|
|
2887
2887
|
return result;
|
|
2888
2888
|
}
|
|
2889
|
-
/**
|
|
2889
|
+
/**
|
|
2890
|
+
* Extract the `gp_Ax1` axis of an analytic surface adaptor by type index, or
|
|
2891
|
+
* null. GeomAbs_SurfaceType: 1 = Cylinder, 2 = Cone, 4 = Torus, 7 =
|
|
2892
|
+
* SurfaceOfRevolution. gp_Cone / gp_Torus are not bound in the shipped
|
|
2893
|
+
* opencascade.js build, so their accessors throw; that is treated as "no axis".
|
|
2894
|
+
*/
|
|
2895
|
+
function surfaceAxisAx1(adaptor, typeIdx) {
|
|
2896
|
+
let prim = null;
|
|
2897
|
+
try {
|
|
2898
|
+
if (typeIdx === 7) return adaptor.AxeOfRevolution();
|
|
2899
|
+
if (typeIdx === 1) prim = adaptor.Cylinder();
|
|
2900
|
+
else if (typeIdx === 2) prim = adaptor.Cone();
|
|
2901
|
+
else if (typeIdx === 4) prim = adaptor.Torus();
|
|
2902
|
+
else return null;
|
|
2903
|
+
const axis = prim.Axis();
|
|
2904
|
+
prim.delete();
|
|
2905
|
+
return axis;
|
|
2906
|
+
} catch {
|
|
2907
|
+
prim?.delete?.();
|
|
2908
|
+
return null;
|
|
2909
|
+
}
|
|
2910
|
+
}
|
|
2911
|
+
/**
|
|
2912
|
+
* Get the axis of symmetry (point on axis + unit direction) for an analytic
|
|
2913
|
+
* face that has one: cylinder, cone, torus, or surface of revolution. Null
|
|
2914
|
+
* otherwise (plane, sphere, free-form).
|
|
2915
|
+
*/
|
|
2890
2916
|
function getSurfaceAxis$1(oc, face) {
|
|
2891
2917
|
const adaptor = new oc.BRepAdaptor_Surface_2(face, false);
|
|
2892
2918
|
try {
|
|
2893
2919
|
const typeVal = adaptor.GetType();
|
|
2894
|
-
|
|
2895
|
-
|
|
2896
|
-
|
|
2897
|
-
|
|
2898
|
-
|
|
2899
|
-
|
|
2900
|
-
|
|
2901
|
-
|
|
2902
|
-
|
|
2903
|
-
|
|
2904
|
-
|
|
2905
|
-
|
|
2906
|
-
|
|
2907
|
-
|
|
2908
|
-
|
|
2909
|
-
|
|
2910
|
-
|
|
2911
|
-
|
|
2912
|
-
|
|
2913
|
-
|
|
2914
|
-
|
|
2915
|
-
|
|
2920
|
+
const axis = surfaceAxisAx1(adaptor, typeof typeVal === "number" ? typeVal : Number(typeVal?.value ?? typeVal));
|
|
2921
|
+
if (!axis) return null;
|
|
2922
|
+
let loc = null;
|
|
2923
|
+
let dir = null;
|
|
2924
|
+
try {
|
|
2925
|
+
loc = axis.Location();
|
|
2926
|
+
dir = axis.Direction();
|
|
2927
|
+
return {
|
|
2928
|
+
origin: [
|
|
2929
|
+
loc.X(),
|
|
2930
|
+
loc.Y(),
|
|
2931
|
+
loc.Z()
|
|
2932
|
+
],
|
|
2933
|
+
direction: [
|
|
2934
|
+
dir.X(),
|
|
2935
|
+
dir.Y(),
|
|
2936
|
+
dir.Z()
|
|
2937
|
+
]
|
|
2938
|
+
};
|
|
2939
|
+
} finally {
|
|
2940
|
+
loc?.delete?.();
|
|
2941
|
+
dir?.delete?.();
|
|
2942
|
+
axis.delete();
|
|
2943
|
+
}
|
|
2916
2944
|
} finally {
|
|
2917
2945
|
adaptor.delete();
|
|
2918
2946
|
}
|
|
@@ -6018,8 +6046,9 @@ function getSurfaceCylinderData(bk, surface) {
|
|
|
6018
6046
|
}
|
|
6019
6047
|
function getSurfaceAxis(bk, face) {
|
|
6020
6048
|
const params = JSON.parse(bk.getAnalyticSurfaceParams(unwrap$1(face, "face")));
|
|
6021
|
-
|
|
6022
|
-
|
|
6049
|
+
const point = params.type === "cylinder" ? params.origin : params.type === "cone" ? params.apex : null;
|
|
6050
|
+
if (!point || !params.axis) return null;
|
|
6051
|
+
const [ox, oy, oz] = point;
|
|
6023
6052
|
const [ax, ay, az] = params.axis;
|
|
6024
6053
|
const len = Math.hypot(ax, ay, az);
|
|
6025
6054
|
if (len < 1e-12) return null;
|
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-D31dKTZS.cjs");
|
|
3
|
+
const require_blueprintSketcher = require("./blueprintSketcher-D75tuXkF.cjs");
|
|
4
|
+
const require_drawFns = require("./drawFns-DNokXs9U.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-DL-wgnVs.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-BBoTkSta.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-CYc0xi6l.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
|
-
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-CyTY0prh.js";
|
|
2
2
|
import { A as ok, R as unwrap, b as err, l as typeCastError, v as andThen } from "./errors-DNWJsfVU.js";
|
|
3
|
-
import { _ as cast, v as downcast } from "./faceFns-
|
|
3
|
+
import { _ as cast, v as downcast } from "./faceFns-BJ2hzXJp.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-CxSqNvHA.cjs");
|
|
2
2
|
const require_errors = require("./errors-CXJtc4I7.cjs");
|
|
3
|
-
const require_faceFns = require("./faceFns-
|
|
3
|
+
const require_faceFns = require("./faceFns-p0lyVuyw.cjs");
|
|
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-CxSqNvHA.cjs");
|
|
2
2
|
const require_errors = require("./errors-CXJtc4I7.cjs");
|
|
3
|
-
const require_faceFns = require("./faceFns-
|
|
3
|
+
const require_faceFns = require("./faceFns-p0lyVuyw.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-CyTY0prh.js";
|
|
2
2
|
import { A as ok, b as err, d as validationError, i as kernelError, v as andThen } from "./errors-DNWJsfVU.js";
|
|
3
|
-
import { _ as cast, u as outerWire } from "./faceFns-
|
|
3
|
+
import { _ as cast, u as outerWire } from "./faceFns-BJ2hzXJp.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-D31dKTZS.cjs");
|
|
3
|
+
const require_textMetrics = require("./textMetrics-CjbXCzpg.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-CYc0xi6l.js";
|
|
2
|
+
import { n as textMetrics, r as sketchText, t as fontMetrics } from "./textMetrics-DfxB-y9A.js";
|
|
3
3
|
export { fontMetrics, getFont, loadFont, sketchText, textBlueprints, textMetrics };
|
|
@@ -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-CyTY0prh.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-DNWJsfVU.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-DSjjtrjg.js";
|
|
6
|
-
import { _ as cast, v as downcast } from "./faceFns-
|
|
7
|
-
import {
|
|
6
|
+
import { _ as cast, v as downcast } from "./faceFns-BJ2hzXJp.js";
|
|
7
|
+
import { l as curveStartPoint, u as curveTangentAt } from "./curveFns-B4KEYU1M.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-Do0rypyD.js";
|
|
10
|
+
import { r as organiseBlueprints, t as BlueprintSketcher } from "./blueprintSketcher-DL-wgnVs.js";
|
|
11
|
+
import { o as makeSolid, t as makeCompound } from "./solidBuilders-BtEFUFQ9.js";
|
|
12
|
+
import { c as sweep, i as complexExtrude, l as twistExtrude, r as revolve, t as extrude } from "./extrudeFns-CSWqlW-n.js";
|
|
13
13
|
import opentype from "opentype.js";
|
|
14
14
|
//#region src/operations/loftFns.ts
|
|
15
15
|
/**
|
|
@@ -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-CxSqNvHA.cjs");
|
|
33
33
|
const require_errors = require("./errors-CXJtc4I7.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-BA4HfgQu.cjs");
|
|
37
|
-
const require_faceFns = require("./faceFns-
|
|
38
|
-
const require_curveFns = require("./curveFns-
|
|
37
|
+
const require_faceFns = require("./faceFns-p0lyVuyw.cjs");
|
|
38
|
+
const require_curveFns = require("./curveFns-C0oCmjV2.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-CPHOXRLE.cjs");
|
|
41
|
+
const require_blueprintSketcher = require("./blueprintSketcher-D75tuXkF.cjs");
|
|
42
|
+
const require_solidBuilders = require("./solidBuilders-diw2zyyN.cjs");
|
|
43
|
+
const require_extrudeFns = require("./extrudeFns-BJSW3EaV.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,5 +1,5 @@
|
|
|
1
1
|
import { A as ok, b as err, d as validationError, t as BrepErrorCode } from "./errors-DNWJsfVU.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-CYc0xi6l.js";
|
|
3
3
|
//#region src/text/sketchText.ts
|
|
4
4
|
/**
|
|
5
5
|
* Render text as 3D sketch outlines on a plane.
|