Find your next open-source project

Search by name, purpose, or keyword — or paste a GitHub repository URL

SamG-Coder/SmartImposter

Media & Design

A from-scratch Rust + Vulkan forest renderer that turns distant plants into RTX-evaluated parallax octahedral impostors.

108
10
Rust
MIT
1 day old

What it is

SmartImposter is a from-scratch graphics engine in Rust and Vulkan that renders a large forest entirely with hardware ray tracing — there is no rasterizer. It places roughly 440,899 plants of 14 species; near the camera each plant is a full mesh, while beyond the mesh distance it collapses to a single AABB whose intersection shader ray-marches a baked, BC-compressed hemi-octahedral impostor atlas.

The distinguishing idea is that impostors are procedural geometry: the RT cores traverse and cull a box, then a custom intersection shader marches baked depth (parallax occlusion mapping in orthogonal view space) to find the hit. Lighting is handled with baked self-shadowing plus a per-texel normal spread, so impostors shade close to the real meshes. DLSS Ray Reconstruction can denoise and upscale a single noisy sample per pixel, with a built-in TAA fallback when the SDK is absent (README).

It is aimed at graphics programmers studying ray tracing, impostor-based vegetation LOD and DLSS integration, not at people who just want a ready-made game scene.

Quick start

The repo ships no plant assets, because the Quixel Megaplants and Megascans materials on Fab cannot be redistributed. You need a Vulkan RT-capable GPU (developed on an RTX 5080 with 16 GB), about 4.5 GB of free VRAM at defaults, Rust stable and the Vulkan SDK.

  1. Import the desired Megaplants into a UE 5.x project in Unreal format and export them headlessly with tools/ue_export_megaplants.py.
  2. Convert each exported species with tools/megaplant_to_mtree.py into assets/species/<Species>.mtree and .json; optionally add Megascans grass via tools/grass_to_mtree.py and the four ground surfaces via SI_GROUND_DIR.
  3. Build and run:
cargo run --release

DLSS Ray Reconstruction requires the NVIDIA DLSS SDK, DLSS_SDK set at build time and nvngx_dlssd.dll placed in assets/dlss/; otherwise the engine logs why and falls back to TAA. Command-line flags such as --dlss, --fly, --species, --shot and --bench-move cover capture, benchmarking and asset loadouts. See the getting-started section for the exact converter commands.

Constraints

  • Hardware ray tracing is mandatory (VK_KHR_ray_tracing_pipeline, VK_KHR_acceleration_structure); there is no rasterized path.
  • The full default asset set needs roughly 3.2 GB of impostor atlases and plant/ground textures; --imp-res, --imp-texel, SI_TEX_MAX or --species reduce this.
  • assets/species must be built from your own Fab licenses; license restrictions forbid bundling the assets.
  • Known limits include upward close-range views of impostors showing vertical streaking (the atlases cover only the upper hemisphere), no wind animation, repeating grass patch layouts visible from high up, front-lit poplar impostors about 1.2x brighter than meshes, and grainy LOD bands at low frame rates (limitations).
  • The code is MIT-licensed; Quixel assets and the NVIDIA DLSS SDK/runtime remain under their own licenses (license).

HotRepo's take

The project entered HotRepo's Rust new-project list on 2026-11-18 with 108 stars and 7 stars gained in a roughly 1.5-hour window, alongside 10 forks; it has no recorded all-language daily rank. That is a small, early sample, so it says little about adoption. The more substantive point is scope: the README documents a complete, measured pipeline — 8.0 ms/frame at 1440p with DLSS-RR Quality and 15.4 ms with DLAA on an RTX 5080, a ~5.3 s startup bake for 52 atlases, and before/after numbers for Shader Execution Reordering and CPU/GPU overlap. The asset-conversion toolchain means anyone reproducing the scene must own the Fab assets, which limits easy experimentation but keeps the repository a focused study of impostor ray tracing rather than a plug-and-play demo.

Written by AI from the project's README, updated . The project's own docs are the source of truth.