Rust crate to implement at least parts of the PBRT book's C++ code. See also https://www.rs-pbrt.org/about ...
Go to file
Jan Walter 1502536c29 [rust-mode] Use rust-run-clippy to optimize the code a bit. 2023-09-09 10:27:14 +02:00
docs Prepare v0.9.10 release. 2023-09-01 21:25:52 +02:00
examples For command line options switch from structopt to clap. 2022-11-05 15:29:55 +01:00
profile Start profiling via cpuprofiler crate. 2017-10-06 11:11:50 +02:00
src [rust-mode] Use rust-run-clippy to optimize the code a bit. 2023-09-09 10:27:14 +02:00
wix cargo wix -v init --force 2022-03-10 15:41:00 +01:00
.build.yml Fix build manifest for sourcehut (one help rule for each bin file). 2022-03-09 15:34:52 +01:00
.clippy.toml [clippy] needless_range_loop, too_many_arguments. 2020-01-30 11:16:12 +00:00
.gitignore Do not check in Cargo.lock files. 2022-06-23 16:49:42 +02:00
.travis.yml Travis fails far too often. Let's try this. 2019-06-12 07:32:51 +01:00
Cargo.toml Prepare v0.9.10 release. 2023-09-01 21:25:52 +02:00
LICENSE Dual license file for sourcehut. Badge about sr.ht build. 2021-12-27 17:58:54 +01:00
LICENSE-APACHE Dual license file for sourcehut. Badge about sr.ht build. 2021-12-27 17:58:54 +01:00
LICENSE-MIT Dual license file for sourcehut. Badge about sr.ht build. 2021-12-27 17:58:54 +01:00
LICENSE.rtf Upgrade crates image, num_cpus, pest[_derive], and smallvec. 2022-11-05 13:10:51 +01:00
Makefile Move parse_blend_file.rs from examples folder to src/bin. 2022-03-09 15:27:40 +01:00
OpenEXR.txt [skip ci] Add './bootstrap' step and bash environment. 2017-10-26 15:55:56 +02:00
README.md Prepare v0.9.10 release. 2023-09-01 21:25:52 +02:00
about.hbs Change to dual licensed (Apache 2.0 & MIT). Update crates. 2020-09-24 15:01:33 +02:00
about.toml Change to dual licensed (Apache 2.0 & MIT). Update crates. 2020-09-24 15:01:33 +02:00
license.html Prepare v0.8.3 release. 2020-10-12 12:25:09 +02:00

README.md

rs_pbrt

crates.io Documentation Status dependency status builds.sr.ht status

You can find more information about rs_pbrt at https://www.rs-pbrt.org/about ...

Rust crate to implement a counterpart to the PBRT book's (3rd edition) C++ code:

http://www.pbrt.org

Current Rust (development) documentation:

https://www.janwalter.org/doc/rust/rs_pbrt/index.html or https://www.rs-pbrt.org/doc/crates/rs_pbrt/index.html

Usage

> cargo build --release --no-default-features
> ./target/release/rs_pbrt --help
rs_pbrt version 0.9.10 (unknown) [Detected 28 cores]

Physically based rendering (PBR) with Rust

Usage: rs_pbrt [OPTIONS] --path <PATH>

Options:
      --cropx0 <CROPX0>          Specify an image crop window <x0 x1 y0 y1> [default: 0.0]
      --cropx1 <CROPX1>          Specify an image crop window <x0 x1 y0 y1> [default: 1.0]
      --cropy0 <CROPY0>          Specify an image crop window <x0 x1 y0 y1> [default: 0.0]
      --cropy1 <CROPY1>          Specify an image crop window <x0 x1 y0 y1> [default: 1.0]
  -i, --integrator <INTEGRATOR>  ao, directlighting, whitted, path, bdpt, mlt, sppm, volpath
  -t, --nthreads <NTHREADS>      use specified number of threads for rendering [default: 0]
  -s, --samples <SAMPLES>        pixel samples [default: 0]
  -p, --path <PATH>              The path to the file to read
  -h, --help                     Print help information
  -V, --version                  Print version information

Test Scenes

Some images of the test scenes are shown below, but you can find more test scenes on GitLab.

Ganesha Statue

Very detailed scan of a small statue with over 4.3 million triangles, illuminated by a few area light sources.

Ganesha Statue

The scene can be found within the GitLab repository (pbrt_ganesha.tar.gz).

Subsurface Scattering (SSS)

SSS Dragon

The scene can be found within the GitLab repository (sss_dragon.tar.gz).

Stochastic Progressive Photon Mapping (SPPM)

SPPM CausticGlass

The scene can be found within the GitLab repository (caustic_glass.tar.gz).

Ecosystem (Cover image for the first edition of the PBRT book)

Ecosystem

The scene can be found within the GitLab repository (pbrt_ecosys.tar.gz).

Landscape (Cover image for the third edition of the PBRT book)

Landscape

Hair

The hair scattering model in action:

Curly and straight hair rendered by Rust version ofPBRT

The scene can be found within the GitLab repository (pbrt_hair.tar.gz).

Japanes Classroom by NovaZeeke

Classroom room rendered byrs_pbrt

The scene can be found within the GitLab repository (bitterli_classroom.tar.gz).

The White Room by Jay-Artist

The White Room rendered byrs_pbrt

The scene can be found within the GitLab repository (bitterli_living-room-2.tar.gz).

Country Kitchen by Jay-Artist

Kitchen rendered byrs_pbrt

The scene can be found within the GitLab repository (bitterli_kitchen.tar.gz).

The Wooden Staircase by Wig42

Staircase rendered byrs_pbrt

The scene can be found within the GitLab repository (bitterli_staircase.tar.gz).

Conference Room by Anat Grynberg and Greg Ward

Conference room rendered byrs_pbrt

The scene can be found within the GitLab repository (radiance_conference_room folder).

Theater by Charles Ehrlich and Greg Ward

Theater rendered byrs_pbrt

Theater rendered byrs_pbrt

The scene can be found within the GitLab repository (radiance_theater folder).

For more information check out the rs-pbrt web page.

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.