RenderKit / ospray

An Open, Scalable, Portable, Ray Tracing Based Rendering Engine for High-Fidelity Visualization
http://ospray.org
Apache License 2.0
1.01k stars 182 forks source link

Principled - Reflectance of the base layer depending on IOR of the coat layer #449

Open Paulfx opened 4 years ago

Paulfx commented 4 years ago

Hi,

I noticed when using a principled material with following parameters : CoatIOR = 1.5, BaseIOR=1.5, and CoatStrength=1 that the base layer still has specular reflection. However, as the coat and the base has the same refractive index, the reflectance at the interface between the coat and the base should be 0, so in theory there shouldn't be any specular reflection under the coat layer.

Can you please explain how you calculate reflectance at this interface ?

Thanks

atafra commented 4 years ago

Hi,

It is common practice in principled materials to control the reflectance of the layers independently, ignoring the IOR of the layer below/above. This makes the material parameters more artist friendly. E.g. see the Autodesk Standard Surface: https://github.com/Autodesk/standard-surface

The OSPRay Principled material follows this convention for better compatibility with other popular material models.