|
|
|
@@ -4,6 +4,7 @@ import { Grid, Environment, Text } from '@react-three/drei';
|
|
|
|
|
import { ViewerOrbitControls as OrbitControls } from './three/ViewerOrbitControls';
|
|
|
|
|
import * as THREE from 'three';
|
|
|
|
|
import { useGalpaoStore } from '../store/galpaoStore';
|
|
|
|
|
import { AirflowSystem } from './three/AirflowSystem';
|
|
|
|
|
import { useWindStore } from '../store/appStore';
|
|
|
|
|
import SceneCanvas from './SceneCanvas';
|
|
|
|
|
import FallbackDiagram from './FallbackDiagram';
|
|
|
|
@@ -34,6 +35,8 @@ function PressureArrow({
|
|
|
|
|
p: number;
|
|
|
|
|
}) {
|
|
|
|
|
const { q } = useWindStore();
|
|
|
|
|
const { viewMode } = useGalpaoStore();
|
|
|
|
|
if (viewMode === 'airflow') return null;
|
|
|
|
|
const force = p * q; // kN/m2
|
|
|
|
|
|
|
|
|
|
const normVec = useMemo(() => new THREE.Vector3(...normal).normalize(), [normal]);
|
|
|
|
@@ -63,12 +66,12 @@ function PressureArrow({
|
|
|
|
|
{length - headLen > 0 && (
|
|
|
|
|
<mesh position={mid.toArray()} rotation={[quat.x, quat.y, quat.z]}>
|
|
|
|
|
<cylinderGeometry args={[0.08, 0.08, length - headLen, 8]} />
|
|
|
|
|
<meshStandardMaterial color={color} />
|
|
|
|
|
<meshStandardMaterial color={color} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
)}
|
|
|
|
|
<mesh position={end.toArray()} rotation={[quat.x, quat.y, quat.z]}>
|
|
|
|
|
<coneGeometry args={[0.2, headLen, 8]} />
|
|
|
|
|
<meshStandardMaterial color={color} />
|
|
|
|
|
<meshStandardMaterial color={color} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
</group>
|
|
|
|
|
);
|
|
|
|
@@ -131,7 +134,7 @@ export function WarehouseModel() {
|
|
|
|
|
const { invalidate } = useThree();
|
|
|
|
|
const theme = useCanvasTheme();
|
|
|
|
|
const isDark = theme === 'dark';
|
|
|
|
|
const { width, length, height, roofPitch, wallCpe, roofCpe, template, extraHeight, skirtHeight } = useGalpaoStore();
|
|
|
|
|
const { width, length, height, roofPitch, wallCpe, roofCpe, template, extraHeight, skirtHeight, viewMode } = useGalpaoStore();
|
|
|
|
|
const { windAngle, cpi, permeabilityCase } = useWindStore();
|
|
|
|
|
|
|
|
|
|
useEffect(() => {
|
|
|
|
@@ -181,26 +184,26 @@ export function WarehouseModel() {
|
|
|
|
|
return (
|
|
|
|
|
<group>
|
|
|
|
|
{/* === PAREDES === */}
|
|
|
|
|
{showMainWalls && (
|
|
|
|
|
{showMainWalls && viewMode === 'solid' && (
|
|
|
|
|
<group>
|
|
|
|
|
{/* Lateral Esquerda (X = -width/2, Parede C) */}
|
|
|
|
|
<group position={[-width / 2, height / 2, 0]}>
|
|
|
|
|
<mesh position={[0, 0, -length / 4]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[wallThickness, height, length / 2]} />
|
|
|
|
|
<meshStandardMaterial color={wallCColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={wallCColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[0, 0, -length / 4]} normal={[-1, 0, 0]} p={wallCpe.C - cpi} />
|
|
|
|
|
|
|
|
|
|
<mesh position={[0, 0, length / 4]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[wallThickness, height, length / 2]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallDColor : wallCColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallDColor : wallCColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[0, 0, length / 4]} normal={[-1, 0, 0]} p={(isParallel ? wallCpe.D : wallCpe.C) - cpi} />
|
|
|
|
|
|
|
|
|
|
{hasOpening('C', permeabilityCase, windAngle) && (
|
|
|
|
|
<mesh position={[-wallThickness/2 - 0.01, -height/4, 0]}>
|
|
|
|
|
<boxGeometry args={[0.05, height * 0.5, length * 0.15]} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.9} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.9} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
)}
|
|
|
|
|
</group>
|
|
|
|
@@ -209,20 +212,20 @@ export function WarehouseModel() {
|
|
|
|
|
<group position={[width / 2, height / 2, 0]}>
|
|
|
|
|
<mesh position={[0, 0, -length / 4]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[wallThickness, height, length / 2]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallCColor : wallDColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallCColor : wallDColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[0, 0, -length / 4]} normal={[1, 0, 0]} p={(isParallel ? wallCpe.C : wallCpe.D) - cpi} />
|
|
|
|
|
|
|
|
|
|
<mesh position={[0, 0, length / 4]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[wallThickness, height, length / 2]} />
|
|
|
|
|
<meshStandardMaterial color={wallDColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={wallDColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[0, 0, length / 4]} normal={[1, 0, 0]} p={wallCpe.D - cpi} />
|
|
|
|
|
|
|
|
|
|
{hasOpening('D', permeabilityCase, windAngle) && (
|
|
|
|
|
<mesh position={[wallThickness/2 + 0.01, -height/4, 0]}>
|
|
|
|
|
<boxGeometry args={[0.05, height * 0.5, length * 0.15]} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.9} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.9} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
)}
|
|
|
|
|
</group>
|
|
|
|
@@ -231,20 +234,20 @@ export function WarehouseModel() {
|
|
|
|
|
<group position={[0, height / 2, -length / 2]}>
|
|
|
|
|
<mesh position={[-width / 4, 0, 0]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[width / 2, height, wallThickness]} />
|
|
|
|
|
<meshStandardMaterial color={wallAColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={wallAColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[-width / 4, 0, 0]} normal={[0, 0, -1]} p={wallCpe.A - cpi} />
|
|
|
|
|
|
|
|
|
|
<mesh position={[width / 4, 0, 0]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[width / 2, height, wallThickness]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallAColor : wallBColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallAColor : wallBColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[width / 4, 0, 0]} normal={[0, 0, -1]} p={(isParallel ? wallCpe.A : wallCpe.B) - cpi} />
|
|
|
|
|
|
|
|
|
|
{hasOpening('A', permeabilityCase, windAngle) && (
|
|
|
|
|
<mesh position={[0, -height/4, -wallThickness/2 - 0.01]}>
|
|
|
|
|
<boxGeometry args={[width * 0.3, height * 0.5, 0.05]} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.9} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.9} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
)}
|
|
|
|
|
</group>
|
|
|
|
@@ -253,20 +256,20 @@ export function WarehouseModel() {
|
|
|
|
|
<group position={[0, height / 2, length / 2]}>
|
|
|
|
|
<mesh position={[-width / 4, 0, 0]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[width / 2, height, wallThickness]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallBColor : wallAColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallBColor : wallAColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[-width / 4, 0, 0]} normal={[0, 0, 1]} p={(isParallel ? wallCpe.B : wallCpe.A) - cpi} />
|
|
|
|
|
|
|
|
|
|
<mesh position={[width / 4, 0, 0]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[width / 2, height, wallThickness]} />
|
|
|
|
|
<meshStandardMaterial color={wallBColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={wallBColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[width / 4, 0, 0]} normal={[0, 0, 1]} p={wallCpe.B - cpi} />
|
|
|
|
|
|
|
|
|
|
{hasOpening('B', permeabilityCase, windAngle) && (
|
|
|
|
|
<mesh position={[0, -height/4, wallThickness/2 + 0.01]}>
|
|
|
|
|
<boxGeometry args={[width * 0.3, height * 0.5, 0.05]} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.9} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.9} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
)}
|
|
|
|
|
</group>
|
|
|
|
@@ -279,22 +282,22 @@ export function WarehouseModel() {
|
|
|
|
|
{/* Platibanda Traseira */}
|
|
|
|
|
<mesh position={[0, height + extraHeight / 2, -length / 2]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[width, extraHeight, wallThickness]} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
{/* Platibanda Frontal */}
|
|
|
|
|
<mesh position={[0, height + extraHeight / 2, length / 2]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[width, extraHeight, wallThickness]} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
{/* Platibanda Esquerda */}
|
|
|
|
|
<mesh position={[-width / 2, height + extraHeight / 2, 0]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[wallThickness, extraHeight, length]} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
{/* Platibanda Direita */}
|
|
|
|
|
<mesh position={[width / 2, height + extraHeight / 2, 0]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[wallThickness, extraHeight, length]} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
</group>
|
|
|
|
|
)}
|
|
|
|
@@ -305,22 +308,22 @@ export function WarehouseModel() {
|
|
|
|
|
{/* Saia Traseira */}
|
|
|
|
|
<mesh position={[0, height - skirtHeight / 2, -length / 2]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[width, skirtHeight, wallThickness]} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
{/* Saia Frontal */}
|
|
|
|
|
<mesh position={[0, height - skirtHeight / 2, length / 2]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[width, skirtHeight, wallThickness]} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
{/* Saia Esquerda */}
|
|
|
|
|
<mesh position={[-width / 2, height - skirtHeight / 2, 0]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[wallThickness, skirtHeight, length]} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
{/* Saia Direita */}
|
|
|
|
|
<mesh position={[width / 2, height - skirtHeight / 2, 0]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[wallThickness, skirtHeight, length]} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={extraColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
</group>
|
|
|
|
|
)}
|
|
|
|
@@ -330,11 +333,11 @@ export function WarehouseModel() {
|
|
|
|
|
<group position={[0, height, length / 2]}>
|
|
|
|
|
<mesh>
|
|
|
|
|
<shapeGeometry args={[leftShape]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallBColor : wallCColor} side={THREE.DoubleSide} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallBColor : wallCColor} side={THREE.DoubleSide} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<mesh>
|
|
|
|
|
<shapeGeometry args={[rightShape]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallBColor : wallDColor} side={THREE.DoubleSide} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallBColor : wallDColor} side={THREE.DoubleSide} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
</group>
|
|
|
|
|
|
|
|
|
@@ -342,11 +345,11 @@ export function WarehouseModel() {
|
|
|
|
|
<group position={[0, height, -length / 2]} rotation={[0, Math.PI, 0]}>
|
|
|
|
|
<mesh>
|
|
|
|
|
<shapeGeometry args={[leftShape]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallAColor : wallDColor} side={THREE.DoubleSide} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallAColor : wallDColor} side={THREE.DoubleSide} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<mesh>
|
|
|
|
|
<shapeGeometry args={[rightShape]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallAColor : wallCColor} side={THREE.DoubleSide} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? wallAColor : wallCColor} side={THREE.DoubleSide} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
</group>
|
|
|
|
|
|
|
|
|
@@ -356,47 +359,47 @@ export function WarehouseModel() {
|
|
|
|
|
{/* Seg 1 (Traseiro-Fim) */}
|
|
|
|
|
<mesh position={[0, 0, -3 * length / 8]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.08, length / 4]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofEColor : roofEColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofEColor : roofEColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[0, 0.04, -3 * length / 8]} normal={[0, 1, 0]} p={roofCpe.E - cpi} />
|
|
|
|
|
|
|
|
|
|
{/* Seg 2 (Traseiro-Meio) */}
|
|
|
|
|
<mesh position={[0, 0, -length / 8]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.08, length / 4]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofFColor : roofFColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofFColor : roofFColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[0, 0.04, -length / 8]} normal={[0, 1, 0]} p={roofCpe.F - cpi} />
|
|
|
|
|
|
|
|
|
|
{/* Seg 3 (Frontal-Meio) */}
|
|
|
|
|
<mesh position={[0, 0, length / 8]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.08, length / 4]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofGColor : roofFColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofGColor : roofFColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[0, 0.04, length / 8]} normal={[0, 1, 0]} p={(isParallel ? roofCpe.G : roofCpe.F) - cpi} />
|
|
|
|
|
|
|
|
|
|
{/* Seg 4 (Frontal-Fim) */}
|
|
|
|
|
<mesh position={[0, 0, 3 * length / 8]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.08, length / 4]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofHColor : roofEColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofHColor : roofEColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[0, 0.04, 3 * length / 8]} normal={[0, 1, 0]} p={(isParallel ? roofCpe.H : roofCpe.E) - cpi} />
|
|
|
|
|
|
|
|
|
|
{/* Linhas de Divisão das Zonas no Telhado */}
|
|
|
|
|
<mesh position={[0, 0.05, -length / 4]}>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.02, 0.06]} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<mesh position={[0, 0.05, 0]}>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.02, 0.06]} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<mesh position={[0, 0.05, length / 4]}>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.02, 0.06]} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<mesh position={[-widthSlope * 0.35, 0.05, 0]}>
|
|
|
|
|
<boxGeometry args={[0.06, 0.02, length]} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
|
|
|
|
|
{/* Rótulo e Título da Água */}
|
|
|
|
@@ -487,47 +490,47 @@ export function WarehouseModel() {
|
|
|
|
|
{/* Seg 1 (Traseiro-Fim) */}
|
|
|
|
|
<mesh position={[0, 0, -3 * length / 8]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.08, length / 4]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofEColor : roofGColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofEColor : roofGColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[0, 0.04, -3 * length / 8]} normal={[0, 1, 0]} p={(isParallel ? roofCpe.E : roofCpe.G) - cpi} />
|
|
|
|
|
|
|
|
|
|
{/* Seg 2 (Traseiro-Meio) */}
|
|
|
|
|
<mesh position={[0, 0, -length / 8]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.08, length / 4]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofFColor : roofHColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofFColor : roofHColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[0, 0.04, -length / 8]} normal={[0, 1, 0]} p={(isParallel ? roofCpe.F : roofCpe.H) - cpi} />
|
|
|
|
|
|
|
|
|
|
{/* Seg 3 (Frontal-Meio) */}
|
|
|
|
|
<mesh position={[0, 0, length / 8]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.08, length / 4]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofGColor : roofHColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofGColor : roofHColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[0, 0.04, length / 8]} normal={[0, 1, 0]} p={(isParallel ? roofCpe.G : roofCpe.H) - cpi} />
|
|
|
|
|
|
|
|
|
|
{/* Seg 4 (Frontal-Fim) */}
|
|
|
|
|
<mesh position={[0, 0, 3 * length / 8]} castShadow receiveShadow>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.08, length / 4]} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofHColor : roofGColor} roughness={0.4} />
|
|
|
|
|
<meshStandardMaterial color={isParallel ? roofHColor : roofGColor} roughness={0.4} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<PressureArrow center={[0, 0.04, 3 * length / 8]} normal={[0, 1, 0]} p={(isParallel ? roofCpe.H : roofCpe.G) - cpi} />
|
|
|
|
|
|
|
|
|
|
{/* Linhas de Divisão das Zonas no Telhado */}
|
|
|
|
|
<mesh position={[0, 0.05, -length / 4]}>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.02, 0.06]} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<mesh position={[0, 0.05, 0]}>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.02, 0.06]} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<mesh position={[0, 0.05, length / 4]}>
|
|
|
|
|
<boxGeometry args={[widthSlope, 0.02, 0.06]} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<mesh position={[widthSlope * 0.35, 0.05, 0]}>
|
|
|
|
|
<boxGeometry args={[0.06, 0.02, length]} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} />
|
|
|
|
|
<meshStandardMaterial color="#0f172a" roughness={0.5} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
|
|
|
|
|
{/* Rótulo e Título da Água */}
|
|
|
|
@@ -616,19 +619,21 @@ export function WarehouseModel() {
|
|
|
|
|
{/* Cumeeira */}
|
|
|
|
|
<mesh position={[0, height + roofHeight + 0.02, 0]}>
|
|
|
|
|
<boxGeometry args={[0.08, 0.04, length + 0.1]} />
|
|
|
|
|
<meshStandardMaterial color={isDark ? "#475569" : "#2d3748"} roughness={0.5} />
|
|
|
|
|
<meshStandardMaterial color={isDark ? "#475569" : "#2d3748"} roughness={0.5} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
|
|
|
|
|
{/* Bordas Laterais do Telhado (Beirais) */}
|
|
|
|
|
<mesh position={[width / 2 + 0.02, height, 0]}>
|
|
|
|
|
<boxGeometry args={[0.04, 0.08, length]} />
|
|
|
|
|
<meshStandardMaterial color={isDark ? "#475569" : "#2d3748"} />
|
|
|
|
|
<meshStandardMaterial color={isDark ? "#475569" : "#2d3748"} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
<mesh position={[-width / 2 - 0.02, height, 0]}>
|
|
|
|
|
<boxGeometry args={[0.04, 0.08, length]} />
|
|
|
|
|
<meshStandardMaterial color={isDark ? "#475569" : "#2d3748"} />
|
|
|
|
|
<meshStandardMaterial color={isDark ? "#475569" : "#2d3748"} transparent={viewMode === 'airflow'} opacity={viewMode === 'airflow' ? 0.35 : 1} />
|
|
|
|
|
</mesh>
|
|
|
|
|
|
|
|
|
|
{viewMode === 'airflow' && <AirflowSystem windAngle={windAngle} width={width} length={length} height={height} permeabilityCase={permeabilityCase} />}
|
|
|
|
|
|
|
|
|
|
{/* === RÓTULOS 3D === */}
|
|
|
|
|
{showMainWalls && (
|
|
|
|
|
<group>
|
|
|
|
|