It allows to implement tricks based on a knowledge whether the path ever cam through a portal or not, and even something more advanced based on the number of portals. The main current objective is for strokes shading: stroke shader uses Ray Portal BSDF to place ray to the center of the stroke and point it in the direction of the surface it is generated for. This gives stroke a single color which matches shading of the original object. For this usecase to work the ray bounced from the original surface should ignore the strokes, which is now possible by using Portal Depth input and mixing with the Transparent BSDF. It also helps to make shading look better when there are multiple stroke layers. A solution of using portal depth is chosen over a single flag due to various factors: - Last time we've looked into it it was a bit tricky to implement as a flag due to us running out of bits. - It feels to be more flexible solution, even though it is a bit hard to come up with 100% compelling setup for it. - It needs to be slightly different from the current "Is Foo" flags, and be more "Is Portal Descendant" or something. An extra uint16 is added to the state to count the portal depth, but it is only allocated for scenes that use Ray Portal BSDF. Portal BSDF still increments Transparent bounce, as it is required to have some "limiting" factor so that ray does not get infinitely move to different place of the scene. Ref #125213 Pull Request: https://projects.blender.org/blender/blender/pulls/143107
This folder contains files used by ctest testing system in Blender. The purpose of this files it to do automated render tests for Cycles, Workbench and EEVEE. If you want to extend this collection make sure the file is really small and uses as few samples as possible for reliable detection of render regressions. Each file is expected to be rendered in around one second.