fix(B05): 3D 제안 ② 비탈 끝 드레이프 — 115-7 로 짧아진 행의 설계면 높이 끝과 바깥 지형 턱 없앰(측점 아닌 행 · 지반 차 0.1 m 넘는 행 · 측점 행은 B06 그대로)(115-8)
- 성토 닿은 70° 삼각형 760 → 150(226) · 측점 오차 그대로 - test_115_6 드레이프 단언 하나 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EYJJRCfHfdCGNhmXTjQKV7
This commit is contained in:
@@ -382,7 +382,20 @@ const r6 = (v) => Math.round(v * 1e6) / 1e6;
|
||||
}
|
||||
toeErr = Math.max(toeErr, best === Infinity ? 99 : best);
|
||||
}
|
||||
// 드레이프(115-8) — 측점 아닌 행의 비탈 끝(둘레 점)은 그 자리 망 지형 높이.
|
||||
let offGround = 0;
|
||||
let daylightRows = 0;
|
||||
out.design.outer.forEach(([dx, dz]) => {
|
||||
const tag = tagAt.get(fkey(dx, dz));
|
||||
if (tag !== PSLG.TAG_FILL && tag !== PSLG.TAG_CUT) return;
|
||||
if ([-20, 0, 20].some((x) => Math.abs(dx - x) < 1e-6)) return;
|
||||
const i = [...Array(pslg.count).keys()].find((k) => pslg.x[k] === dx && pslg.z[k] === dz);
|
||||
daylightRows += 1;
|
||||
if (Math.abs(pslg.y[i] - heightIndex.heightAt(dx, dz)) > 1e-4) offGround += 1;
|
||||
});
|
||||
results.straight = {
|
||||
daylightRows,
|
||||
offGround,
|
||||
stats: out.stats,
|
||||
gaps: gap.gaps,
|
||||
maxGapLen: r6(gap.maxGapLen),
|
||||
|
||||
@@ -41,6 +41,12 @@ def test_straight_station_section_matches_b06(results):
|
||||
assert r["toeErr"] < 0.06 # 비탈 끝 자리(시험 걸음 0.05 m 안)
|
||||
|
||||
|
||||
def test_straight_daylight_draped(results):
|
||||
r = results["straight"]
|
||||
assert r["daylightRows"] > 300
|
||||
assert r["offGround"] == 0 # 측점 아닌 행 비탈 끝 = 망 지형 높이(드레이프 · 115-8)
|
||||
|
||||
|
||||
def test_straight_terrain_outside_untouched(results):
|
||||
r = results["straight"]
|
||||
assert r["originalUntouched"] is True # 원본 정점 버퍼 그대로
|
||||
|
||||
Reference in New Issue
Block a user