feat(view): 지형 모델이 없을 때 교각별 지반 패드를 정사각형으로 표시
- 한 변 = 코핑 길이 + 2 m, 교각 축에 맞춰 코핑 중심에 둠, 지반고 높이 - 패드는 교각별 추정이며 서로 잇지 않음 (지형 면 아님) - 테스트: 상면 네 모서리로 한 변과 대각선 길이 확인 Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
2caed5b87f
commit
844177b40e
2 files changed
+26
-15
No files matched your search
+8
-6
@@ -20,8 +20,8 @@ export const PART_LABELS: Record<PartName, string> = {
|
||||
ground: '지반',
|
||||
};
|
||||
|
||||
/** Ground-level line drawn without a terrain grid (m): length = coping + margin, thin and narrow. */
|
||||
const GROUND_LINE = { margin: 2, thickness: 0.05, width: 0.15 } as const;
|
||||
/** Ground pad drawn without a terrain grid (m): a square of side = coping length + margin, thin. */
|
||||
const GROUND_PAD = { margin: 2, thickness: 0.05 } as const;
|
||||
|
||||
const COLORS: Record<PartName, number> = {
|
||||
coping: 0xb8c2cc,
|
||||
@@ -177,15 +177,17 @@ export function buildPierScene(m: PierModel, terrain?: TerrainGrid): PierScene {
|
||||
}
|
||||
|
||||
// Ground: the terrain grid around the piers when the ground model has one (수 m 떨어진 지형까지 보임).
|
||||
// Without a terrain, only a thin line at this pier's 지반고 across the coping (no surface is assumed, 승인 2026-10-27).
|
||||
// Without a terrain, a thin square pad at this pier's 지반고, side = coping length + 2 m (승인 2026-10-27).
|
||||
// It is a local estimate, not a terrain surface: the pads are not joined to each other.
|
||||
if (terrain) {
|
||||
const material = new THREE.MeshStandardMaterial({ color: COLORS.ground, roughness: 0.9, metalness: 0, transparent: true, opacity: 0.35, side: THREE.DoubleSide });
|
||||
material.userData.baseOpacity = 0.35;
|
||||
parts.ground.add(new THREE.Mesh(terrainGeometry(terrain, m.pivot), material));
|
||||
} else {
|
||||
const line = new THREE.BoxGeometry(m.copingL + GROUND_LINE.margin, GROUND_LINE.thickness, GROUND_LINE.width);
|
||||
line.translate(m.copingL / 2, m.groundEl, 0);
|
||||
add('ground', line, 1);
|
||||
const side = m.copingL + GROUND_PAD.margin;
|
||||
const pad = new THREE.BoxGeometry(side, GROUND_PAD.thickness, side);
|
||||
pad.translate(m.copingL / 2, m.groundEl, 0);
|
||||
add('ground', pad, 0.35);
|
||||
}
|
||||
|
||||
const root = new THREE.Group();
|
||||
|
||||
Reference in new issue
Block a user