Try it live at luxdraft.studio
A 2D lighting design and analysis tool created as a personal project to help with home renovation planning. LuxDraft Studio enables room layout creation, light fixture placement, and real-time illuminance calculations with IES photometric data support.
While built for personal use, it may be useful for anyone planning lighting layouts for their home or small projects.
- Interactive Drawing Tools - Create room layouts with walls, rafters, and architectural features
- Snap-to-Grid System - Precise positioning with intelligent snapping
- Measurement Tools - Real-time distance and dimension measurements
- Undo/Redo History - Full editing history with keyboard shortcuts
- IES Photometric Support - Import and parse industry-standard IES files
- Real-time Calculations - Accurate illuminance (lux) calculations using photometric principles
- Visual Heatmaps - Color-coded illumination visualization across the floor plan
- Dead Zone Detection - Identify under-lit areas below specified thresholds
- Spacing Analysis - Automatic detection of fixture spacing issues
- Light Statistics - Comprehensive metrics including average lux, uniformity ratios, and coverage
- Custom Light Definitions - Create and manage fixture libraries with lumen output and beam angles
- Property Panel - Edit fixture properties, positions, and photometric data
- Multiple View Modes - Switch between design and analysis views
- Auto-save - Automatic persistence to browser local storage
- Theme Support - Dark and light theme options
- Svelte 5 - Reactive UI framework with the latest runes API
- Three.js - 3D graphics for rendering and calculations
- TypeScript - Type-safe development
- Vite (Rolldown) - Fast build tooling with Rolldown bundler
- Vitest - Unit testing framework
- Node.js (v18 or higher recommended)
- npm or yarn package manager
- Git LFS (Large File Storage) - required for image assets
# Install Git LFS if you haven't already
git lfs install
# Clone the repository
git clone <repository-url>
cd lux_draft
# Install dependencies
npm install# Start development server
npm run devOpen your browser to http://localhost:5173 to start designing.
# Build optimized production bundle
npm run build
# Preview production build
npm run preview# Run tests in watch mode
npm test
# Run tests once
npm run test:run| Key | Action |
|---|---|
D |
Switch to Draw mode |
V |
Switch to Select mode |
L |
Switch to Light placement mode / Set manual length (in draw mode) |
M |
Toggle measurement tool |
S |
Toggle grid snap |
Esc |
Cancel current operation / Clear measurement |
Ctrl+Z |
Undo |
Ctrl+Y / Ctrl+Shift+Z |
Redo |
- Press
Dto enter Draw mode - Click to place wall points
- Press
Lto manually enter wall lengths - Complete the room by connecting back to the start point
- Press
Lto enter Light placement mode - Click to place fixtures
- Use the Property Panel to adjust:
- Lumen output
- Beam angle
- Ceiling height
- Fixture names
- Open the Lighting Stats panel to view:
- Average illuminance (lux)
- Minimum/maximum lux values
- Uniformity ratios
- Coverage percentage
- Enable heatmap view to visualize light distribution
- Configure dead zone thresholds to identify under-lit areas
- Review spacing warnings for fixture placement issues
LuxDraft Studio supports industry-standard IES photometric data files:
- Open the Light Definition Manager
- Click "Import IES File"
- Select your
.iesfile - The parser extracts lumen values and calculates beam angles automatically
LuxDraft Studio implements physically-based lighting calculations:
- Inverse Square Law - Light intensity decreases with the square of distance
- Lambert's Cosine Law - Surface illumination based on angle of incidence
- Beam Distribution - Smooth falloff at beam edges using smoothstep interpolation
- Solid Angle Conversion - Accurate lumen-to-candela conversion for spotlights
- Unit Conversion - Proper handling of feet/meters for illuminance calculations
The rendering pipeline uses WebGL shaders for real-time visualization of complex lighting scenarios with multiple fixtures.
Contributions are welcome! Please ensure:
- Code follows existing TypeScript patterns
- Tests are added for new features
- Commits follow conventional commit format
- UI changes maintain design consistency
MIT License
Copyright (c) 2026 LuxDraft Studio
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
- IES file format specification from the Illuminating Engineering Society
- Three.js community for excellent 3D rendering tools
- Svelte team for the reactive framework
Built with precision for lighting designers, architects, and stage technicians.
