更新版本,修复镜像槽问题

This commit is contained in:
FishOrBear
2020-04-30 17:12:30 +08:00
parent d79d759091
commit 85db279fab
12 changed files with 2582 additions and 2218 deletions

View File

@@ -1,12 +1,12 @@
import { Box3, Vector3, Matrix4, Mesh } from "three";
import { Box3, Matrix4, Mesh, Vector3 } from "three";
import { Dimension, GetBoxArr } from ".";
/**
* 绘制标注实体
*
*
* @export
* @param {Box3} box
* @param {Box3} box
* @returns 标注实体列表
*/
export function DrawDimension(brList: Mesh[]): Dimension[]
@@ -24,7 +24,7 @@ export function DrawDimension(brList: Mesh[]): Dimension[]
let textHeight = 45;
let dimx = new Dimension(size.x, textHeight, true);
dimx.applyMatrix(mat4);
dimx.applyMatrix4(mat4);
let dimz = new Dimension(size.z, textHeight);
mat4.makeBasis(
@@ -33,7 +33,7 @@ export function DrawDimension(brList: Mesh[]): Dimension[]
new Vector3(0, -1, 0)
)
mat4.setPosition(box.max.clone().add(new Vector3(30, -size.y)));
dimz.applyMatrix(mat4);
dimz.applyMatrix4(mat4);
let dimy = new Dimension(size.y, textHeight, true, true);
mat4.makeBasis(
@@ -42,7 +42,7 @@ export function DrawDimension(brList: Mesh[]): Dimension[]
new Vector3(0, 0, 1)
)
mat4.setPosition(box.max.clone().add(new Vector3(30, -size.y)));
dimy.applyMatrix(mat4);
dimy.applyMatrix4(mat4);
return [dimx, dimy, dimz];