Skip to content

Utah-Graphics-Lab/ReSTIR-Shadow-Maps

Repository files navigation

ReSTIR Shadow Maps

Introduction

  • This repo includes the source code for the following EG 2025 paper

Many-Light Rendering Using ReSTIR-Sampled Shadow Maps
Song Zhang (University of Utah), Daqi Lin (NVIDIA), , Chris Wyman (NVIDIA), Cem Yuksel (University of Utah)
Computer Graphics Forum (Proceedings of Eurographics 2025)
Utah Graphics Research Page

ReSTIR Shadow Maps is a practical method targeting dynamic shadow maps for many light sources in real-time rendering. It computes full-resolution shadow maps for a subset of lights, which is selected with spatiotemporal reservoir resampling (ReSTIR). Its selection strategy automatically regenerates shadow maps for lights with the strongest contributions to pixels in the current camera view. The remaining lights are handled using imperfect shadow maps, which provide low-resolution shadow approximation. It significantly reduces the computation and storage compared to using all full-resolution shadow maps and substantially improve shadow quality compared to handling all lights with imperfect shadow maps.

  • The method is implemented as a render pass under Source\RenderPasses\ReSTIRShadowMaps in Falcor 5.1. See README_Falcor.md for the original README file provided by Falcor 5.1.
  • Two scripts are provided to show how the method works in an animated version of the Bistro scene (from NVIDIA Ocra's Amazon Lumberyard Bistro) and Emerald Square (from NVIDIA Emerald Square City Scene) with hand placed flying emissive teapots. Note: all scenes' emissive lights are actually approxmiated using analytic point/spot lights.
  • Before running the scripts, you need to compile the program and download the scene files following the instruction below.

Prerequisites

How to compile

IMPORTANT: We use git submodules to download dependencies! Downloading the git repository as a .zip (rather than using git clone) will ensure you lack required dependencies, and the build scripts will fail.

After cloning the repository:

  • Remember to download the NVAPI, and extract the content of the zip file into Source/Externals/.packman/ and rename the folder to nvapi.
  • Open Falcor.sln and Build Solution in the ReleaseD3D12 configuration

Run the demo

  • Before running the program, download the Bistro and Emerald Square scenes from Google Drive.
  • Unzip and put everything under Source\RenderPasses\ReSTIRShadowMaps\Data\.
  • Run the Local Windows Debugger in VS.
  • After Mogwai is running, click File -> Load Script -> Source\RenderPasses\ReSTIRShadowMaps\Scripts\__bistro.py or Source\RenderPasses\ReSTIRShadowMaps\Scripts\Emerald_Square.py
  • For specific usage, you can look into the tooltips on each UI widget (i.e. the question mark at the end of each widget, see image below).

About

Source Code for EG 2025 Paper "Many-Light Rendering Using ReSTIR-Sampled Shadow Maps"

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published