功能:导出ClipperCpp初始化函数
This commit is contained in:
24
api.esm.js
24
api.esm.js
@@ -8,8 +8,9 @@ import Flatbush from 'flatbush';
|
||||
import geom3 from '@jscad/modeling/src/geometries/geom3';
|
||||
import { intersect } from '@jscad/modeling/src/operations/booleans';
|
||||
import { create } from '@jscad/modeling/src/geometries/poly3';
|
||||
import { observable } from 'mobx';
|
||||
import * as clipperLib from 'js-angusj-clipper/web';
|
||||
import { JoinType, EndType } from 'js-angusj-clipper/web';
|
||||
import { observable } from 'mobx';
|
||||
import polylabel from 'polylabel';
|
||||
|
||||
/******************************************************************************
|
||||
@@ -21177,6 +21178,23 @@ function EntitysUpdateWrap(ens, exec) {
|
||||
}
|
||||
}
|
||||
|
||||
let clipperCpp = {};
|
||||
function InitClipperCpp() {
|
||||
if (clipperCpp.lib)
|
||||
return;
|
||||
if (!globalThis.document)
|
||||
globalThis.document = {};
|
||||
return new Promise((res, rej) => {
|
||||
clipperLib.loadNativeClipperLibInstanceAsync(
|
||||
// let it autodetect which one to use, but also available WasmOnly and AsmJsOnly
|
||||
clipperLib.NativeClipperLibRequestedFormat.AsmJsOnly).then(c => {
|
||||
clipperCpp.lib = c;
|
||||
res();
|
||||
// console.log("载入成功!");//不再需要
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
let CreateObjectData = class CreateObjectData extends CADObject {
|
||||
/**
|
||||
* 如果是实体新建,那么不需要调用`Save`,历史记录会在命令结束的时候调用.
|
||||
@@ -34480,8 +34498,6 @@ class GetArcParam {
|
||||
}
|
||||
}
|
||||
|
||||
let clipperCpp = {};
|
||||
|
||||
//点表面积
|
||||
function Area(pts) {
|
||||
let cnt = pts.length;
|
||||
@@ -36185,5 +36201,5 @@ function UpdateStartEndPoint(curve) {
|
||||
curve.EndPoint = ep;
|
||||
}
|
||||
|
||||
export { AlignedDimension, AllObjectData, AmbientLight, Arc, ArcDimension, AxisCS, BlockTable, BlockTableRecord, Board, BoxSolid, CADFactory, CADFiler, CURVE_FACE_TYPE_KEY, CURVE_MESH_NAMES, CameraSnapshootRecord, CameraType, CameraUpdate, Circle, CommandHistoryRecord, CompositeEntity, ContourTreeNode, ConverBoardTypeToSpaceType, CreateObjectData, Curve, CurveTapeShape, CylinderHole, Cylineder, Database, DepthType, DiameterDimension, Dimension, DirectionalLight, DisposeTextShapeCache, Ellipse, Entity, EntityColorHistoryRecord, EntityRef, EraseEntityData, ExtendType$1 as ExtendType, ExtrudeBuildConfig, ExtrudeGeometryBuilder, ExtrudeHole, ExtrudeSolid, FaceEntity, Factory, FastDrillingEdgeGeometry, FastDrillingMeshGeometry, FastMeshGeometry, GangDrillType, GetBoxGeoBufferGeometry, Groove, GroupRecord, GroupTable, HardwareCompositeEntity, HardwareTopline, HemisphereLight, HistoricManage, HistorycRecord, Hole, Light, Line, LineAngularDimension, LinearDimension, MaterialTableRecord, MaxDrawGrooveCount, ObjectAllDataHistoryRecord, ObjectCollection, PhysicalMaterialRecord, Point, PointLight, Polyline, Positioning, PositioningBoardSpace, PositioningClampSpace, PositioningTemporary, ProcessingGroupRecord, ProcessingGroupTable, RadiusDimension, RectAreaLight, Region, RemoveObjectData, RenderType, RevolveSolid, RoomBase, RoomFlatBase, RoomFlatFloor, RoomFlatTop, RoomHoleBase, RoomHoleLine, RoomHolePolyline, RoomRegion, RoomWallArc, RoomWallBase, RoomWallLine, RoomWallParse, Shape2, Spline, SpotLight, SubtractRange, SubtractRange2, SweepSolid, SymbolTable, Tape, TempPolyline$1 as TempPolyline, TempateDefaultParamCount, TempateThicknessAction, TemplateAction, TemplateBehindBoard, TemplateBoardRecord, TemplateFilletAction, TemplateLatticeRecord, TemplateLayerBoard, TemplateLeftRightBoardRecord, TemplateMoveAction, TemplateParam, TemplateRecord, TemplateSizeBoard, TemplateStretchGripAction, TemplateStretchScaleBoxAction, TemplateTable, TemplateTopBottomBoard, TemplateVerticalBoard, TemplateVisualSpace, TemplateWineRackRecord, Text, TextAligen, TextureTable, TextureTableRecord, ThicknessDirection, UVType, UpdateTempPolyline, ViewportEntity, ViewportEntity2, VisualSpaceBox, WallFaceType, applyMixins, boardUVGenerator, boardUVGenerator2 };
|
||||
export { AlignedDimension, AllObjectData, AmbientLight, Arc, ArcDimension, AxisCS, BlockTable, BlockTableRecord, Board, BoxSolid, CADFactory, CADFiler, CURVE_FACE_TYPE_KEY, CURVE_MESH_NAMES, CameraSnapshootRecord, CameraType, CameraUpdate, Circle, CommandHistoryRecord, CompositeEntity, ContourTreeNode, ConverBoardTypeToSpaceType, CreateObjectData, Curve, CurveTapeShape, CylinderHole, Cylineder, Database, DepthType, DiameterDimension, Dimension, DirectionalLight, DisposeTextShapeCache, Ellipse, Entity, EntityColorHistoryRecord, EntityRef, EraseEntityData, ExtendType$1 as ExtendType, ExtrudeBuildConfig, ExtrudeGeometryBuilder, ExtrudeHole, ExtrudeSolid, FaceEntity, Factory, FastDrillingEdgeGeometry, FastDrillingMeshGeometry, FastMeshGeometry, GangDrillType, GetBoxGeoBufferGeometry, Groove, GroupRecord, GroupTable, HardwareCompositeEntity, HardwareTopline, HemisphereLight, HistoricManage, HistorycRecord, Hole, InitClipperCpp, Light, Line, LineAngularDimension, LinearDimension, MaterialTableRecord, MaxDrawGrooveCount, ObjectAllDataHistoryRecord, ObjectCollection, PhysicalMaterialRecord, Point, PointLight, Polyline, Positioning, PositioningBoardSpace, PositioningClampSpace, PositioningTemporary, ProcessingGroupRecord, ProcessingGroupTable, RadiusDimension, RectAreaLight, Region, RemoveObjectData, RenderType, RevolveSolid, RoomBase, RoomFlatBase, RoomFlatFloor, RoomFlatTop, RoomHoleBase, RoomHoleLine, RoomHolePolyline, RoomRegion, RoomWallArc, RoomWallBase, RoomWallLine, RoomWallParse, Shape2, Spline, SpotLight, SubtractRange, SubtractRange2, SweepSolid, SymbolTable, Tape, TempPolyline$1 as TempPolyline, TempateDefaultParamCount, TempateThicknessAction, TemplateAction, TemplateBehindBoard, TemplateBoardRecord, TemplateFilletAction, TemplateLatticeRecord, TemplateLayerBoard, TemplateLeftRightBoardRecord, TemplateMoveAction, TemplateParam, TemplateRecord, TemplateSizeBoard, TemplateStretchGripAction, TemplateStretchScaleBoxAction, TemplateTable, TemplateTopBottomBoard, TemplateVerticalBoard, TemplateVisualSpace, TemplateWineRackRecord, Text, TextAligen, TextureTable, TextureTableRecord, ThicknessDirection, UVType, UpdateTempPolyline, ViewportEntity, ViewportEntity2, VisualSpaceBox, WallFaceType, applyMixins, boardUVGenerator, boardUVGenerator2, clipperCpp };
|
||||
//# sourceMappingURL=api.esm.js.map
|
||||
|
Reference in New Issue
Block a user