actureSize - 소수점처리
This commit is contained in:
parent
b6258c6a2a
commit
b6711a1bb9
@ -6000,9 +6000,9 @@ export const calcLineActualSize2 = (points, degree = 0) => {
|
||||
const hx = xLength * Math.tan(degree * (Math.PI / 180))
|
||||
|
||||
const hy = yLength * Math.tan(degree * (Math.PI / 180))
|
||||
const actualSize = Math.sqrt(hx ** 2 + planeSize ** 2)
|
||||
const actualSize2 = Math.sqrt(hy ** 2 + planeSize ** 2)
|
||||
return actualSize
|
||||
const actualSize = Number(Math.sqrt(hx ** 2 + planeSize ** 2)).toFixed(0)
|
||||
const actualSize2 = Number(Math.sqrt(hy ** 2 + planeSize ** 2)).toFixed(0)
|
||||
return actualSize
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -822,7 +822,7 @@ const createInnerLinesFromSkeleton = (roofId, canvas, skeleton, textMode) => {
|
||||
type: 'eaveHelpLine',
|
||||
isStart: true,
|
||||
pitch: wallLine.attributes.pitch,
|
||||
actualSize: (isDiagonal) ? calcLineActualSize(
|
||||
actualSize: (isDiagonal) ? calcLineActualSize2(
|
||||
{
|
||||
x1: p1.x,
|
||||
y1: p1.y,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user