Class ShadowsPass
Shadows rendering service.
Assembly: FlaxEngine.dll
File: Engine/Renderer/ShadowsPass.h
Syntax
public class ShadowsPass : public RendererPass
Methods
Dispose()
Cleanup service data.
Declaration
public virtual void Dispose() override
Overrides
GetShadowAtlas(const RenderBuffers* renderBuffers, GPUTexture*& shadowMapAtlas, GPUBufferView*& shadowsBuffer)
Gets the shadow atlas texture and shadows buffer for shadow projection in shaders.
Declaration
public static void GetShadowAtlas(const RenderBuffers* renderBuffers, GPUTexture*& shadowMapAtlas, GPUBufferView*& shadowsBuffer)
Parameters
RenderBuffers
renderBuffers
The render buffers that store frame context. |
GPUTexture
shadowMapAtlas
The output shadow map atlas texture or null if unused. |
GPUBufferView
shadowsBuffer
The output shadows buffer or null if unused. |
Init()
Initialize service.
Declaration
public virtual bool Init() override
Returns
bool
|
Overrides
RenderShadowMaps(RenderContextBatch& renderContextBatch)
Renders the shadow maps for all lights (into atlas).
Declaration
public void RenderShadowMaps(RenderContextBatch& renderContextBatch)
Parameters
RenderContextBatch
renderContextBatch
|
RenderShadowMask(RenderContextBatch& renderContextBatch, RenderLightData& light, GPUTextureView* shadowMask)
Renders the shadow mask for the given light.
Declaration
public void RenderShadowMask(RenderContextBatch& renderContextBatch, RenderLightData& light, GPUTextureView* shadowMask)
Parameters
RenderContextBatch
renderContextBatch
The rendering context batch. |
RenderLightData
light
The light. |
GPUTextureView
shadowMask
The shadow mask (output). |
setupResources()
Declaration
protected virtual bool setupResources() override
Returns
bool
|
Overrides
SetupShadows(RenderContext& renderContext, RenderContextBatch& renderContextBatch)
Setups the shadows rendering for batched scene drawing. Checks which lights will cast a shadow.
Declaration
public void SetupShadows(RenderContext& renderContext, RenderContextBatch& renderContextBatch)
Parameters
RenderContext
renderContext
|
RenderContextBatch
renderContextBatch
|
ToString()
Gets the string representation of this object.
Declaration
public virtual String ToString() const override
Returns
String
|