1498
« on: 2017-03-27, 11:46:25 »
Hello and welcome to the community!
The way the layered material works is actually very simple once you know how pathtracing renderers work. So being a bit simplifying here, in order to find a color of some point in a scene, you samle a direction and calculate how much light comes from that direction and what color is the result of this light depending on the material. If you average a lot of these samples then, you have a pretty exact idea of what the scene looks like.
Now, what the layered material does is nothing more than just randomly selecting from a set of materials when you are sampling the direction. and the amount then influences the probability with which a given material is selected.
Edit: to be more specific, let me quote the internal documentation: This material simulates stacking of multiple layers of thin materials on each another - the top material is evaluated first, and where its mask is non-white, the one material below it is evaluated, and so on, until the base material is reached