How tejas-raskar/solarbipv works
SolarBIPV is an interactive 3D city viewer for estimating building rooftop solar potential. Users enter the model, adjust date and time, select a building, and receive rooftop area, shading, irradiance, and BIPV power estimates. The graph separates navigation and guidance, scene composition, rooftop analysis, and solar calculations. The README and excerpts establish the calculation stages; unsampled model details are represented only where the tree or explicit imports support them.
Main entry points: Scene.jsx Scene composition · CityModel.jsx Interactive city · App.jsx App routing · sunPosition.js Sun position and controls
Components 19
Navigation and guidance
- App routing
src/App.jsx - Landing page
src/pages/Landing.jsx - Hero presentation
src/components/Hero.jsx - Method documentation
src/pages/Docs.jsx
3D city scene
- Model page
src/pages/Model.jsx - Scene composition
src/components/Scene.jsx - Interactive city
src/components/CityModel.jsx - Road geometry
src/components/RoadModel.jsx - Vegetation
src/components/Vegetation.jsx - Cloud layer
src/components/Clouds.jsx - Ground plane
src/components/Ground.jsx - City model asset
public/assets/ny_noDecimate.glb
Rooftop analysis
- Rooftop detection and area
src/utils/rooftopArea.js - Rooftop highlighting
src/utils/highlightRooftops.js
Solar calculations
- Sun position and controls
src/utils/sunPosition.js - Shadow fraction
src/utils/bipvCalculation.js - Irradiance and power
src/utils/bipvCalculation.js
Other components
- User
- SunCalc library
Connections 18
- User → App routing: opens
- App routing → Landing page: routes to
src/App.jsx - App routing → Model page: routes to
src/App.jsx - App routing → Method documentation: routes to
src/App.jsx - Landing page → Hero presentation: renders
src/pages/Landing.jsx - Model page → Scene composition: renders
src/pages/Model.jsx - Scene composition → Interactive city: renders
src/components/Scene.jsx - Scene composition → Road geometry: renders
src/components/Scene.jsx - Scene composition → Vegetation: renders
src/components/Scene.jsx - Scene composition → Cloud layer: renders
src/components/Scene.jsx - Scene composition → Ground plane: renders
src/components/Scene.jsx - Interactive city → City model asset: loads
src/components/CityModel.jsx - Interactive city → Rooftop detection and area: calculates area
src/components/CityModel.jsx - Interactive city → Rooftop highlighting: creates highlight
src/components/CityModel.jsx - Interactive city → Irradiance and power: calculates power
src/components/CityModel.jsx - Irradiance and power → Sun position and controls: gets sun data
src/utils/bipvCalculation.js - Sun position and controls → SunCalc library: gets position
src/utils/sunPosition.js - Scene composition → Sun position and controls: updates light
src/components/Scene.jsx