pbrt4
A Rust crate to load pbrt-v4 files.
The scene description files used by pbrt are plain text files. The file format was designed so that it would be both easy to parse and easy for applications to generate from their own internal representations of scenes.
A pbrt scene file consists of a series of statements; different statements specify the geometry and light sources in the scene and set overall rendering parameters (such as which light transport algorithm to use or the image resolution).
Resources
- PBR book.
- pbrt-v4 repo.
- The file format documentation.
- pbrt-v4-scenes repo.
Example
let data = read_to_string?;
let scene = load?;
for shape in scene.shapes