feat(abut-rebar): ③ 교대 날개벽 3D 철근 (WR1–WR20, 좌 · 우)
- 날개벽 배근 경로(교대 s · t · z)를 교대 3D 철근에 추가. 선택 · 색 기준 공통 - 테스트: 철근표 = 3D 개수 (양측), 벽체 전면 뒤 · 저판 하면망 위 Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
bac087ce63
commit
e3c9ad0953
3 files changed
+49
-6
No files matched your search
@@ -12,6 +12,8 @@ import { abutSkewK } from '../src/view/abut-scene';
|
||||
import { buildAbutRebar3D } from '../src/view/abut-rebar3d';
|
||||
import { abutWallGeom, abutWallRebar } from '../src/core/abut/rebar/wall';
|
||||
import { abutParapetGeom, abutParapetRebar } from '../src/core/abut/rebar/parapet';
|
||||
import { abutWingGeom, abutWingRebar } from '../src/core/abut/rebar/wing';
|
||||
import { buildWings } from '../src/core/abut/wings';
|
||||
|
||||
// 예제 A1 (교대확대기초철근.md §13).
|
||||
const RAG = fileURLToPath(new URL('../../../RAG/운곡교P1입력.xlsx', import.meta.url));
|
||||
@@ -131,3 +133,28 @@ describe('교대 흉벽 · 브라켓 3D 철근 (③, 2026-11-04)', () => {
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
describe('교대 날개벽 3D 철근 (③, 2026-11-04)', () => {
|
||||
const footing = abutFootingRebar(geom);
|
||||
const wingsR = buildWings(model, members).map((w) => abutWingRebar(abutWingGeom(model, members, w, footing.z.B68)));
|
||||
const scene = buildAbutRebar3D(geom, footing, k, back, bottom, undefined, undefined, wingsR);
|
||||
|
||||
it('draws both wings: every WR bar (one tube per straight piece), 좌 + 우', () => {
|
||||
expect(wingsR.length).toBe(2);
|
||||
const marks = new Set(wingsR.flatMap((r) => r.bars.map((b) => b.mark)));
|
||||
for (const m of marks) {
|
||||
const pieces = wingsR.flatMap((r) => r.paths.filter((p) => p.mark === m)).reduce((a, p) => a + p.pts.length - 1, 0);
|
||||
expect(scene.byName.get(m)?.length, m).toBe(pieces);
|
||||
}
|
||||
});
|
||||
|
||||
it('wing bars lie behind the 벽체 전면 and above the 저판 하면망', () => {
|
||||
const box = new THREE.Box3();
|
||||
for (const r of wingsR) for (const b of r.bars) for (const mesh of scene.byName.get(b.mark)!) {
|
||||
mesh.geometry.computeBoundingBox();
|
||||
box.copy(mesh.geometry.boundingBox!);
|
||||
expect(box.max.z, b.mark).toBeLessThan(members.shape.wallFrontM);
|
||||
expect(box.min.y, b.mark).toBeGreaterThan(bottom + footing.z.B68 / 1000 - (b.mark === 'WR6' ? 0.8 : 0.4));
|
||||
}
|
||||
});
|
||||
});
|
||||
Reference in new issue
Block a user