feat(rebar): apply 4-bar symmetric vertical stacking offset (±1.5 db, ±0.5 db) to P6 crossties to resolve centre intersection interference

This commit is contained in:
ypshim committed 2026-10-22 17:50:57 +09:00
1 parent a2317caf6c
commit 9900aa6d8e
1 file changed
+10 -6
+10 -6
View File
@@ -214,20 +214,24 @@ export function buildRebar3D(m: PierModel): RebarScene {
for (const z of col.p5) ring('P5', c.k, sc, base + mm(z), rt, NOMINAL_DIAMETER.H19);
for (const z of col.p4) ring('P4', c.k, sc, base + mm(z), rt, NOMINAL_DIAMETER.H19);
const hookP6 = mm(Math.round(hookLength('tie90', NOMINAL_DIAMETER.H16))); // 135 mm
const dP6 = NOMINAL_DIAMETER.H16; // 15.9 mm
const p6Angles = [0, 46.96, 90, 133.04];
for (const z of col.p6Levels) {
for (const deg of [0, 46.96, 90, 133.04]) {
p6Angles.forEach((deg, i) => {
const a = (deg * Math.PI) / 180;
const xA = sc - rt * Math.cos(a);
const zA = -rt * Math.sin(a);
const xB = sc + rt * Math.cos(a);
const zB = rt * Math.sin(a);
const yBar = base + mm(z);
// Vertical stacking offset: ±1.5 db, ±0.5 db to avoid interference at the column centre (Q-C15)
const zOffset = (i - 1.5) * dP6;
const yBar = base + mm(z + zOffset);
// Main crosstie across the diameter
addBar('P6', c.k, [xA, yBar, zA], [xB, yBar, zB], NOMINAL_DIAMETER.H16, COLOR.tie);
addBar('P6', c.k, [xA, yBar, zA], [xB, yBar, zB], dP6, COLOR.tie);
// 90° hooks at both ends turning downward (135 mm, wrapping the tie)
addBar('P6', c.k, [xA, yBar, zA], [xA, yBar - hookP6, zA], NOMINAL_DIAMETER.H16, COLOR.tie);
addBar('P6', c.k, [xB, yBar, zB], [xB, yBar - hookP6, zB], NOMINAL_DIAMETER.H16, COLOR.tie);
}
addBar('P6', c.k, [xA, yBar, zA], [xA, yBar - hookP6, zA], dP6, COLOR.tie);
addBar('P6', c.k, [xB, yBar, zB], [xB, yBar - hookP6, zB], dP6, COLOR.tie);
});
}
}