diff --git a/src/components/FenceViewer3D.tsx b/src/components/FenceViewer3D.tsx index 13ddaef..82ef774 100644 --- a/src/components/FenceViewer3D.tsx +++ b/src/components/FenceViewer3D.tsx @@ -88,6 +88,7 @@ export default function FenceViewer3D() { const [hasBarbedWire, setHasBarbedWire] = useState(true); const [hasConcertina, setHasConcertina] = useState(false); const [showRoll, setShowRoll] = useState(true); + const [showBraces, setShowBraces] = useState(false); const [autoRotate, setAutoRotate] = useState(false); const [webGLError, setWebGLError] = useState(false); @@ -386,8 +387,8 @@ export default function FenceViewer3D() { group.add(armMesh); } - // Escoras nos cantos - if (idx === 0 || idx === posts.length - 1 || p.isCorner) { + // Escoras nos cantos e pontas (Contraventamento opcional) + if (showBraces && (idx === 0 || idx === posts.length - 1 || p.isCorner)) { const braceLength = h * 0.95; const braceGeo = new THREE.BoxGeometry(0.08, braceLength, 0.08); const braceMesh = new THREE.Mesh(braceGeo, postMat); @@ -556,7 +557,7 @@ export default function FenceViewer3D() { group.add(rollGroup); } - }, [fenceType, color, height, layout, hasBarbedWire, hasConcertina, showRoll]); + }, [fenceType, color, height, layout, hasBarbedWire, hasConcertina, showRoll, showBraces]); const setCameraView = (type: "geral" | "detalhe" | "topo") => { if (!cameraRef.current || !controlsRef.current) return; @@ -934,6 +935,18 @@ export default function FenceViewer3D() { Adicionar Concertina Perimetral + +