Skip to content
/ pyrite Public

Pyrite is an experimental render engine, written in Rust

License

Apache-2.0, MIT licenses found

Licenses found

Apache-2.0
LICENSE-APACHE
MIT
LICENSE-MIT
Notifications You must be signed in to change notification settings

Ogeon/pyrite

Repository files navigation

Pyrite (super pre alpha or something)

Build Status

Pyrite is an experimental render engine, written in Rust, and only meant as a learning project. Don't expect it to deliver the same quality as more well established renderers.

It uses various kinds of path tracing and colors based on wavelengths. The idea is to explore the possibilities this gives and to see what kinds of effects chan be achieved that way.

Some notable features:

  • Spectral path tracing. Makes features like dispersion natural.
  • Approximation of RGB colors, as described by Scott Allen Burns.
  • Camera-to-light path tracing and bidirectional path tracing.
  • Loading meshes (.obj only for now) and textures.
  • 3D fractals (like quaternion Julia sets and Mandelbulbs) and other shapes, using distance estimation.
  • Materials, spectra and other values can be combined as parametric values for mor customized effects.

Getting Started

Pyrite is currently only tested on Linux, but it may work on other systems too. To download and build Pyrite using Git and Cargo:

git clone https://github.com/Ogeon/pyrite.git
cd pyrite
cargo build --release

To run Pyrite:

cargo run --release path/to/project.lua

or

target/release/pyrite path/to/project.lua

This will result in an image called render.png in path/to/, by default. Example projects can be found in pyrite/test/.

Project Configuration

Projects are configured using Lua to get access to more flexibility and convenience than formats like JSON, YAML and TOML would provide. For example arithmetics like spectrum(some_spectrum) * spectrum(some_other_spectrum), reusing values, avoiding repetition and being able to programmatically generate configuration.

The format is still in flux, so the examples in pyrite/test/ are the best source of information (outside the renderer code) for now.

Sources And Acknowledgements

This project uses data and a few example assets from external sources:

Data sources:

Example assets:

Contributing

Pyrite exists because it's fun to write and experiment with and you are most welcome to help if you feel like it would be a fun thing to do. Optimizations, beautiful materials, response curves, cool shapes or other improvements are all welcome. Suggestions and interesting reading material is also welcome!

License

Licensed under either of

at your option.

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.

About

Pyrite is an experimental render engine, written in Rust

Resources

License

Apache-2.0, MIT licenses found

Licenses found

Apache-2.0
LICENSE-APACHE
MIT
LICENSE-MIT

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published