Skip to content
Pdawg-bytesPublic

About

A real-time, portable, and deterministic software ray-tracer and ray-marcher written in C++.

Topics

Resources

Stars

6 stars

Watchers

0 watching

Forks

Latest commit

 

History

35 Commits

Folders and files

Repository files navigation

Ether

A real-time, portable, and deterministic software ray-tracer and ray-marcher written in C++.

Features

Lighting

  • Analytical Direct Lighting: Deterministic evaluation for point and directional light sources.
  • Physically Based Shading: Full Cook-Torrance BRDF evaluation via GGX.
  • SDF Ambient Occlusion: Fast proximity occlusion calculated via ray-marched distance fields across all primitives.

Materials

  • Physical Properties: Support for roughness, metalness, and emission properties.
  • Texture Mapping: Optional mapping for albedo, roughness, emission, and bump maps (supports explicit UVs on polygons and planar projection on primitives).
  • Glass Refraction: IOR and Transmission properties for emulating transparent objects.

Geometry

  • Hybrid Representation: Scene-wide Surface Area Heuristic BVH that captures individual primitives alongside an SDF evaluator for CSG trees.
  • Mesh Loading: .obj + .mtl file parser for meshes.
  • Analytic Primitives: Sphere, Box, Plane, Torus, and Cylinder primitives.
  • Constructive Solid Geometry: Full boolean operations supported in CSG trees for all primitives.

Platforms

  • Windows (With multithreading support #define MULTI_THREADED_RENDERING in Raytracer.h)
  • Nintendo 3DS (Runs poorly, more of a proof-of-concept)

Compilation

Windows

  1. Download and install Visual Studio 2026 with the C++ development workload along with Clang-CL support.
  2. Open the Ether solution.
  3. Compile.

3DS

  1. Download and install the devkitPro toolchain and include 3DS support.
  2. Enter the Ether directory and run make.

Usage

In order to use .obj files, you must place them inside of a folder named Data in the root of this repository. All paths in Ether are relative to this folder. Loading an object from Teapot/teapot.obj points to </path/to/repository>/Data/Teapot/teapot.obj. The 3DS build automatically includes this entire folder in the RomFS of the 3dsx.

Examples

OBJ Files

image

Cornell Box

image

Large Object (>320k polygons)

image

Sponza (>260k polygons)

image

Texture Mapping

image

CSG Scene

image

CSG and primitives mixed

image

OBJ Scene on Nintendo 3DS

image

BVH Visualization

image

About

A real-time, portable, and deterministic software ray-tracer and ray-marcher written in C++.

Topics

Resources

Stars

6 stars

Watchers

0 watching

Forks

Releases

Contributors

Languages