Skip to content

Commit 3e8a535

Browse files
authored
Merge branch 'main' into bhata/renderutil-refactor
2 parents 5d1288b + 164768f commit 3e8a535

62 files changed

Lines changed: 1070 additions & 1810 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
build
22
dist
33
.DS_Store
4+
CMakeUserPresets.json

documents/Specification/MaterialX.PBRSpec.md

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -200,16 +200,19 @@ Implementations are expected to preserve energy as the roughness of the surface
200200

201201
The `tint` input colors the reflected and transmitted light but should be left at white (1,1,1) for physically correct results. Setting the `ior` input to zero disables the Fresnel curve, allowing reflectivity to be controlled purely by weight and tint.
202202

203-
The `scatter_mode` controls whether the surface reflects light (`R`), transmits light (`T`), or both (`RT`). In `RT` mode, reflection and transmission occur both when entering and leaving a surface, with their respective intensities controlled by the Fresnel curve. Depending on the IOR and incident angle, total internal reflection may occur even when transmission modes are selected.
203+
Setting `retroreflective` to true switches the BSDF to retroreflection mode, where light is reflected back toward the incoming direction rather than the mirror reflection direction[^Raab2025].
204204

205205
Thin-film iridescence effects[^Belcour2017] may be enabled by setting `thinfilm_thickness` to a non-zero value.
206206

207+
The `scatter_mode` controls whether the surface reflects light (`R`), transmits light (`T`), or both (`RT`). In `RT` mode, reflection and transmission occur both when entering and leaving a surface, with their respective intensities controlled by the Fresnel curve. Depending on the IOR and incident angle, total internal reflection may occur even when transmission modes are selected.
208+
207209
|Port |Description |Type |Default |Accepted Values|
208210
|--------------------|---------------------------------------------------------------|-------|-------------|---------------|
209211
|`weight` |Weight of the BSDF contribution |float |1.0 |[0, 1] |
210212
|`tint` |Color weight to tint the reflected and transmitted light |color3 |1.0, 1.0, 1.0| |
211213
|`ior` |Index of refraction of the surface |float |1.5 | |
212214
|`roughness` |Surface roughness along the tangent and bitangent |vector2|0.05, 0.05 |[0, 1] |
215+
|`retroreflective` |Enable retroreflection mode for the BSDF |boolean|false | |
213216
|`thinfilm_thickness`|Thickness of the iridescent thin-film layer in nanometers |float |0.0 | |
214217
|`thinfilm_ior` |Index of refraction of the thin-film layer |float |1.5 | |
215218
|`normal` |Normal vector of the surface |vector3|Nworld | |
@@ -227,6 +230,8 @@ Implementations are expected to preserve energy as the roughness of the surface
227230

228231
The default values for `ior` and `extinction` represent approximate values for gold.
229232

233+
Setting `retroreflective` to true switches the BSDF to retroreflection mode, where light is reflected back toward the incoming direction rather than the mirror reflection direction[^Raab2025].
234+
230235
Thin-film iridescence effects[^Belcour2017] may be enabled by setting `thinfilm_thickness` to a non-zero value.
231236

232237
|Port |Description |Type |Default |Accepted Values|
@@ -235,6 +240,7 @@ Thin-film iridescence effects[^Belcour2017] may be enabled by setting `thinfilm_
235240
|`ior` |Index of refraction |color3 |0.183, 0.421, 1.373 | |
236241
|`extinction` |Extinction coefficient |color3 |3.424, 2.346, 1.770 | |
237242
|`roughness` |Surface roughness |vector2|0.05, 0.05 |[0, 1] |
243+
|`retroreflective` |Enable retroreflection mode for the BSDF |boolean|false | |
238244
|`thinfilm_thickness`|Thickness of the iridescent thin-film layer in nanometers|float |0.0 | |
239245
|`thinfilm_ior` |Index of refraction of the thin-film layer |float |1.5 | |
240246
|`normal` |Normal vector of the surface |vector3|Nworld | |
@@ -251,10 +257,12 @@ Implementations are expected to preserve energy as the roughness of the surface
251257

252258
The `color82` input provides a multiplier on reflectivity at 82 degrees, useful for capturing the characteristic "dip" in the reflectance curve of metallic surfaces. Setting it to (1,1,1) effectively disables this feature for backward compatibility.
253259

254-
The `scatter_mode` behavior matches that of `dielectric_bsdf`: in `RT` mode, reflection and transmission occur both when entering and leaving a surface, with intensities controlled by the Fresnel curve. Total internal reflection may occur depending on the incident angle.
260+
Setting `retroreflective` to true switches the BSDF to retroreflection mode, where light is reflected back toward the incoming direction rather than the mirror reflection direction[^Raab2025].
255261

256262
Thin-film iridescence effects[^Belcour2017] may be enabled by setting `thinfilm_thickness` to a non-zero value.
257263

264+
The `scatter_mode` behavior matches that of `dielectric_bsdf`: in `RT` mode, reflection and transmission occur both when entering and leaving a surface, with intensities controlled by the Fresnel curve. Total internal reflection may occur depending on the incident angle.
265+
258266
|Port |Description |Type |Default |Accepted Values|
259267
|--------------------|---------------------------------------------------------------|-------|-------------|---------------|
260268
|`weight` |Weight of the BSDF contribution |float |1.0 |[0, 1] |
@@ -263,6 +271,7 @@ Thin-film iridescence effects[^Belcour2017] may be enabled by setting `thinfilm_
263271
|`color90` |Reflectivity per color component at grazing angles |color3 |1.0, 1.0, 1.0| |
264272
|`exponent` |Exponent for Schlick blending between color0 and color90 |float |5.0 | |
265273
|`roughness` |Surface roughness along the tangent and bitangent |vector2|0.05, 0.05 |[0, 1] |
274+
|`retroreflective` |Enable retroreflection mode for the BSDF |boolean|false | |
266275
|`thinfilm_thickness`|Thickness of the iridescent thin-film layer in nanometers |float |0.0 | |
267276
|`thinfilm_ior` |Index of refraction of the thin-film layer |float |1.5 | |
268277
|`normal` |Normal vector of the surface |vector3|Nworld | |
@@ -702,6 +711,8 @@ Path Tracing**, <https://media.disneyanimation.com/uploads/production/publicatio
702711

703712
[^Portsmouth2025]: Portsmouth et al., **EON: A practical energy-preserving rough diffuse BRDF**, <https://www.jcgt.org/published/0014/01/06/>, 2025.
704713

714+
[^Raab2025]: Matthias Raab et al., **The Minimal Retroreflective Microfacet Model**, to appear, 2025
715+
705716
[^Turquin2019]: Emmanuel Turquin, **Practical multiple scattering compensation for microfacet models**, <https://blog.selfshadow.com/publications/turquin/ms_comp_final.pdf>, 2019.
706717

707718
[^Walter2007]: Bruce Walter et al., **Microfacet Models for Refraction through Rough Surfaces**, <https://www.graphics.cornell.edu/~bjw/microfacetbsdf.pdf>, 2007

0 commit comments

Comments
 (0)