@x-viewer/core 0.9.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 +2 -0
- package/dist/index.esm.js +11790 -0
- package/dist/types/Locale.d.ts +23 -0
- package/dist/types/components/dxf-layout-bar/DxfLayoutBar.d.ts +26 -0
- package/dist/types/components/dxf-layout-bar/index.d.ts +1 -0
- package/dist/types/components/tool-tip/Tooltip.d.ts +20 -0
- package/dist/types/components/tool-tip/index.d.ts +1 -0
- package/dist/types/core/Configs.d.ts +288 -0
- package/dist/types/core/Constants.d.ts +81 -0
- package/dist/types/core/Units.d.ts +16 -0
- package/dist/types/core/VersionManager.d.ts +14 -0
- package/dist/types/core/camera/CameraManager.d.ts +80 -0
- package/dist/types/core/camera/index.d.ts +1 -0
- package/dist/types/core/camera-controls/CameraControls.d.ts +744 -0
- package/dist/types/core/camera-controls/Constants.d.ts +2 -0
- package/dist/types/core/camera-controls/EventDispatcher.d.ts +41 -0
- package/dist/types/core/camera-controls/index.d.ts +3 -0
- package/dist/types/core/camera-controls/types.d.ts +112 -0
- package/dist/types/core/camera-controls/utils/extractClientCoordFromEvent.d.ts +3 -0
- package/dist/types/core/camera-controls/utils/math-utils.d.ts +14 -0
- package/dist/types/core/camera-controls/utils/notSupportedInOrthographicCamera.d.ts +2 -0
- package/dist/types/core/canvas/CanvasRender.d.ts +52 -0
- package/dist/types/core/canvas/Constants.d.ts +31 -0
- package/dist/types/core/canvas/Drawable.d.ts +98 -0
- package/dist/types/core/canvas/DrawableList.d.ts +40 -0
- package/dist/types/core/canvas/MarkerDrawable.d.ts +30 -0
- package/dist/types/core/canvas/PathDrawable.d.ts +39 -0
- package/dist/types/core/canvas/index.d.ts +6 -0
- package/dist/types/core/compare/BaseDxfCompareHelper.d.ts +104 -0
- package/dist/types/core/compare/CompareDrawable.d.ts +18 -0
- package/dist/types/core/compare/DxfCompareHelper.d.ts +69 -0
- package/dist/types/core/compare/DxfCompareMarkupManager.d.ts +11 -0
- package/dist/types/core/compare/index.d.ts +4 -0
- package/dist/types/core/components/Container.d.ts +38 -0
- package/dist/types/core/components/ProgressBar.d.ts +31 -0
- package/dist/types/core/components/Spinner.d.ts +16 -0
- package/dist/types/core/components/index.d.ts +3 -0
- package/dist/types/core/controls/CameraControlsEx.d.ts +37 -0
- package/dist/types/core/controls/Control.d.ts +17 -0
- package/dist/types/core/controls/OrbitControls.d.ts +13 -0
- package/dist/types/core/controls/PlanControls.d.ts +13 -0
- package/dist/types/core/controls/index.d.ts +4 -0
- package/dist/types/core/dxf/DxfCompare.d.ts +151 -0
- package/dist/types/core/dxf/DxfConstants.d.ts +33 -0
- package/dist/types/core/dxf/DxfLoader.d.ts +557 -0
- package/dist/types/core/dxf/DxfObject.d.ts +33 -0
- package/dist/types/core/dxf/DxfUtils.d.ts +45 -0
- package/dist/types/core/dxf/HatchPatternShaders.d.ts +12 -0
- package/dist/types/core/dxf/LinePatternShaders.d.ts +12 -0
- package/dist/types/core/dxf/bspline.d.ts +7 -0
- package/dist/types/core/dxf/dxfom-mtext.d.ts +46 -0
- package/dist/types/core/dxf/dxfom-text.d.ts +16 -0
- package/dist/types/core/dxf/index.d.ts +10 -0
- package/dist/types/core/dxf/round10.d.ts +1 -0
- package/dist/types/core/dxf-parser/AutoCadColorIndex.d.ts +8 -0
- package/dist/types/core/dxf-parser/DxfBaseReader.d.ts +12 -0
- package/dist/types/core/dxf-parser/DxfBinaryReader.d.ts +14 -0
- package/dist/types/core/dxf-parser/DxfParser.d.ts +324 -0
- package/dist/types/core/dxf-parser/DxfTextReader.d.ts +31 -0
- package/dist/types/core/dxf-parser/ParseHelpers.d.ts +45 -0
- package/dist/types/core/dxf-parser/entities/3dface.d.ts +13 -0
- package/dist/types/core/dxf-parser/entities/arc.d.ts +18 -0
- package/dist/types/core/dxf-parser/entities/attdef.d.ts +33 -0
- package/dist/types/core/dxf-parser/entities/attrib.d.ts +33 -0
- package/dist/types/core/dxf-parser/entities/circle.d.ts +15 -0
- package/dist/types/core/dxf-parser/entities/dimension.d.ts +24 -0
- package/dist/types/core/dxf-parser/entities/ellipse.d.ts +17 -0
- package/dist/types/core/dxf-parser/entities/geomtry.d.ts +42 -0
- package/dist/types/core/dxf-parser/entities/hatch.d.ts +110 -0
- package/dist/types/core/dxf-parser/entities/image.d.ts +39 -0
- package/dist/types/core/dxf-parser/entities/insert.d.ts +22 -0
- package/dist/types/core/dxf-parser/entities/leader.d.ts +23 -0
- package/dist/types/core/dxf-parser/entities/line.d.ts +12 -0
- package/dist/types/core/dxf-parser/entities/lwpolyline.d.ts +23 -0
- package/dist/types/core/dxf-parser/entities/mleader.d.ts +103 -0
- package/dist/types/core/dxf-parser/entities/mtext.d.ts +20 -0
- package/dist/types/core/dxf-parser/entities/ole2frame.d.ts +22 -0
- package/dist/types/core/dxf-parser/entities/point.d.ts +13 -0
- package/dist/types/core/dxf-parser/entities/polyline.d.ts +22 -0
- package/dist/types/core/dxf-parser/entities/ray.d.ts +12 -0
- package/dist/types/core/dxf-parser/entities/region.d.ts +12 -0
- package/dist/types/core/dxf-parser/entities/seqend.d.ts +10 -0
- package/dist/types/core/dxf-parser/entities/solid.d.ts +12 -0
- package/dist/types/core/dxf-parser/entities/spline.d.ts +25 -0
- package/dist/types/core/dxf-parser/entities/table.d.ts +44 -0
- package/dist/types/core/dxf-parser/entities/text.d.ts +20 -0
- package/dist/types/core/dxf-parser/entities/vertex.d.ts +22 -0
- package/dist/types/core/dxf-parser/entities/viewport.d.ts +56 -0
- package/dist/types/core/dxf-parser/entities/xline.d.ts +12 -0
- package/dist/types/core/dxf-parser/index.d.ts +27 -0
- package/dist/types/core/dxf-parser/objects/common.d.ts +26 -0
- package/dist/types/core/dxf-parser/objects/dictionary.d.ts +23 -0
- package/dist/types/core/dxf-parser/objects/imagedef.d.ts +24 -0
- package/dist/types/core/dxf-parser/objects/layout.d.ts +29 -0
- package/dist/types/core/dxf-parser/objects/sortentstable.d.ts +12 -0
- package/dist/types/core/dxf-parser/objects/spatialfilter.d.ts +22 -0
- package/dist/types/core/dxf-parser/objects/xrecord.d.ts +11 -0
- package/dist/types/core/effect/EffectManager.d.ts +43 -0
- package/dist/types/core/effect/index.d.ts +1 -0
- package/dist/types/core/font/BaseFont.d.ts +41 -0
- package/dist/types/core/font/FontManager.d.ts +52 -0
- package/dist/types/core/font/MeshFont.d.ts +14 -0
- package/dist/types/core/font/ShxFont.d.ts +49 -0
- package/dist/types/core/font/index.d.ts +1 -0
- package/dist/types/core/font/shx/ExtraLettersTemplate.d.ts +4 -0
- package/dist/types/core/font/shx/Shx.constants.d.ts +20 -0
- package/dist/types/core/font/shx/ShxParser.d.ts +18 -0
- package/dist/types/core/font/shx/TextShape.d.ts +24 -0
- package/dist/types/core/font/shx/gbk/index.d.ts +4 -0
- package/dist/types/core/font/shx/index.d.ts +1 -0
- package/dist/types/core/font/shx/util/BitConverter.d.ts +18 -0
- package/dist/types/core/geometry-offset/Edge.d.ts +27 -0
- package/dist/types/core/geometry-offset/Offset.d.ts +46 -0
- package/dist/types/core/geometry-offset/index.d.ts +1 -0
- package/dist/types/core/helpers/BinaryReader.d.ts +23 -0
- package/dist/types/core/helpers/BoxSelectHelper.d.ts +44 -0
- package/dist/types/core/helpers/InstantiateHelper.d.ts +26 -0
- package/dist/types/core/helpers/LoadingHelper.d.ts +65 -0
- package/dist/types/core/helpers/MeshBvhHelper.d.ts +15 -0
- package/dist/types/core/helpers/MobileTouchHelperDrawable.d.ts +26 -0
- package/dist/types/core/helpers/OSnapHelper.d.ts +159 -0
- package/dist/types/core/helpers/ObjectPixelSizeHelper.d.ts +13 -0
- package/dist/types/core/helpers/PickMarkupHelper.d.ts +29 -0
- package/dist/types/core/helpers/RafHelper.d.ts +18 -0
- package/dist/types/core/helpers/ZoomToRectHelper.d.ts +20 -0
- package/dist/types/core/helpers/index.d.ts +11 -0
- package/dist/types/core/index.d.ts +24 -0
- package/dist/types/core/indexeddb/BaseTable.d.ts +36 -0
- package/dist/types/core/indexeddb/DxfDataTable.d.ts +22 -0
- package/dist/types/core/indexeddb/FontDataTable.d.ts +32 -0
- package/dist/types/core/indexeddb/IndexedDbManager.d.ts +49 -0
- package/dist/types/core/indexeddb/index.d.ts +4 -0
- package/dist/types/core/input-manager/InputManager.d.ts +147 -0
- package/dist/types/core/input-manager/index.d.ts +1 -0
- package/dist/types/core/interactions/Interaction.d.ts +10 -0
- package/dist/types/core/interactions/Viewer2dInteraction.d.ts +17 -0
- package/dist/types/core/interactions/Viewer3dInteraction.d.ts +26 -0
- package/dist/types/core/interactions/index.d.ts +1 -0
- package/dist/types/core/materials/BimTilesHighlightMaterial.d.ts +21 -0
- package/dist/types/core/materials/BimTilesMaterial.d.ts +26 -0
- package/dist/types/core/materials/BimTilesPickMaterial.d.ts +9 -0
- package/dist/types/core/materials/BimTilesTransparentMaterial.d.ts +20 -0
- package/dist/types/core/materials/StandardMaterialEx.d.ts +16 -0
- package/dist/types/core/materials/constants.d.ts +0 -0
- package/dist/types/core/materials/index.d.ts +5 -0
- package/dist/types/core/model/Constants.d.ts +58 -0
- package/dist/types/core/model/Model.d.ts +18 -0
- package/dist/types/core/model/Model2d.d.ts +142 -0
- package/dist/types/core/model/Model3d.d.ts +137 -0
- package/dist/types/core/model/bimtiles/BatchedMeshesParser.d.ts +26 -0
- package/dist/types/core/model/bimtiles/BimTilesConfigParser.d.ts +43 -0
- package/dist/types/core/model/bimtiles/BimTilesData.d.ts +280 -0
- package/dist/types/core/model/bimtiles/BimTilesMaterialManager.d.ts +139 -0
- package/dist/types/core/model/bimtiles/BimTilesModel.d.ts +67 -0
- package/dist/types/core/model/bimtiles/BimTilesPropertyParser.d.ts +42 -0
- package/dist/types/core/model/bimtiles/BimTilesRenderer.d.ts +49 -0
- package/dist/types/core/model/bimtiles/InstancedMeshesParser.d.ts +37 -0
- package/dist/types/core/model/bimtiles/TileParser.d.ts +11 -0
- package/dist/types/core/model/bimtiles/Utils.d.ts +29 -0
- package/dist/types/core/model/index.d.ts +6 -0
- package/dist/types/core/patches/Constants.d.ts +6 -0
- package/dist/types/core/patches/Line.d.ts +2 -0
- package/dist/types/core/patches/Mesh.d.ts +2 -0
- package/dist/types/core/patches/Points.d.ts +2 -0
- package/dist/types/core/patches/index.d.ts +4 -0
- package/dist/types/core/patches/shaders/ShaderChunk.d.ts +2 -0
- package/dist/types/core/patches/shaders/shaderChunk/common_ex.glsl.d.ts +2 -0
- package/dist/types/core/patches/shaders/shaderChunk/id_pars_vertex.glsl.d.ts +2 -0
- package/dist/types/core/patches/shaders/shaderChunk/id_vertex.glsl.d.ts +2 -0
- package/dist/types/core/patches/shaders/shaderChunk/outine_bc_vertex.glsl.d.ts +2 -0
- package/dist/types/core/patches/shaders/shaderChunk/outline_bc_fragment.glsl.d.ts +2 -0
- package/dist/types/core/patches/shaders/shaderChunk/outline_bc_pars_fragment.glsl.d.ts +2 -0
- package/dist/types/core/patches/shaders/shaderChunk/outline_bc_pars_vertex.glsl.d.ts +2 -0
- package/dist/types/core/patches/shaders/shaderChunk/state_fragment.glsl.d.ts +2 -0
- package/dist/types/core/patches/shaders/shaderChunk/state_highlight_fragment.glsl.d.ts +2 -0
- package/dist/types/core/patches/shaders/shaderChunk/state_pars_fragment.glsl.d.ts +2 -0
- package/dist/types/core/patches/shaders/shaderChunk/state_transparent_fragment.glsl.d.ts +2 -0
- package/dist/types/core/patches/shaders/shaderLib/pick_ex.glsl.d.ts +2 -0
- package/dist/types/core/patches/shaders/shaderLib/standard_ex.glsl.d.ts +2 -0
- package/dist/types/core/pick/PickManager.d.ts +52 -0
- package/dist/types/core/pick/index.d.ts +1 -0
- package/dist/types/core/scene/SceneManager.d.ts +48 -0
- package/dist/types/core/scene/index.d.ts +1 -0
- package/dist/types/core/shp-js/BitView.d.ts +12 -0
- package/dist/types/core/shp-js/SHPLoader.d.ts +12 -0
- package/dist/types/core/shp-js/Shp.d.ts +10 -0
- package/dist/types/core/shp-js/ShpThree.d.ts +23 -0
- package/dist/types/core/shp-js/index.d.ts +4 -0
- package/dist/types/core/text-texture/TextTexture.d.ts +45 -0
- package/dist/types/core/text-texture/index.d.ts +1 -0
- package/dist/types/core/undo/Command.d.ts +6 -0
- package/dist/types/core/undo/UndoManager.d.ts +24 -0
- package/dist/types/core/undo/index.d.ts +2 -0
- package/dist/types/core/utils/CSS2DObjectUtils.d.ts +14 -0
- package/dist/types/core/utils/CancelablePromise.d.ts +6 -0
- package/dist/types/core/utils/ColorUtils.d.ts +25 -0
- package/dist/types/core/utils/CommonUtils.d.ts +141 -0
- package/dist/types/core/utils/CoordinateUtils.d.ts +81 -0
- package/dist/types/core/utils/DecimalPrecisionUtils.d.ts +10 -0
- package/dist/types/core/utils/DeviceUtils.d.ts +15 -0
- package/dist/types/core/utils/EdgeUtils.d.ts +14 -0
- package/dist/types/core/utils/Event.d.ts +33 -0
- package/dist/types/core/utils/ExportUtils.d.ts +61 -0
- package/dist/types/core/utils/FpsUtils.d.ts +13 -0
- package/dist/types/core/utils/GeometryUtils.d.ts +78 -0
- package/dist/types/core/utils/LodashUtils.d.ts +208 -0
- package/dist/types/core/utils/LogUtils.d.ts +29 -0
- package/dist/types/core/utils/MaterialUtils.d.ts +40 -0
- package/dist/types/core/utils/MathUtils.d.ts +41 -0
- package/dist/types/core/utils/MergeUtils.d.ts +126 -0
- package/dist/types/core/utils/ObjectUtils.d.ts +216 -0
- package/dist/types/core/utils/PolygonUtils.d.ts +9 -0
- package/dist/types/core/utils/SVGObjectUtils.d.ts +22 -0
- package/dist/types/core/utils/SceneUtils.d.ts +26 -0
- package/dist/types/core/utils/SectionUtils.d.ts +11 -0
- package/dist/types/core/utils/SimplifyUtils.d.ts +15 -0
- package/dist/types/core/utils/TextureUtils.d.ts +16 -0
- package/dist/types/core/utils/UVUtils.d.ts +21 -0
- package/dist/types/core/utils/UnitConversionUtils.d.ts +31 -0
- package/dist/types/core/utils/index.d.ts +26 -0
- package/dist/types/core/viewers/BaseViewer.d.ts +253 -0
- package/dist/types/core/viewers/BimTilesViewer.d.ts +130 -0
- package/dist/types/core/viewers/Constants.d.ts +9 -0
- package/dist/types/core/viewers/Plugin.d.ts +30 -0
- package/dist/types/core/viewers/Viewer2d.d.ts +413 -0
- package/dist/types/core/viewers/Viewer3d.d.ts +136 -0
- package/dist/types/core/viewers/Viewer3dLite.d.ts +144 -0
- package/dist/types/core/viewers/ViewerEvent.d.ts +108 -0
- package/dist/types/core/viewers/index.d.ts +8 -0
- package/dist/types/core/webcam/WebCam.d.ts +28 -0
- package/dist/types/core/webcam/index.d.ts +1 -0
- package/dist/types/core/workers/CreateMeshBvh.worker.d.ts +1 -0
- package/dist/types/core/workers/GenerateMeshBvhWorker.d.ts +17 -0
- package/dist/types/core/workers/index.d.ts +1 -0
- package/dist/types/export.doc.d.ts +9 -0
- package/dist/types/index.d.ts +23 -0
- package/dist/types/version.d.ts +2 -0
- package/package.json +88 -0
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { DwgEntity } from "@mlightcad/libredwg-web";
|
|
2
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
3
|
+
/**
|
|
4
|
+
* @internal
|
|
5
|
+
*/
|
|
6
|
+
export interface IPoint {
|
|
7
|
+
x: number;
|
|
8
|
+
y: number;
|
|
9
|
+
z?: number;
|
|
10
|
+
bulge?: number;
|
|
11
|
+
}
|
|
12
|
+
export interface IEntity {
|
|
13
|
+
lineType: string;
|
|
14
|
+
layer: string;
|
|
15
|
+
lineTypeScale: number;
|
|
16
|
+
visible: boolean;
|
|
17
|
+
colorIndex: number;
|
|
18
|
+
color: number;
|
|
19
|
+
isTrueColor: boolean;
|
|
20
|
+
inPaperSpace: boolean;
|
|
21
|
+
layoutName: string;
|
|
22
|
+
ownerHandle: string;
|
|
23
|
+
materialObjectHandle: string;
|
|
24
|
+
lineweight: 0 | 5 | 9 | 13 | 15 | 18 | 20 | 25 | 30 | 35 | 40 | 50 | 53 | 60 | 70 | 80 | 90 | 100 | 106 | 120 | 140 | 158 | 200 | 211 | -3 | -2 | -1;
|
|
25
|
+
extendedData?: {
|
|
26
|
+
customStrings?: string[];
|
|
27
|
+
applicationName?: string;
|
|
28
|
+
originalHandle?: string;
|
|
29
|
+
originalType?: string;
|
|
30
|
+
outlines?: number[][][];
|
|
31
|
+
};
|
|
32
|
+
type: string;
|
|
33
|
+
handle: string;
|
|
34
|
+
blockPosition?: IPoint;
|
|
35
|
+
attributesFollow?: boolean;
|
|
36
|
+
}
|
|
37
|
+
export type EntityName = "POINT" | "3DFACE" | "ARC" | "ATTDEF" | "ATTRIB" | "CIRCLE" | "DIMENSION" | "MULTILEADER" | "ELLIPSE" | "HATCH" | "IMAGE" | "INSERT" | "LEADER" | "LINE" | "LWPOLYLINE" | "MTEXT" | "OLE2FRAME" | "POLYLINE" | "REGION" | "RAY" | "SEQEND" | "SOLID" | "SPLINE" | "ACAD_TABLE" | "TEXT" | "VERTEX" | "VIEWPORT" | "XLINE";
|
|
38
|
+
export default interface IGeometry {
|
|
39
|
+
ForEntityName: EntityName;
|
|
40
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): IEntity;
|
|
41
|
+
parseDwgEntity(entity: DwgEntity): IEntity;
|
|
42
|
+
}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { DwgHatchEntity } from "@mlightcad/libredwg-web";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from "./geomtry";
|
|
3
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
4
|
+
export declare enum HatchBoundaryPathTypeFlag {
|
|
5
|
+
Default = 0,
|
|
6
|
+
External = 1,
|
|
7
|
+
Polyline = 2,
|
|
8
|
+
Derived = 4,
|
|
9
|
+
Textbox = 8,
|
|
10
|
+
Outermost = 16,
|
|
11
|
+
MaxFlags = 31
|
|
12
|
+
}
|
|
13
|
+
export declare enum HatchEdgeType {
|
|
14
|
+
Polyline = 0,
|
|
15
|
+
Line = 1,
|
|
16
|
+
Arc = 2,
|
|
17
|
+
Ellipse = 3,
|
|
18
|
+
Spline = 4
|
|
19
|
+
}
|
|
20
|
+
export declare abstract class HatchEdge {
|
|
21
|
+
readonly type: HatchEdgeType;
|
|
22
|
+
startPoint: IPoint;
|
|
23
|
+
endPoint: IPoint;
|
|
24
|
+
constructor(type: HatchEdgeType);
|
|
25
|
+
}
|
|
26
|
+
export declare class HatchPolyline extends HatchEdge {
|
|
27
|
+
points: IPoint[];
|
|
28
|
+
isClosed: boolean;
|
|
29
|
+
constructor();
|
|
30
|
+
}
|
|
31
|
+
export declare class HatchLine extends HatchEdge {
|
|
32
|
+
constructor();
|
|
33
|
+
}
|
|
34
|
+
export declare class HatchArc extends HatchEdge {
|
|
35
|
+
center: IPoint;
|
|
36
|
+
radius: number;
|
|
37
|
+
startAngle: number;
|
|
38
|
+
endAngle: number;
|
|
39
|
+
bCounterclockwise: boolean;
|
|
40
|
+
constructor();
|
|
41
|
+
}
|
|
42
|
+
export declare class HatchEllipse extends HatchEdge {
|
|
43
|
+
center: IPoint;
|
|
44
|
+
majorAxisEndPoint: IPoint;
|
|
45
|
+
minorRatio: number;
|
|
46
|
+
startAngle: number;
|
|
47
|
+
endAngle: number;
|
|
48
|
+
bCounterclockwise: boolean;
|
|
49
|
+
constructor();
|
|
50
|
+
}
|
|
51
|
+
export declare class HatchSpline extends HatchEdge {
|
|
52
|
+
controlPoints: IPoint[];
|
|
53
|
+
numControlPoints: number;
|
|
54
|
+
knotValues: number[];
|
|
55
|
+
numKnots: number;
|
|
56
|
+
bPeriodic: boolean;
|
|
57
|
+
bRational: boolean;
|
|
58
|
+
degreeOfSplineCurve: number;
|
|
59
|
+
constructor();
|
|
60
|
+
}
|
|
61
|
+
export interface IHatchBoundaryPath {
|
|
62
|
+
edges: HatchEdge[];
|
|
63
|
+
pathTypeFlag: HatchBoundaryPathTypeFlag;
|
|
64
|
+
}
|
|
65
|
+
export declare enum HatchStyle {
|
|
66
|
+
Normal = 0,
|
|
67
|
+
Outer = 1,
|
|
68
|
+
Ignore = 2
|
|
69
|
+
}
|
|
70
|
+
export declare enum HatchType {
|
|
71
|
+
UserDefined = 0,
|
|
72
|
+
Predefined = 1,
|
|
73
|
+
Custom = 2
|
|
74
|
+
}
|
|
75
|
+
export interface IHatchPatternLine {
|
|
76
|
+
angle: number;
|
|
77
|
+
origin: IPoint;
|
|
78
|
+
delta: IPoint;
|
|
79
|
+
dashPattern: number[];
|
|
80
|
+
}
|
|
81
|
+
export interface IHatchEntity extends IEntity {
|
|
82
|
+
elevationX: number;
|
|
83
|
+
elevationY: number;
|
|
84
|
+
elevationZ: number;
|
|
85
|
+
pixelSize: number;
|
|
86
|
+
associativity: boolean;
|
|
87
|
+
annotatedBoundary: boolean;
|
|
88
|
+
boundaryPathsCount: number;
|
|
89
|
+
boundaryPaths: IHatchBoundaryPath[];
|
|
90
|
+
seedPointsCount: number;
|
|
91
|
+
extrusionDirectionX: number;
|
|
92
|
+
extrusionDirectionY: number;
|
|
93
|
+
extrusionDirectionZ: number;
|
|
94
|
+
patternName: string;
|
|
95
|
+
solidFill: boolean;
|
|
96
|
+
patternFillColor: number;
|
|
97
|
+
style: HatchStyle;
|
|
98
|
+
patternType: HatchType;
|
|
99
|
+
patternAngle: number;
|
|
100
|
+
patternScale: number;
|
|
101
|
+
patternLines?: IHatchPatternLine[];
|
|
102
|
+
isGradientColor?: boolean;
|
|
103
|
+
gradientColorCount?: number;
|
|
104
|
+
gradientColors?: number[];
|
|
105
|
+
}
|
|
106
|
+
export default class Hatch implements IGeometry {
|
|
107
|
+
readonly ForEntityName = "HATCH";
|
|
108
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): IHatchEntity;
|
|
109
|
+
parseDwgEntity(entity: DwgHatchEntity): IEntity;
|
|
110
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from "./geomtry";
|
|
3
|
+
import { DwgImageEntity } from "@mlightcad/libredwg-web";
|
|
4
|
+
export declare enum ImageFlags {
|
|
5
|
+
ShowImage = 1,
|
|
6
|
+
ShowImageWhenNotAlignedWithScreen = 2,
|
|
7
|
+
UseClippingBoundary = 4,
|
|
8
|
+
TransparencyIsOn = 8
|
|
9
|
+
}
|
|
10
|
+
export declare enum ImageClippingBoundaryType {
|
|
11
|
+
Rectangular = 1,
|
|
12
|
+
Polygonal = 2
|
|
13
|
+
}
|
|
14
|
+
export declare enum ImageClipMode {
|
|
15
|
+
Outside = 0,
|
|
16
|
+
Inside = 1
|
|
17
|
+
}
|
|
18
|
+
export interface IImageEntity extends IEntity {
|
|
19
|
+
position: IPoint;
|
|
20
|
+
uPixel: IPoint;
|
|
21
|
+
vPixel: IPoint;
|
|
22
|
+
imageSize: IPoint;
|
|
23
|
+
imageDefHandle: string;
|
|
24
|
+
flags: ImageFlags;
|
|
25
|
+
clipping: number;
|
|
26
|
+
brightness: number;
|
|
27
|
+
contrast: number;
|
|
28
|
+
fade: number;
|
|
29
|
+
imageDefReactorHandle: string;
|
|
30
|
+
clippingBoundaryType: ImageClippingBoundaryType;
|
|
31
|
+
countBoundaryPoints: number;
|
|
32
|
+
clippingBoundaryPath: IPoint[];
|
|
33
|
+
clipMode: ImageClipMode;
|
|
34
|
+
}
|
|
35
|
+
export default class Image implements IGeometry {
|
|
36
|
+
ForEntityName: "IMAGE";
|
|
37
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): IImageEntity;
|
|
38
|
+
parseDwgEntity(entity: DwgImageEntity): IEntity;
|
|
39
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from "./geomtry";
|
|
3
|
+
import { DwgInsertEntity } from "@mlightcad/libredwg-web";
|
|
4
|
+
export interface IInsertEntity extends IEntity {
|
|
5
|
+
block: string;
|
|
6
|
+
attributesFollow: boolean;
|
|
7
|
+
xScale: number;
|
|
8
|
+
yScale: number;
|
|
9
|
+
zScale: number;
|
|
10
|
+
position: IPoint;
|
|
11
|
+
rotation: number;
|
|
12
|
+
columnCount: number;
|
|
13
|
+
rowCount: number;
|
|
14
|
+
columnSpacing: number;
|
|
15
|
+
rowSpacing: number;
|
|
16
|
+
extrusionDirection: IPoint;
|
|
17
|
+
}
|
|
18
|
+
export default class Insert implements IGeometry {
|
|
19
|
+
ForEntityName: "INSERT";
|
|
20
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): IInsertEntity;
|
|
21
|
+
parseDwgEntity(entity: DwgInsertEntity): IEntity;
|
|
22
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from "./geomtry";
|
|
3
|
+
import { DwgLeaderEntity } from "@mlightcad/libredwg-web";
|
|
4
|
+
export interface ILeaderEntity extends IEntity {
|
|
5
|
+
dimensionStyle: string;
|
|
6
|
+
textHeight: number;
|
|
7
|
+
textWidth: number;
|
|
8
|
+
arrowFlag: number;
|
|
9
|
+
pathType: number;
|
|
10
|
+
arrowHeight: number;
|
|
11
|
+
arrowHeadScale: number;
|
|
12
|
+
creationFlag: number;
|
|
13
|
+
direction: number;
|
|
14
|
+
hasHookline: boolean;
|
|
15
|
+
block: string;
|
|
16
|
+
arrowHeadBlockHandle: string;
|
|
17
|
+
vertices: IPoint[];
|
|
18
|
+
}
|
|
19
|
+
export default class Leader implements IGeometry {
|
|
20
|
+
ForEntityName: "LEADER";
|
|
21
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): ILeaderEntity;
|
|
22
|
+
parseDwgEntity(entity: DwgLeaderEntity): IEntity;
|
|
23
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from './geomtry';
|
|
3
|
+
import { DwgLineEntity } from '@mlightcad/libredwg-web';
|
|
4
|
+
export interface ILineEntity extends IEntity {
|
|
5
|
+
vertices: IPoint[];
|
|
6
|
+
extrusionDirection: IPoint;
|
|
7
|
+
}
|
|
8
|
+
export default class Line implements IGeometry {
|
|
9
|
+
ForEntityName: "LINE";
|
|
10
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): ILineEntity;
|
|
11
|
+
parseDwgEntity(entity: DwgLineEntity): IEntity;
|
|
12
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from "./geomtry";
|
|
3
|
+
import { DwgLWPolylineEntity } from "@mlightcad/libredwg-web";
|
|
4
|
+
export interface IVertex extends IPoint {
|
|
5
|
+
startWidth?: number;
|
|
6
|
+
endWidth?: number;
|
|
7
|
+
}
|
|
8
|
+
export interface ILwpolylineEntity extends IEntity {
|
|
9
|
+
vertices: IVertex[];
|
|
10
|
+
elevation?: number;
|
|
11
|
+
thickness?: number;
|
|
12
|
+
shape: boolean;
|
|
13
|
+
hasContinuousLinetypePattern: boolean;
|
|
14
|
+
constantWidth?: number;
|
|
15
|
+
extrusionDirectionX?: number;
|
|
16
|
+
extrusionDirectionY?: number;
|
|
17
|
+
extrusionDirectionZ?: number;
|
|
18
|
+
}
|
|
19
|
+
export default class Lwpolyline implements IGeometry {
|
|
20
|
+
ForEntityName: "LWPOLYLINE";
|
|
21
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): ILwpolylineEntity;
|
|
22
|
+
parseDwgEntity(entity: DwgLWPolylineEntity): IEntity;
|
|
23
|
+
}
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import { DwgLeaderEntity } from "@mlightcad/libredwg-web";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from "./geomtry";
|
|
3
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
4
|
+
export interface ILeaderEntity extends IEntity {
|
|
5
|
+
leaderStyleId: number;
|
|
6
|
+
leaderLineType: number;
|
|
7
|
+
leaderLineColor: number;
|
|
8
|
+
leaderLineTypeId: number;
|
|
9
|
+
leaderLineWeight: number;
|
|
10
|
+
enableLanding: boolean;
|
|
11
|
+
enableDogLeg: boolean;
|
|
12
|
+
doglegLength: number;
|
|
13
|
+
arrowHeadId: number;
|
|
14
|
+
arrowHeadSize: number;
|
|
15
|
+
contentType: number;
|
|
16
|
+
textStyleId: number;
|
|
17
|
+
textLeftAttachmentType: number;
|
|
18
|
+
textRightAttachmentType: number;
|
|
19
|
+
textAngleType: number;
|
|
20
|
+
textAlignmentType: number;
|
|
21
|
+
textColor: number;
|
|
22
|
+
enableFrameText: boolean;
|
|
23
|
+
blockContentId: number;
|
|
24
|
+
blockContentColor: number;
|
|
25
|
+
blockContentScale: IPoint;
|
|
26
|
+
blockContentRotation: number;
|
|
27
|
+
blockContentConnectionType: number;
|
|
28
|
+
enableAnotationScale: boolean;
|
|
29
|
+
arrowHeadIndex: number;
|
|
30
|
+
blockAttributeId: number;
|
|
31
|
+
blockAttributeIndex: number;
|
|
32
|
+
blockAttributeWidth: number;
|
|
33
|
+
blockAttributeTextString: string;
|
|
34
|
+
textDirectionNegative: boolean;
|
|
35
|
+
textAlignInIPE: number;
|
|
36
|
+
textAttachmentPoint: number;
|
|
37
|
+
textAttachmentDirectionMText: number;
|
|
38
|
+
textAttachmentDirectionBottom: number;
|
|
39
|
+
textAttachmentDirectionTop: number;
|
|
40
|
+
contextData: IMLeaderContextData;
|
|
41
|
+
}
|
|
42
|
+
export interface IMLeaderContextData {
|
|
43
|
+
contentScale: number;
|
|
44
|
+
contentBasePosition: IPoint;
|
|
45
|
+
textHeight: number;
|
|
46
|
+
arrowHeadSize: number;
|
|
47
|
+
landingGap: number;
|
|
48
|
+
hasMText: boolean;
|
|
49
|
+
defaultTextContents: string;
|
|
50
|
+
textNormalDirection: IPoint;
|
|
51
|
+
textLocation: IPoint;
|
|
52
|
+
textDirection: IPoint;
|
|
53
|
+
textRotation: number;
|
|
54
|
+
textWidth: number;
|
|
55
|
+
textLineSpacingFactor: number;
|
|
56
|
+
textLineSpacingStyle: number;
|
|
57
|
+
textColor: number;
|
|
58
|
+
textAttachment: number;
|
|
59
|
+
textFlowDirection: number;
|
|
60
|
+
textBackgroundColor: number;
|
|
61
|
+
textBackgroundScaleFactor: number;
|
|
62
|
+
textBackgroundTransparency: number;
|
|
63
|
+
textBackgroundColorOn: boolean;
|
|
64
|
+
textBackgroundFillOn: boolean;
|
|
65
|
+
textColumnType: number;
|
|
66
|
+
textUseAutoHeight: boolean;
|
|
67
|
+
textColumnWidth: number;
|
|
68
|
+
textColumnGutterWidth: number;
|
|
69
|
+
textColumnFlowReversed: boolean;
|
|
70
|
+
textColumnHeight: number;
|
|
71
|
+
textUseWordBreak: boolean;
|
|
72
|
+
hasBlock: boolean;
|
|
73
|
+
blockContentId: number;
|
|
74
|
+
blockContentNormalDirection: IPoint;
|
|
75
|
+
blockContentPosition: IPoint;
|
|
76
|
+
blockContentScale: number;
|
|
77
|
+
blockContentRotation: number;
|
|
78
|
+
blockContentColor: number;
|
|
79
|
+
blockTransformationMatrix: number[];
|
|
80
|
+
planeOriginPoint: IPoint;
|
|
81
|
+
planeXAxisDirection: IPoint;
|
|
82
|
+
planeYAxisDirection: IPoint;
|
|
83
|
+
planeNormalReversed: boolean;
|
|
84
|
+
leaders: IMLeaderLeader[];
|
|
85
|
+
}
|
|
86
|
+
export interface IMLeaderLeader {
|
|
87
|
+
hasSetLastLeaderLinePoint: boolean;
|
|
88
|
+
hasSetDoglegVector: boolean;
|
|
89
|
+
lastLeaderLinePoint: IPoint;
|
|
90
|
+
doglegVector: IPoint;
|
|
91
|
+
leaderBranchIndex: number;
|
|
92
|
+
doglegLength: number;
|
|
93
|
+
leaderLines: IMLeaderLine[];
|
|
94
|
+
}
|
|
95
|
+
export interface IMLeaderLine {
|
|
96
|
+
vertices: IPoint[][];
|
|
97
|
+
leaderLineIndex: number;
|
|
98
|
+
}
|
|
99
|
+
export default class MLeader implements IGeometry {
|
|
100
|
+
ForEntityName: "MULTILEADER";
|
|
101
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): ILeaderEntity;
|
|
102
|
+
parseDwgEntity(entity: DwgLeaderEntity): IEntity;
|
|
103
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from "./geomtry";
|
|
3
|
+
import { DwgMTextEntity } from "@mlightcad/libredwg-web";
|
|
4
|
+
export interface IMtextEntity extends IEntity {
|
|
5
|
+
text: string;
|
|
6
|
+
position: IPoint;
|
|
7
|
+
directionVector?: IPoint;
|
|
8
|
+
height: number;
|
|
9
|
+
width: number;
|
|
10
|
+
rotation?: number;
|
|
11
|
+
attachmentPoint: number;
|
|
12
|
+
drawingDirection: number;
|
|
13
|
+
textStyle?: string;
|
|
14
|
+
lineSpaceFactor?: number;
|
|
15
|
+
}
|
|
16
|
+
export default class Mtext implements IGeometry {
|
|
17
|
+
ForEntityName: "MTEXT";
|
|
18
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): IMtextEntity;
|
|
19
|
+
parseDwgEntity(entity: DwgMTextEntity): IEntity;
|
|
20
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { DwgOle2FrameEntity } from "@mlightcad/libredwg-web";
|
|
2
|
+
import IGeometry, { IEntity } from "./geomtry";
|
|
3
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
4
|
+
export interface IOleEntity extends IEntity {
|
|
5
|
+
documentType: string;
|
|
6
|
+
version: number;
|
|
7
|
+
leftUpX: number;
|
|
8
|
+
leftUpY: number;
|
|
9
|
+
leftUpZ: number;
|
|
10
|
+
rightDownX: number;
|
|
11
|
+
rightDownY: number;
|
|
12
|
+
rightDownZ: number;
|
|
13
|
+
type: string;
|
|
14
|
+
tileModeDescriptor: number;
|
|
15
|
+
binaryData: string;
|
|
16
|
+
lengthOfBinaryData: number;
|
|
17
|
+
}
|
|
18
|
+
export default class Ole2frame implements IGeometry {
|
|
19
|
+
readonly ForEntityName = "OLE2FRAME";
|
|
20
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): IOleEntity;
|
|
21
|
+
parseDwgEntity(entity: DwgOle2FrameEntity): IEntity;
|
|
22
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from './geomtry';
|
|
3
|
+
import { DwgPointEntity } from '@mlightcad/libredwg-web';
|
|
4
|
+
export interface IPointEntity extends IEntity {
|
|
5
|
+
position: IPoint;
|
|
6
|
+
thickness: number;
|
|
7
|
+
extrusionDirection: IPoint;
|
|
8
|
+
}
|
|
9
|
+
export default class Point implements IGeometry {
|
|
10
|
+
ForEntityName: "POINT";
|
|
11
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): IPointEntity;
|
|
12
|
+
parseDwgEntity(entity: DwgPointEntity): IEntity;
|
|
13
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from "./geomtry";
|
|
3
|
+
import { IVertexEntity } from "./vertex";
|
|
4
|
+
import { DwgPolyline2dEntity } from "@mlightcad/libredwg-web";
|
|
5
|
+
export interface IPolylineEntity extends IEntity {
|
|
6
|
+
vertices: IVertexEntity[];
|
|
7
|
+
thickness: number;
|
|
8
|
+
shape: boolean;
|
|
9
|
+
includesCurveFitVertices: boolean;
|
|
10
|
+
includesSplineFitVertices: boolean;
|
|
11
|
+
is3dPolyline: boolean;
|
|
12
|
+
is3dPolygonMesh: boolean;
|
|
13
|
+
is3dPolygonMeshClosed: boolean;
|
|
14
|
+
isPolyfaceMesh: boolean;
|
|
15
|
+
hasContinuousLinetypePattern: boolean;
|
|
16
|
+
extrusionDirection: IPoint;
|
|
17
|
+
}
|
|
18
|
+
export default class Polyline implements IGeometry {
|
|
19
|
+
ForEntityName: "POLYLINE";
|
|
20
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): IPolylineEntity;
|
|
21
|
+
parseDwgEntity(entity: DwgPolyline2dEntity): IEntity;
|
|
22
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from './geomtry';
|
|
3
|
+
import { DwgRayEntity } from '@mlightcad/libredwg-web';
|
|
4
|
+
export interface IRayEntity extends IEntity {
|
|
5
|
+
vertices: IPoint[];
|
|
6
|
+
directionVector: IPoint;
|
|
7
|
+
}
|
|
8
|
+
export default class Ray implements IGeometry {
|
|
9
|
+
ForEntityName: "RAY";
|
|
10
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): IRayEntity;
|
|
11
|
+
parseDwgEntity(entity: DwgRayEntity): IEntity;
|
|
12
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { DwgEntity } from "@mlightcad/libredwg-web";
|
|
2
|
+
import IGeometry, { IEntity } from "./geomtry";
|
|
3
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
4
|
+
export interface IRegionEntity extends IEntity {
|
|
5
|
+
modelerVersion?: number;
|
|
6
|
+
proprietaryData?: string;
|
|
7
|
+
}
|
|
8
|
+
export default class Region implements IGeometry {
|
|
9
|
+
ForEntityName: "REGION";
|
|
10
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): IRegionEntity;
|
|
11
|
+
parseDwgEntity(entity: DwgEntity): IEntity;
|
|
12
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
2
|
+
import IGeometry, { IEntity } from './geomtry';
|
|
3
|
+
import { DwgEntity } from '@mlightcad/libredwg-web';
|
|
4
|
+
export interface ISeqendEntity extends IEntity {
|
|
5
|
+
}
|
|
6
|
+
export default class Seqend implements IGeometry {
|
|
7
|
+
ForEntityName: "SEQEND";
|
|
8
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): ISeqendEntity;
|
|
9
|
+
parseDwgEntity(entity: DwgEntity): IEntity;
|
|
10
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { DwgSolidEntity } from "@mlightcad/libredwg-web";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from "./geomtry";
|
|
3
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
4
|
+
export interface ISolidEntity extends IEntity {
|
|
5
|
+
points: IPoint[];
|
|
6
|
+
extrusionDirection: IPoint;
|
|
7
|
+
}
|
|
8
|
+
export default class Solid implements IGeometry {
|
|
9
|
+
ForEntityName: "SOLID";
|
|
10
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): ISolidEntity;
|
|
11
|
+
parseDwgEntity(entity: DwgSolidEntity): IEntity;
|
|
12
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { DwgSplineEntity } from "@mlightcad/libredwg-web";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from "./geomtry";
|
|
3
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
4
|
+
export interface ISplineEntity extends IEntity {
|
|
5
|
+
controlPoints?: IPoint[];
|
|
6
|
+
fitPoints?: IPoint[];
|
|
7
|
+
startTangent: IPoint;
|
|
8
|
+
endTangent: IPoint;
|
|
9
|
+
knotValues: number[];
|
|
10
|
+
closed: boolean;
|
|
11
|
+
periodic: boolean;
|
|
12
|
+
rational: boolean;
|
|
13
|
+
planar: boolean;
|
|
14
|
+
linear: boolean;
|
|
15
|
+
degreeOfSplineCurve: number;
|
|
16
|
+
numberOfKnots: number;
|
|
17
|
+
numberOfControlPoints: number;
|
|
18
|
+
numberOfFitPoints: number;
|
|
19
|
+
normalVector: IPoint;
|
|
20
|
+
}
|
|
21
|
+
export default class Spline implements IGeometry {
|
|
22
|
+
ForEntityName: "SPLINE";
|
|
23
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): ISplineEntity;
|
|
24
|
+
parseDwgEntity(entity: DwgSplineEntity): IEntity;
|
|
25
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { DwgTableEntity } from "@mlightcad/libredwg-web";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from "./geomtry";
|
|
3
|
+
import { IMtextEntity } from "./mtext";
|
|
4
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
5
|
+
export interface ITableEntity extends IEntity {
|
|
6
|
+
version: number;
|
|
7
|
+
startPoint: IPoint;
|
|
8
|
+
directionVector: IPoint;
|
|
9
|
+
tableValue: number;
|
|
10
|
+
rowCount: number;
|
|
11
|
+
columnCount: number;
|
|
12
|
+
overrideFlag?: number;
|
|
13
|
+
borderColorOverrideFlag?: number;
|
|
14
|
+
borderLineWeightOverrideFlag?: number;
|
|
15
|
+
borderVisibilityOverrideFlag?: number;
|
|
16
|
+
rowHeightArr: number[];
|
|
17
|
+
columnWidthArr: number[];
|
|
18
|
+
tableStyleId?: string;
|
|
19
|
+
blockRecordHandle?: string;
|
|
20
|
+
cells: TableCell[];
|
|
21
|
+
}
|
|
22
|
+
export interface TableCell extends IMtextEntity {
|
|
23
|
+
cellType: number;
|
|
24
|
+
flagValue?: number;
|
|
25
|
+
mergedValue?: number;
|
|
26
|
+
autoFit?: number;
|
|
27
|
+
borderWidth?: number;
|
|
28
|
+
borderHeight?: number;
|
|
29
|
+
overrideFlag?: number;
|
|
30
|
+
virtualEdgeFlag?: number;
|
|
31
|
+
fieldObjetId?: string;
|
|
32
|
+
blockTableRecordId?: string;
|
|
33
|
+
blockScale?: number;
|
|
34
|
+
blockAttrNum?: number;
|
|
35
|
+
attrDefineId?: string[];
|
|
36
|
+
attrText?: string;
|
|
37
|
+
textHeight: number;
|
|
38
|
+
extendedCellFlags?: number;
|
|
39
|
+
}
|
|
40
|
+
export default class Table implements IGeometry {
|
|
41
|
+
ForEntityName: "ACAD_TABLE";
|
|
42
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): ITableEntity;
|
|
43
|
+
parseDwgEntity(entity: DwgTableEntity): IEntity;
|
|
44
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { DwgTextEntity } from "@mlightcad/libredwg-web";
|
|
2
|
+
import IGeometry, { IEntity, IPoint } from "./geomtry";
|
|
3
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
4
|
+
export interface ITextEntity extends IEntity {
|
|
5
|
+
startPoint: IPoint;
|
|
6
|
+
endPoint: IPoint;
|
|
7
|
+
textHeight: number;
|
|
8
|
+
xScale: number;
|
|
9
|
+
rotation: number;
|
|
10
|
+
text: string;
|
|
11
|
+
textStyle: string;
|
|
12
|
+
mirrored: number;
|
|
13
|
+
halign: number;
|
|
14
|
+
valign: number;
|
|
15
|
+
}
|
|
16
|
+
export default class Text implements IGeometry {
|
|
17
|
+
ForEntityName: "TEXT";
|
|
18
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): ITextEntity;
|
|
19
|
+
parseDwgEntity(entity: DwgTextEntity): IEntity;
|
|
20
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { DwgVertex2dEntity } from "@mlightcad/libredwg-web";
|
|
2
|
+
import { DxfBaseReader, IGroup } from "../DxfBaseReader";
|
|
3
|
+
import IGeometry, { IEntity, IPoint } from './geomtry';
|
|
4
|
+
export interface IVertexEntity extends IEntity, IPoint {
|
|
5
|
+
bulge: number;
|
|
6
|
+
curveFittingVertex: boolean;
|
|
7
|
+
curveFitTangent: boolean;
|
|
8
|
+
splineVertex: boolean;
|
|
9
|
+
splineControlPoint: boolean;
|
|
10
|
+
threeDPolylineVertex: boolean;
|
|
11
|
+
threeDPolylineMesh: boolean;
|
|
12
|
+
polyfaceMeshVertex: boolean;
|
|
13
|
+
faceA: number;
|
|
14
|
+
faceB: number;
|
|
15
|
+
faceC: number;
|
|
16
|
+
faceD: number;
|
|
17
|
+
}
|
|
18
|
+
export default class Vertex implements IGeometry {
|
|
19
|
+
ForEntityName: "VERTEX";
|
|
20
|
+
parseEntity(scanner: DxfBaseReader, curr: IGroup): IVertexEntity;
|
|
21
|
+
parseDwgEntity(entity: DwgVertex2dEntity): IEntity;
|
|
22
|
+
}
|