mxdraw 0.1.25 → 0.1.26
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/lib/MxModule/MxDbArea/MxDbArea.js +1 -1
- package/dist/lib/MxModule/MxDbCloudLine/MxDbCloudLine.js +1 -0
- package/dist/lib/MxModule/MxDbCloudLine/index.js +1 -0
- package/dist/lib/MxModule/MxDbEllipse/MxDbEllipse.js +1 -0
- package/dist/lib/MxModule/MxDbEllipse/index.js +1 -0
- package/dist/lib/MxModule/MxDbLeadComment/MxDbLeadComment.js +1 -0
- package/dist/lib/MxModule/MxDbLeadComment/index.js +1 -0
- package/dist/lib/MxModule/MxDbRectBoxLeadComment/MxDbRectBoxLeadComment.js +1 -0
- package/dist/lib/MxModule/MxDbRectBoxLeadComment/index.js +1 -0
- package/dist/lib/MxModule/MxDbRegularPolygon/MxDbRegularPolygon.js +1 -0
- package/dist/lib/MxModule/MxDbRegularPolygon/index.js +1 -0
- package/dist/lib/MxModule/MxDbText/MxDbText.js +1 -0
- package/dist/lib/MxModule/MxDbText/index.js +1 -0
- package/dist/lib/MxModule/loadCoreCode/mxfun.es5.js +1 -1
- package/dist/lib/mxdraw.js +1 -1
- package/dist/lib/tools/dynamicImport/index.js +1 -1
- package/dist/lib/tools/three/index.js +1 -1
- package/dist/mxdraw.es5.js +1 -1
- package/dist/mxdraw.umd.js +1 -1
- package/dist/types/MxModule/MxDbCloudLine/MxDbCloudLine.d.ts +27 -0
- package/dist/types/MxModule/MxDbCloudLine/index.d.ts +3 -0
- package/dist/types/MxModule/MxDbEllipse/MxDbEllipse.d.ts +18 -0
- package/dist/types/MxModule/MxDbEllipse/index.d.ts +3 -0
- package/dist/types/MxModule/MxDbLeadComment/MxDbLeadComment.d.ts +17 -0
- package/dist/types/MxModule/MxDbLeadComment/index.d.ts +3 -0
- package/dist/types/MxModule/MxDbRectBoxLeadComment/MxDbRectBoxLeadComment.d.ts +19 -0
- package/dist/types/MxModule/MxDbRectBoxLeadComment/index.d.ts +3 -0
- package/dist/types/MxModule/MxDbRegularPolygon/MxDbRegularPolygon.d.ts +18 -0
- package/dist/types/MxModule/MxDbRegularPolygon/index.d.ts +2 -0
- package/dist/types/MxModule/MxDbText/MxDbText.d.ts +20 -0
- package/dist/types/MxModule/MxDbText/index.d.ts +3 -0
- package/dist/types/mxdraw.d.ts +13 -1
- package/dist/types/tools/three/index.d.ts +14 -2
- package/package.json +1 -1
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/** @module MxDbCloudLine*/
|
|
2
|
+
import { Vector3 } from 'three';
|
|
3
|
+
import McGiWorldDraw from '../McGiWorldDraw';
|
|
4
|
+
import MxDbEntity from '../MxDbEntity';
|
|
5
|
+
/**
|
|
6
|
+
* MxDbCloudLine 对象.
|
|
7
|
+
*/
|
|
8
|
+
export default class MxDbCloudLine extends MxDbEntity {
|
|
9
|
+
private points;
|
|
10
|
+
private radius;
|
|
11
|
+
private drawGeometry;
|
|
12
|
+
getTypeName(): string;
|
|
13
|
+
create(): MxDbEntity;
|
|
14
|
+
setRadius(radius: number): void;
|
|
15
|
+
getRadius(): number;
|
|
16
|
+
private clacNewArcDiameterPoint;
|
|
17
|
+
private createCloudArcCurvePoints;
|
|
18
|
+
addPoint(pt: THREE.Vector3, isAddToDrawGeometry?: boolean): void;
|
|
19
|
+
addLine(pt1: THREE.Vector3, pt2: THREE.Vector3): void;
|
|
20
|
+
reCalculateDrawGeometry(): void;
|
|
21
|
+
worldDraw(pWorldDraw: McGiWorldDraw): void;
|
|
22
|
+
getCenter(): Vector3;
|
|
23
|
+
getGripPoints(): Vector3[];
|
|
24
|
+
moveGripPointsAt(index: number, offset: Vector3): boolean;
|
|
25
|
+
dwgIn(obj: any): boolean;
|
|
26
|
+
dwgOut(obj: any): object;
|
|
27
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/** @module MxDbEllipse*/
|
|
2
|
+
import { Vector3 } from 'three';
|
|
3
|
+
import McGiWorldDraw from '../McGiWorldDraw';
|
|
4
|
+
import MxDbEntity from '../MxDbEntity';
|
|
5
|
+
/**
|
|
6
|
+
* MxDbEllipse
|
|
7
|
+
*/
|
|
8
|
+
export default class MxDbEllipse extends MxDbEntity {
|
|
9
|
+
point1: Vector3;
|
|
10
|
+
point2: Vector3;
|
|
11
|
+
getTypeName(): string;
|
|
12
|
+
worldDraw(pWorldDraw: McGiWorldDraw): void;
|
|
13
|
+
getGripPoints(): Vector3[];
|
|
14
|
+
moveGripPointsAt(index: number, offset: Vector3): boolean;
|
|
15
|
+
create(): MxDbEntity;
|
|
16
|
+
dwgIn(obj: any): boolean;
|
|
17
|
+
dwgOut(obj: any): object;
|
|
18
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/** @module MxDbLeadComment*/
|
|
2
|
+
import * as THREE from 'three';
|
|
3
|
+
import McGiWorldDraw from '../McGiWorldDraw';
|
|
4
|
+
import MxDbEntity from '../MxDbEntity';
|
|
5
|
+
export default class MxDbLeadComment extends MxDbEntity {
|
|
6
|
+
point1: THREE.Vector3;
|
|
7
|
+
point2: THREE.Vector3;
|
|
8
|
+
text: string;
|
|
9
|
+
textHeight: number;
|
|
10
|
+
getTypeName(): string;
|
|
11
|
+
create(): MxDbEntity;
|
|
12
|
+
worldDraw(pWorldDraw: McGiWorldDraw): void;
|
|
13
|
+
getGripPoints(): Array<THREE.Vector3>;
|
|
14
|
+
moveGripPointsAt(index: number, offset: THREE.Vector3): boolean;
|
|
15
|
+
dwgIn(obj: any): boolean;
|
|
16
|
+
dwgOut(obj: any): object;
|
|
17
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/** @module MxDbRectBoxLeadComment*/
|
|
2
|
+
import * as THREE from 'three';
|
|
3
|
+
import McGiWorldDraw from '../McGiWorldDraw';
|
|
4
|
+
import MxDbEntity from '../MxDbEntity';
|
|
5
|
+
export default class MxDbRectBoxLeadComment extends MxDbEntity {
|
|
6
|
+
point1: THREE.Vector3;
|
|
7
|
+
point2: THREE.Vector3;
|
|
8
|
+
point3: THREE.Vector3;
|
|
9
|
+
text: string;
|
|
10
|
+
textHeight: number;
|
|
11
|
+
radius: number;
|
|
12
|
+
getTypeName(): string;
|
|
13
|
+
create(): MxDbEntity;
|
|
14
|
+
worldDraw(pWorldDraw: McGiWorldDraw): void;
|
|
15
|
+
getGripPoints(): Array<THREE.Vector3>;
|
|
16
|
+
moveGripPointsAt(index: number, offset: THREE.Vector3): boolean;
|
|
17
|
+
dwgIn(obj: any): boolean;
|
|
18
|
+
dwgOut(obj: any): object;
|
|
19
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import MxDbEntity from '../MxDbEntity';
|
|
2
|
+
import { Vector3 } from 'three';
|
|
3
|
+
import McGiWorldDraw from '../McGiWorldDraw';
|
|
4
|
+
/**
|
|
5
|
+
* MxDbRegularPolygon
|
|
6
|
+
*/
|
|
7
|
+
export default class MxDbRegularPolygon extends MxDbEntity {
|
|
8
|
+
centerPoint: Vector3;
|
|
9
|
+
otherPoint: Vector3;
|
|
10
|
+
sidesNumber: number;
|
|
11
|
+
getTypeName(): string;
|
|
12
|
+
worldDraw(pWorldDraw: McGiWorldDraw): void;
|
|
13
|
+
getGripPoints(): Vector3[];
|
|
14
|
+
moveGripPointsAt(index: number, offset: Vector3): boolean;
|
|
15
|
+
create(): MxDbEntity;
|
|
16
|
+
dwgIn(obj: any): boolean;
|
|
17
|
+
dwgOut(obj: any): object;
|
|
18
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/** @module MxDbText*/
|
|
2
|
+
import { Vector3 } from 'three';
|
|
3
|
+
import McGiWorldDraw from '../McGiWorldDraw';
|
|
4
|
+
import MxDbEntity from '../MxDbEntity';
|
|
5
|
+
/**
|
|
6
|
+
* MxDbText
|
|
7
|
+
*/
|
|
8
|
+
export default class MxDbText extends MxDbEntity {
|
|
9
|
+
position: Vector3;
|
|
10
|
+
text: string;
|
|
11
|
+
height: number;
|
|
12
|
+
angle: number;
|
|
13
|
+
getTypeName(): string;
|
|
14
|
+
worldDraw(pWorldDraw: McGiWorldDraw): void;
|
|
15
|
+
getGripPoints(): Vector3[];
|
|
16
|
+
moveGripPointsAt(index: number, offset: Vector3): boolean;
|
|
17
|
+
create(): MxDbEntity;
|
|
18
|
+
dwgIn(obj: any): boolean;
|
|
19
|
+
dwgOut(obj: any): object;
|
|
20
|
+
}
|
package/dist/types/mxdraw.d.ts
CHANGED
|
@@ -24,10 +24,16 @@ import MxType from './MxModule/MxType';
|
|
|
24
24
|
import Mxassembly from './MxModule/Mxassembly';
|
|
25
25
|
import MxDbArea from './MxModule/MxDbArea';
|
|
26
26
|
import MxDbAnyLine from './MxModule/MxDbAnyLine';
|
|
27
|
+
import MxDbCloudLine from './MxModule/MxDbCloudLine';
|
|
28
|
+
import MxDbRegularPolygon from './MxModule/MxDbRegularPolygon';
|
|
27
29
|
import McGePoint3d from './MxModule/McGePoint3d';
|
|
28
30
|
import McGePoint3dArray from './MxModule/McGePoint3dArray';
|
|
29
31
|
import McGeTool from './MxModule/McGeTool';
|
|
30
|
-
|
|
32
|
+
import MxDbLeadComment from './MxModule/MxDbLeadComment';
|
|
33
|
+
import MxDbRectBoxLeadComment from './MxModule/MxDbRectBoxLeadComment';
|
|
34
|
+
import MxDbEllipse from './MxModule/MxDbEllipse';
|
|
35
|
+
import MxDbText from './MxModule/MxDbText';
|
|
36
|
+
export { MxFun, Mxassembly, MxThreeJS, McEdGetPointWorldDrawObject, MrxDbgUiPrPoint, McGePoint3d, McGePoint3dArray, McGeTool, MxDbEntity, MxFilters, MxDbImage, MxDbLine, MxDbSVG, MxDbSVGText, MxDbPolyline, Mx3PointArc, MxDbCoord, MxDb2LineAngularDimension, MxDbRect, MxDbAlignedDimension, useCanvasResizeListener, loadCoreCode, store, McGiWorldDraw, McGiWorldDrawType, MrxDbgUiPrBaseReturn, MxType, MxDbArea, MxDbAnyLine, MxDbCloudLine, MxDbLeadComment, MxDbRectBoxLeadComment, MxDbEllipse, MxDbText, MxDbRegularPolygon };
|
|
31
37
|
declare const _default: {
|
|
32
38
|
MxFun: import("./doc").MxFun;
|
|
33
39
|
Mxassembly: import("./MxModule/Mxassembly/Mxassembly").default;
|
|
@@ -59,5 +65,11 @@ declare const _default: {
|
|
|
59
65
|
McGiWorldDrawType: typeof McGiWorldDrawType;
|
|
60
66
|
MxDbArea: typeof MxDbArea;
|
|
61
67
|
MxDbAnyLine: typeof MxDbAnyLine;
|
|
68
|
+
MxDbCloudLine: typeof MxDbCloudLine;
|
|
69
|
+
MxDbLeadComment: typeof MxDbLeadComment;
|
|
70
|
+
MxDbRectBoxLeadComment: typeof MxDbRectBoxLeadComment;
|
|
71
|
+
MxDbEllipse: typeof MxDbEllipse;
|
|
72
|
+
MxDbText: typeof MxDbText;
|
|
73
|
+
MxDbRegularPolygon: typeof MxDbRegularPolygon;
|
|
62
74
|
};
|
|
63
75
|
export default _default;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ColorType } from '@/MxModule/MxType/MxType';
|
|
2
|
+
import { Vector3, Color, Line, Geometry, LineLoop } from 'three';
|
|
2
3
|
/**
|
|
3
4
|
* 移动geometry坐标。
|
|
4
5
|
* @param geometry Three的Geometry对象
|
|
@@ -14,7 +15,7 @@ export declare function setGeometrPostion(geometry: THREE.Geometry, pos: THREE.V
|
|
|
14
15
|
* 生成圆角时修复纹理对应的 uvs
|
|
15
16
|
* @param geometry 几何体
|
|
16
17
|
* */
|
|
17
|
-
export declare function repairGeometryFaceVertexUvs(geometry: THREE.Geometry):
|
|
18
|
+
export declare function repairGeometryFaceVertexUvs(geometry: THREE.Geometry): Geometry;
|
|
18
19
|
/**
|
|
19
20
|
* 获取生成圆角的points定点位置
|
|
20
21
|
* @param points 生成圆角前
|
|
@@ -55,3 +56,14 @@ export declare function createThreePointArc(pt1: Vector3, pt2: Vector3, pt3: Vec
|
|
|
55
56
|
arcLength: number;
|
|
56
57
|
};
|
|
57
58
|
export declare function createAnyLine(points: Vector3[]): Line;
|
|
59
|
+
/**
|
|
60
|
+
* 绘制椭圆 */
|
|
61
|
+
export declare function createThreeEllipse(pt1: Vector3, pt3: Vector3, color: ColorType): Line;
|
|
62
|
+
export declare function computeRegularPolygonVertices(centerPt?: Vector3, pt?: Vector3, segments?: number): Vector3[];
|
|
63
|
+
/**
|
|
64
|
+
* 创建正多边形
|
|
65
|
+
* @param centerPt 中点
|
|
66
|
+
* @param pt 边角一点
|
|
67
|
+
* @param segments 边数
|
|
68
|
+
* */
|
|
69
|
+
export declare function createThreeRegularPolygon(centerPt: Vector3, pt: Vector3, segments: number, color: ColorType): LineLoop;
|