ProductPromotion
Logo

Rust

made by https://0x3d.site

GitHub - Twinklebear/tray_rust: A toy ray tracer in Rust
A toy ray tracer in Rust. Contribute to Twinklebear/tray_rust development by creating an account on GitHub.
Visit Site

GitHub - Twinklebear/tray_rust: A toy ray tracer in Rust

GitHub - Twinklebear/tray_rust: A toy ray tracer in Rust

tray_rust - A Toy Ray Tracer in Rust

tray_rust is a toy physically based ray tracer built off of the techniques discussed in Physically Based Rendering. It began life as a port of tray to Rust to check out the language but has surpassed it in a few ways. The renderer is currently capable of path tracing, supports triangle meshes (MTL support coming soon), and various physically based material models (including measured data from the MERL BRDF Database). tray_rust also supports rigid body animation along B-spline paths and distributed rendering.

Build Status

Running

Running and passing --help or -h will print out options you can pass to the renderer which are documented in the help. For the more complicated use cases I hope to do some write ups and guides on how to use them (e.g. distributed rendering, animation) but this may take a while. I strongly recommend running the release build as the debug version will be very slow.

Building Your Own Scenes

To position and animate objects, the camera and so on the Blender plugin is the easiest to use. However the plugin is still in development and missing some features like setting materials, changing light properties and such so you'll still currently need to do those by hand in the exported JSON file. For materials take a look at the materials documentation for lights you'll likely just want to change the emission color which is an RGB color plus a strength term.

Start at the documentation for the scene module, there are also a few example scenes included but not all the models are provided. From a clean git clone you should be able to run cornell_box.json and smallpt.json. I plan to add some more simple scenes that show usage of other features like animation to provide examples. The rigid body animation feature is relatively new though so I haven't had time to document it properly yet.

Documentation

Documentation can be found on the project site.

TODO

Sample Renders

In the samples the Buddha, Dragon, Bunny and Lucy statue are from The Stanford Scanning Repository. The Rust logo model was made by Nylithius on BlenderArtists. The Utah teapot used is from Morgan McGuire's page and the monkey head is Blender's Suzanne. I've made minor tweaks to some of the models so for convenience you can find versions that can be easily loaded into the sample scenes here, though the cube model for the Cornell box scene is included. The materials on the Rust logo, Buddha, Dragon and Lucy are from the MERL BRDF Database. Models for running the scenes and links to model sources can be found here.

Render times are formatted as hh:mm:ss and were measured using 144 threads on a machine with four Xeon E7-8890 v3 CPUs. The machine is an early/engineering sample from Intel so your results may differ, but massive thanks to Intel for the hardware! Some older renders are shown as well without timing since they were run on a different machine.

Some more sample renders can be found here. I've also used tray_rust for the past two years at Utah's Teapot Rendering Competition, view my animations for 2015 and 2016. The latter was made using the Blender plugin for modeling and contains more complex motion and sequences.

Model gallery

1920x1080, 4096 samples/pixel. Rendering: 00:43:36.45.

Rust Logo with friends, disk

1920x1080, 4096 samples/pixel. Rendering: 00:49:33.514.

More Resources
to explore the angular.

mail [email protected] to add your project or resources here 🔥.

Related Articles
to learn about angular.

FAQ's
to learn more about Angular JS.

mail [email protected] to add more queries here 🔍.

More Sites
to check out once you're finished browsing here.

0x3d
https://www.0x3d.site/
0x3d is designed for aggregating information.
NodeJS
https://nodejs.0x3d.site/
NodeJS Online Directory
Cross Platform
https://cross-platform.0x3d.site/
Cross Platform Online Directory
Open Source
https://open-source.0x3d.site/
Open Source Online Directory
Analytics
https://analytics.0x3d.site/
Analytics Online Directory
JavaScript
https://javascript.0x3d.site/
JavaScript Online Directory
GoLang
https://golang.0x3d.site/
GoLang Online Directory
Python
https://python.0x3d.site/
Python Online Directory
Swift
https://swift.0x3d.site/
Swift Online Directory
Rust
https://rust.0x3d.site/
Rust Online Directory
Scala
https://scala.0x3d.site/
Scala Online Directory
Ruby
https://ruby.0x3d.site/
Ruby Online Directory
Clojure
https://clojure.0x3d.site/
Clojure Online Directory
Elixir
https://elixir.0x3d.site/
Elixir Online Directory
Elm
https://elm.0x3d.site/
Elm Online Directory
Lua
https://lua.0x3d.site/
Lua Online Directory
C Programming
https://c-programming.0x3d.site/
C Programming Online Directory
C++ Programming
https://cpp-programming.0x3d.site/
C++ Programming Online Directory
R Programming
https://r-programming.0x3d.site/
R Programming Online Directory
Perl
https://perl.0x3d.site/
Perl Online Directory
Java
https://java.0x3d.site/
Java Online Directory
Kotlin
https://kotlin.0x3d.site/
Kotlin Online Directory
PHP
https://php.0x3d.site/
PHP Online Directory
React JS
https://react.0x3d.site/
React JS Online Directory
Angular
https://angular.0x3d.site/
Angular JS Online Directory