# s-macke/voxelspace

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/s-macke-voxelspace).**

6,760 stars · 295 forks · C · MIT

## Links

- GitHub: https://github.com/s-macke/VoxelSpace
- Homepage: https://s-macke.github.io/VoxelSpace/VoxelSpace.html
- awesome-repositories: https://awesome-repositories.com/repository/s-macke-voxelspace.md

## Topics

`3d-engine` `comanche` `game-comanche` `rendering-algorithms` `rendering-engine` `voxel` `voxel-engine` `voxel-space-engine`

## Description

VoxelSpace is a 2.5D terrain engine and ray casting renderer that produces navigable 3D landscapes from height and color maps. It functions as a real-time voxel landscape viewer and height map visualizer, converting grayscale elevation data into interactive terrain from a first-person viewpoint.

The project implements a voxel space rendering algorithm that projects height maps into 3D landscapes using ray casting and vertical scanlines. It optimizes rendering performance through front-to-back drawing with a y-buffer to skip occluded pixels, and applies level-of-detail distance culling to reduce detail for far-away terrain. The viewing angle can be rotated by transforming map coordinates with a rotation matrix before rendering.

The terrain appearance is driven by sampling elevation and color data from separate 2D arrays, with the final image constructed by drawing one vertical line of pixels per screen column. The landscape can be navigated using keyboard or mouse controls.

## Tags

### Graphics & Multimedia

- [Height Map Terrain Renderers](https://awesome-repositories.com/f/graphics-multimedia/graphics-engines-rendering/scene-management-systems/3d-rendering-engines/3d-map-renderers/height-map-terrain-renderers.md) — Renders a 3D landscape from a height map and color map using ray casting, with a simple and efficient algorithm. ([source](https://cdn.jsdelivr.net/gh/s-macke/voxelspace@master/README.md))
- [Voxel Space Renderers](https://awesome-repositories.com/f/graphics-multimedia/graphics-engines-rendering/rendering/systems/3d-graphics-pipelines/scene-renderers/high-quality-scene-rendering/high-dynamic-range-rendering/video-renderers/scanline-renderers/voxel-space-renderers.md) — A terrain rendering algorithm that projects height maps into 3D landscapes using ray casting and vertical scanlines.
- [View Transform Rotators](https://awesome-repositories.com/f/graphics-multimedia/image-data-rotation-routines/matrix-based-rotations/view-transform-rotators.md) — Rotates the viewing angle by applying a 2D rotation matrix to map coordinates before ray casting.
- [Height Map Visualizers](https://awesome-repositories.com/f/graphics-multimedia/interactive-map-visualizations/height-map-visualizers.md) — A tool that converts grayscale height maps into interactive 3D terrain with color mapping and rotation.
- [Voxel Landscape Viewers](https://awesome-repositories.com/f/graphics-multimedia/real-time-neural-renderers/real-time-3d-rendering-engines/voxel-landscape-viewers.md) — A fly-through terrain viewer that optimizes rendering with front-to-back drawing and level-of-detail culling.
- [Height Map Samplers](https://awesome-repositories.com/f/graphics-multimedia/scalar-color-mapping/height-map-samplers.md) — Drives terrain appearance by reading elevation and color data from separate 2D arrays indexed by map coordinates.
- [Terrain View Rotators](https://awesome-repositories.com/f/graphics-multimedia/image-data-rotation-routines/matrix-based-rotations/terrain-view-rotators.md) — Rotates the viewing angle by transforming map coordinates with a rotation matrix before rendering. ([source](https://cdn.jsdelivr.net/gh/s-macke/voxelspace@master/README.md))

### Game Development

- [2.5D Terrain Engines](https://awesome-repositories.com/f/game-development/first-person-shooter-engines/2-5d-terrain-engines.md) — An engine that renders height and color maps as a navigable 3D landscape from a first-person viewpoint.

### Software Engineering & Architecture

- [Distance-Based Detail Reducers](https://awesome-repositories.com/f/software-engineering-architecture/performance-reliability/performance-optimization/frontend-rendering-loading/rendering-optimizations/level-of-detail-renderers/distance-based-detail-reducers.md) — Reduces rendering detail for distant terrain by sampling the height map at lower resolution based on distance from the viewer.
- [Y-Buffer Culling Utilities](https://awesome-repositories.com/f/software-engineering-architecture/performance-reliability/performance-optimization/frustum-culling-utilities/back-face-culling-utilities/y-buffer-culling-utilities.md) — Optimizes rendering by drawing terrain columns from nearest to farthest and skipping pixels already covered by a y-buffer.
- [Height Map Column Renderers](https://awesome-repositories.com/f/software-engineering-architecture/ray-casting-mapping/height-map-column-renderers.md) — Renders a 2.5D landscape by casting rays from the viewpoint and drawing vertical screen columns based on height map samples.
- [Height Map Ray Casters](https://awesome-repositories.com/f/software-engineering-architecture/ray-casting-mapping/height-map-ray-casters.md) — A renderer that casts rays across a height map to draw vertical columns, simulating depth and occlusion.

### User Interface & Experience

- [Scanline Column Renderers](https://awesome-repositories.com/f/user-interface-experience/column-layout-configurations/vertical-column-layouts/scanline-column-renderers.md) — Constructs the final image by drawing one vertical line of pixels per screen column, clipped to the y-buffer.

### Web Development

- [Terrain Rendering Optimizers](https://awesome-repositories.com/f/web-development/browser-integration-utilities/browser-engines/rendering-performance-optimizations/terrain-rendering-optimizers.md) — Optimizes rendering performance by drawing front-to-back with a y-buffer to skip occluded pixels and applying level-of-detail to reduce far-away detail. ([source](https://cdn.jsdelivr.net/gh/s-macke/voxelspace@master/README.md))

### Part of an Awesome List

- [Terrain Navigation Controllers](https://awesome-repositories.com/f/awesome-lists/devtools/keyboard-and-navigation/terrain-navigation-controllers.md) — Navigates a 2.5D terrain rendered from height and color maps using ray casting, controlled by keyboard or mouse. ([source](https://s-macke.github.io/VoxelSpace/VoxelSpace.html))
