Culling results (visible objects, lights, reflection probes).
In a scriptable render loop, the rendering process is typically doing culling for each camera (ScriptableRenderContext.Cull), followed by rendering subsets of visible objects (ScriptableRenderContext.DrawRenderers) and processing visible lights (visibleLights, visibleReflectionProbes).
CullingResults also provides several functions to aid shadow rendering (ComputeDirectionalShadowMatricesAndCullingPrimitives, ComputeSpotShadowMatricesAndCullingPrimitives, ComputePointShadowMatricesAndCullingPrimitives).
lightAndReflectionProbeIndexCount | Gets the number of per-object light and reflection probe indices. |
lightIndexCount | Gets the number of per-object light indices. |
reflectionProbeIndexCount | Gets the number of per-object reflection probe indices. |
visibleLights | Array of visible lights. |
visibleOffscreenVertexLights | Off screen lights that still effect visible Scene vertices. |
visibleReflectionProbes | Array of visible reflection probes. |
ComputeDirectionalShadowMatricesAndCullingPrimitives | Calculates the view and projection matrices and shadow split data for a directional light. |
ComputePointShadowMatricesAndCullingPrimitives | Calculates the view and projection matrices and shadow split data for a point light. |
ComputeSpotShadowMatricesAndCullingPrimitives | Calculates the view and projection matrices and shadow split data for a spot light. |
FillLightAndReflectionProbeIndices | Fills a compute buffer with per-object light indices. |
GetLightIndexMap | If a RenderPipeline sorts or otherwise modifies the VisibleLight list, an index remap will be necessary to properly make use of per-object light lists. |
GetReflectionProbeIndexMap | If a RenderPipeline sorts or otherwise modifies the VisibleReflectionProbe list, an index remap will be necessary to properly make use of per-object reflection probe lists. |
GetShadowCasterBounds | Returns the bounding box that encapsulates the visible shadow casters. Can be used to, for instance, dynamically adjust cascade ranges. |
SetLightIndexMap | If a RenderPipeline sorts or otherwise modifies the VisibleLight list, an index remap will be necessary to properly make use of per-object light lists. If an element of the array is set to -1, the light corresponding to that element will be disabled. |
SetReflectionProbeIndexMap | If a RenderPipeline sorts or otherwise modifies the VisibleReflectionProbe list, an index remap will be necessary to properly make use of per-object reflection probe lists. If an element of the array is set to -1, the reflection probe corresponding to that element will be disabled. |
Did you find this page useful? Please give it a rating: