This repository has been archived by the owner on Jul 18, 2020. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
New per-material transparency bias for Shiny Diffuse
When there are objects with many transparent surfaces stacked close together (such as leaves in a tree) sometimes black artifacts appear if the ray reaches the maximum depth. This can be solved by increasing the maximum ray depth, but the render times will increase very significantly. Therefore I've added two new parameters for the Shiny Diffuse material to try to achieve a "trick", which is not realistic and may cause other artifacts but that should prevent the black areas without having to increase the maximum ray depth so much. * transparentbias_factor : this floating point value is 0.0 by default (disabled). If this value is >0.0 the function is enabled. In that case, an additional "bias" will be added to each ray when it hits a transparent surface. If the ray hits a transparent surface, the next secondary ray will not start exactly after that surface but after this bias factor. So, subsequent transparent surfaces can be skipped and not rendered, but the objects behind will be rendered (unless they are too close to them, in that case they might not be rendered!) * transparentbias_multiply_raydepth : this boolean values is false by default. If the factor is used and this is disabled, the factor will be just added to each secondary ray initial position. If this parameter is enabled, the "bias" for each ray will be multiplied by the ray depth. That way, the first few surfaces will be rendered giving a better "density" but the further the secondary rays are generated, the bigger the bias will be. I got interesting results with factor = 1.0 and multiply_raydepth = true. However, even solving the black areas problems, the resulting image will have other artifacts due to some surfaces not being rendered. USE WITH CARE!!
- Loading branch information