Skip to content

Code for "A Multiscale Microfacet Model Based on Inverse Bin Mapping" (Eurographics 2021) by Asen Atanasov, Alexander Wilkie, Vladimir Koylazov and Jaroslav Křivánek

License

Notifications You must be signed in to change notification settings

ChaosGroup/multiscale_microfacet_model

 
 

Repository files navigation

Multiscale microfacet model teaser

A Multiscale Microfacet Model Based on Inverse Bin Mapping

Mitsuba 2 plugin of the paper "A Multiscale Microfacet Model Based on Inverse Bin Mapping" by Asen Atanasov, Alexander Wilkie, Vladimir Koylazov and Jaroslav Křivánek from Eurographics 2021. Note that the original implementation of the method is for "Chaos V-Ray". This Mitsuba 2 plugin was implemented with the sole purpose of comparing it to the related work and is fully contained in /src/bsdfs/glints_ibm.cpp. It is tested only in scalar_rgb mode with the path integrator. This branch is forked from the source code of "Specular Manifold Sampling for Rendering High-Frequency Caustics and Glints" by Zeltner et al. 2020 and contains also the source code of the paper "Position-Normal Distributions for Efficient Rendering of Specular Microstructure" by Yan et al. 2016. Yan's code for writing/reading flat Gaussian elements was partially commented/missing, thus it is retrieved with minimal changes in src/mitsuba/normalmap_to_flakes.cpp and include/mitsuba/render/flake.h respectively.

Compilation

The normal compilation instructions for Mitsuba 2 apply. See the "Getting started" sections in the documentation.

Scenes

Shoes and Kettle scenes by Zeltner et al. 2020 are set up for different methods and are found in results/Figure_19_GlintsComparison. Copies of the original scenes with our proposed BRDF glints_ibm are named shoes_ibm.xml and kettle_ibm.xml. In the paper we present results with different glints_ibm::beckmann_roughness and glints_ibm::tiles parameters.


Mitsuba logo

Mitsuba Renderer 2

Documentation
docs

Mitsuba 2 is a research-oriented rendering system written in portable C++17. It consists of a small set of core libraries and a wide variety of plugins that implement functionality ranging from materials and light sources to complete rendering algorithms. Mitsuba 2 strives to retain scene compatibility with its predecessor Mitsuba 0.6. However, in most other respects, it is a completely new system following a different set of goals.

The most significant change of Mitsuba 2 is that it is a retargetable renderer: this means that the underlying implementations and data structures are specified in a generic fashion that can be transformed to accomplish a number of different tasks. For example:

  1. In the simplest case, Mitsuba 2 is an ordinary CPU-based RGB renderer that processes one ray at a time similar to its predecessor Mitsuba 0.6.

  2. Alternatively, Mitsuba 2 can be transformed into a differentiable renderer that runs on NVIDIA RTX GPUs. A differentiable rendering algorithm is able to compute derivatives of the entire simulation with respect to input parameters such as camera pose, geometry, BSDFs, textures, and volumes. In conjunction with gradient-based optimization, this opens door to challenging inverse problems including computational material design and scene reconstruction.

  3. Another type of transformation turns Mitsuba 2 into a vectorized CPU renderer that leverages Single Instruction/Multiple Data (SIMD) instruction sets such as AVX512 on modern CPUs to efficiently sample many light paths in parallel.

  4. Yet another type of transformation rewrites physical aspects of the simulation: Mitsuba can be used as a monochromatic renderer, RGB-based renderer, or spectral renderer. Each variant can optionally account for the effects of polarization if desired.

In addition to the above transformations, there are several other noteworthy changes:

  1. Mitsuba 2 provides very fine-grained Python bindings to essentially every function using pybind11. This makes it possible to import the renderer into a Jupyter notebook and develop new algorithms interactively while visualizing their behavior using plots.

  2. The renderer includes a large automated test suite written in Python, and its development relies on several continuous integration servers that compile and test new commits on different operating systems using various compilation settings (e.g. debug/release builds, single/double precision, etc). Manually checking that external contributions don't break existing functionality had become a severe bottleneck in the previous Mitsuba 0.6 codebase, hence the goal of this infrastructure is to avoid such manual checks and streamline interactions with the community (Pull Requests, etc.) in the future.

  3. An all-new cross-platform user interface is currently being developed using the NanoGUI library. Note that this is not yet complete.

Compiling and using Mitsuba 2

Please see the documentation for details on how to compile, use, and extend Mitsuba 2.

About

This project was created by Wenzel Jakob. Significant features and/or improvements to the code were contributed by Merlin Nimier-David, Guillaume Loubet, Sébastien Speierer, Delio Vicini, and Tizian Zeltner.

About

Code for "A Multiscale Microfacet Model Based on Inverse Bin Mapping" (Eurographics 2021) by Asen Atanasov, Alexander Wilkie, Vladimir Koylazov and Jaroslav Křivánek

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 83.8%
  • Python 13.1%
  • CMake 1.5%
  • C 0.8%
  • Cuda 0.7%
  • Shell 0.1%