feature/jaeyoung #46
@ -383,6 +383,7 @@ export function useRoofAllocationSetting(id) {
|
||||
}
|
||||
} catch (e) {
|
||||
console.log(e)
|
||||
canvas.discardActiveObject()
|
||||
return
|
||||
}
|
||||
|
||||
|
||||
@ -1168,6 +1168,15 @@ export const usePolygon = () => {
|
||||
canvas.remove(polygon)
|
||||
canvas.renderAll()
|
||||
})
|
||||
|
||||
//지붕 완료 후 보조선을 전부 제거한다.
|
||||
const auxiliaryLines = canvas.getObjects().filter((obj) => obj.name === 'auxiliaryLine')
|
||||
|
||||
auxiliaryLines.forEach((line) => {
|
||||
canvas.remove(line)
|
||||
})
|
||||
canvas.renderAll()
|
||||
canvas.discardActiveObject()
|
||||
}
|
||||
|
||||
const getSplitRoofsPoints = (allLines) => {
|
||||
|
||||
@ -549,8 +549,6 @@ export function isPointOnLine({ x1, y1, x2, y2 }, { x, y }, epsilon = 2) {
|
||||
withinYRange = withinYRange && 2 <= Math.max(y1, y2) - y
|
||||
}
|
||||
|
||||
console.log(Math.min(x1, x2) - x, Math.max(x1, x2) - x)
|
||||
|
||||
return withinXRange && withinYRange
|
||||
}
|
||||
/**
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user