feat: 2 m placeholder pattern zones on lining, station/pattern readout in viewer (Task 5)

No pattern-to-station data exists in the drawings. Per user decision
(2026-10-21) the modelled range 4+745..5+480 is split into 2 m segments with
arbitrary pattern names, marked placeholder in CSV, meta and viewer, to be
replaced later. Ring step reduced to 1 m so that the 2 m segments align.

Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01A5Cun3RHQKna9qxE6ybZ4A
This commit is contained in:
Claude committed 2026-10-21 06:12:58 +00:00
1 parent c9de6f0ef3
commit 6c7e555c25
7 files changed
+2303 -10

No files matched your search

+13 -2
View File
@@ -96,8 +96,10 @@ loader.load(MODEL, (gltf) => {
status.textContent = '로드 실패: 파일을 HTTP 서버로 여세요 (README 참조)';
});
let M = null;
fetch(META).then((r) => r.json()).then((m) => {
info.textContent = '범위: ' + m.scope + ' (단위 ' + m.units + ')\n근사 항목:\n- ' + m.approximations.join('\n- ') + '\n미완:\n- ' + m.open.join('\n- ');
M = m;
info.textContent = '범위: ' + m.scope + ' (단위 ' + m.units + ')\n패턴: ' + m.pattern_status + '\n근사 항목:\n- ' + m.approximations.join('\n- ') + '\n미완:\n- ' + m.open.join('\n- ');
}).catch(() => {});
const ray = new THREE.Raycaster();
@@ -112,7 +114,16 @@ renderer.domElement.addEventListener('pointerup', (e) => {
const hit = ray.intersectObjects(meshes.filter((m) => m.visible), false)[0];
if (hit) {
const key = hit.object.userData.key;
info.textContent = (INFO[key] || key) + '\n교차점: x=' + hit.point.x.toFixed(2) + ' y=' + hit.point.y.toFixed(2) + ' z=' + hit.point.z.toFixed(2) + ' (m, 모델 좌표)';
let extra = '';
if (M && key.startsWith('lining') && hit.faceIndex != null) {
const n = M.ring_points;
const ring = Math.floor(hit.faceIndex / (2 * (n - 1)));
const sta = M.first_station + ring * M.ring_step_m;
const z = M.patterns.find((z) => sta >= z.from && sta < z.to);
const km = Math.floor(sta / 1000), m = Math.round(sta % 1000);
extra = '\n측점: ' + km + '+' + String(m).padStart(3, '0') + '\n패턴: ' + (z ? z.pattern : '-') + ' (임의 배정, 실제 구간 아님)';
}
info.textContent = (INFO[key] || key) + extra + '\n교차점: x=' + hit.point.x.toFixed(2) + ' y=' + hit.point.y.toFixed(2) + ' z=' + hit.point.z.toFixed(2) + ' (m, 모델 좌표)';
}
});