A high-performance, in-editor voxel modeling tool for Unity with optimized mesh generation and seamless workflow integration.
Deltalith provides a complete voxel creation environment directly inside Unity Editor. Build cube-based 3D models, props, characters, and environments without leaving your workflow. The tool features intelligent mesh optimization, vertex color support, and instant asset generation.
- Dedicated 3D viewport with smooth camera controls
- Orbit, pan, and zoom navigation
- Real-time preview with lighting
- Interactive grid display for precise placement
- Isolated rendering system independent of Scene view
- Brush tool with adjustable size (1-8 voxels)
- Color picker with RGB support
- Material ID assignment for multi-material meshes
- Vertex color baking directly into mesh
- Eraser tool for quick removal
- Undo/redo support via Unity's undo system
- 16-slot customizable palette with persistence
- 12-slot recent colors history
- 16 preset colors for quick access
- Hex color input support
- Click-to-select from any palette
- Automatic color saving between sessions
- Greedy meshing algorithm for optimal polygon count
- Automatic face culling removes hidden internal faces
- Submesh generation for material ID separation
- Vertex color support for per-voxel coloring
- Mesh collider generation for raycasting
- 32x32x32 chunk size (32,768 voxels per chunk)
- First block must be placed on ground (y=0)
- Subsequent blocks require adjacency to existing voxels
- Face, edge, and corner adjacency detection
- Automatic snapping to 1x1x1 grid
- Build area constrained to chunk bounds
- Hover preview shows placement location
- Unity mesh asset (.asset) generation
- Ready for MeshFilter assignment
- Preserves vertex colors and materials
- Timestamped export naming
- Automatic folder creation
- Organized export directory structure
- Open Unity Package Manager (Window > Package Manager)
- Click the '+' button and select "Add package from git URL"
- Enter:
https://github.com/SmitBdangar/Deltalith.git - Click 'Add'
- Download or clone this repository
- Copy the
Deltalithfolder into your project'sPackagesdirectory - Unity will automatically detect and import the package
- Unity 2020.3 or later
- .NET Standard 2.0 or higher
- No external dependencies required
- Go to menu:
Deltalith > Voxel Creator - The Deltalith Creator window will open
- Click "New Chunk (Clear)" to start fresh
- Select a color from the palette or color picker
- Adjust brush size if needed (default: 1)
- Left-click in the viewport to place voxels
- Right-click to erase voxels
- Use right-drag to rotate camera
- Use middle-drag to pan camera
- Use scroll wheel to zoom
- Click "Generate Mesh" to update preview
- Click "Export Selected Chunk as Mesh Asset" to save
| Action | Input |
|---|---|
| Place voxel | Left-click |
| Erase voxel | Right-click |
| Rotate camera | Right-drag |
| Pan camera | Middle-drag |
| Zoom camera | Scroll wheel |
| Undo | Ctrl+Z (Unity default) |
Deltalith/
├── Runtime/
│ ├── Deltalith.Runtime.asmdef
│ ├── Voxel.cs # Voxel data structure
│ ├── VoxelChunk.cs # Chunk container (32x32x32)
│ └── VoxelMeshGenerator.cs # Greedy meshing algorithm
│
├── Editor/
│ ├── Deltalith.Editor.asmdef
│ ├── DeltalithCreatorWindow.cs # Main editor window
│ └── DependencyChecker.cs # Package validation
│
├── CHANGELOG.md
├── LICENSE
├── README.md
├── package.json
└── icon.png
Each voxel contains:
- Material ID (byte): 0 = empty, 1-255 = material
- Color (Color32): RGBA vertex color
- Position: Implicit from array index
- Fixed size: 32x32x32 voxels
- 1D array storage for memory efficiency
- Index calculation:
x + size * (y + size * z) - Bounds checking on all operations
The greedy meshing algorithm:
- Analyzes voxel grid in six directions
- Groups adjacent faces with same material
- Extends quads horizontally and vertically
- Culls hidden internal faces
- Generates submeshes per material ID
- Bakes vertex colors into mesh
This typically reduces polygon count by 70-90% compared to naive per-voxel cubes.
- Isolated preview world with dedicated camera
- RenderTexture-based viewport
- Standard shader with vertex color support
- Directional lighting for depth perception
- Transparent hover preview cube
- Grid mesh rendered with line topology
The exported mesh uses Unity's built-in vertex color shader. To use custom materials:
- Create a material with a shader that supports vertex colors
- Assign to the MeshRenderer after export
- Recommended shaders:
- Legacy Shaders/VertexLit
- Custom vertex color shader
- Standard (with vertex color support)
For creating multiple chunks:
- Build and export first chunk
- Click "New Chunk (Clear)" to reset
- Build next chunk
- Export with unique timestamped name
- Combine chunks in scene as needed
- Keep chunk size at 32x32x32 for optimal performance
- Use material IDs to organize submeshes
- Export frequently to avoid data loss
- Clear unused chunks to free memory
- Use the grid toggle to improve viewport FPS
- Maximum chunk size: 32x32x32 voxels
- No multi-chunk editing in single session
- First block must be placed at y=0
- All blocks must be connected (no floating voxels)
- Export supports Unity mesh assets only
- Ensure material supports vertex colors
- Check MeshRenderer has valid material assigned
- Verify mesh has non-zero vertex count
- Check mouse is inside viewport area
- Ensure window has focus
- Try resetting camera with New Chunk
- Use Legacy Shaders/VertexLit or compatible shader
- Ensure material base color is white
- Verify vertex colors are enabled in shader
- First block establishes ground level at y=0
- All subsequent blocks need neighbor connection
- This prevents floating geometry and ensures structural integrity
- Multi-chunk editing and management
- Layer system for complex models
- Selection and copy/paste tools
- Symmetry mode for mirrored editing
- Import existing meshes as voxels
- Animation support for voxel models
- Texture atlas generation
- FBX export support (requires com.unity.formats.fbx)
- OBJ export support
Contributions are welcome! Please follow these guidelines:
- Fork the repository
- Create a feature branch
- Follow Unity C# coding conventions
- Add XML documentation for public APIs
- Test thoroughly in Unity 2020.3+
- Submit a pull request with clear description
MIT License - See LICENSE file for details
- Issues: GitHub Issues
- Documentation: Wiki
- Author: Smit B Dangar
Built for Unity Engine with performance and usability in mind. Inspired by voxel editors like MagicaVoxel and Qubicle, optimized for seamless Unity integration.