Merge pull request !386 from ZoeLeeFZ/fixTestM
pull/386/MERGE
ZoeLeeFZ 5 years ago committed by ChenX
parent 5f77c2823c
commit 79dda5c61c

@ -110,6 +110,14 @@ export class Entity extends CADObject
this.Update(UpdateDraw.Matrix);
}
/** Z轴归0 */
Z0()
{
this.WriteAllObjectRecord();
this._Matrix.elements[14] = 0;
this.Update(UpdateDraw.Matrix);
}
get OCSInv(): Matrix4
{
return new Matrix4().getInverse(this._Matrix);

@ -17,6 +17,7 @@ export class Shape
this.m_Outline = out || new Contour();
hols && this.m_Holes.push(...hols);
}
get Outline()
{
return this.m_Outline;
@ -50,6 +51,14 @@ export class Shape
this.UpdateShape();
return this.m_Shape;
}
Z0()
{
this.m_Outline.Curve.Z0();
for (let h of this.m_Holes)
h.Curve.Z0();
}
ApplyMatrix(m: Matrix4)
{
this.m_Outline.Curve.ApplyMatrix(m);

@ -10,6 +10,7 @@ import { BoolOpeartionType } from "../BoolOperateUtils";
import { OptimizeToolPath } from "./OptimizeToolPath";
import { equalCurve, IsRect } from "../../Common/CurveUtils";
import { Vector3 } from "three";
import { MoveMatrix } from "../../Geometry/GeUtils";
/**
*
@ -179,7 +180,7 @@ export class FeedingToolPath extends Singleton
if (!knifeRadius) knifeRadius = 3;
shape = shape.Clone();
shape.Z0();
this.GrooveAddLen(shape, addLen);
if (thickness >= brThickness)

Loading…
Cancel
Save