maxRecursionDepth
The maximum number of ray bounces this shader can trace (Read Only).
Read time 1 minuteLast updated 6 days ago
Definition
- Type: Property
- Namespace: UnityEngine.Rendering
- Assembly: UnityEngine.CoreModule
public float maxRecursionDepth { get; }
Remarks
This value can be set in a .raytrace file using followed by a positive number.
#pragma max_recursion_depthIf you set value too low, your graphics device may go into removed state, and crash Unity. To generate rays, your value must be at least 0. However, if you invoke the HLSL function inside a closest hit shader (for example) your value must be at least 1.
max_recursion_depthmax_recursion_depthTraceRaymax_recursion_depth