dev #256

Merged
ysCha merged 2 commits from dev into dev-deploy 2025-07-30 17:47:25 +09:00
Showing only changes of commit 31751c26b9 - Show all commits

View File

@ -311,8 +311,6 @@ export function removeDuplicatePolygons(polygons, hasAuxiliaryLine = false) {
// return isValidPoints(polygon)
// })
console.log('uniquePolygons2', uniquePolygons)
return uniquePolygons
}
@ -373,6 +371,14 @@ function checkPolygonSelfIntersection(coordinates) {
}
}
// 모든 점이 같은 직선상에 있는지 검사 (degenerate polygon)
const allSameX = coordinates.every((point) => point.x === coordinates[0].x)
const allSameY = coordinates.every((point) => point.y === coordinates[0].y)
if (allSameX || allSameY) {
return true // 직선상의 점들은 유효하지 않은 다각형이므로 true 반환
}
const intersections = []
const edges = []