This feature processor handles projected shadows for various lights. More...
#include <ProjectedShadowFeatureProcessorInterface.h>
Inherits AZ::RPI::FeatureProcessor.
Inherited by AZ::Render::ProjectedShadowFeatureProcessor.
Classes | |
struct | ProjectedShadowDescriptor |
Used in SetShadowProperties() to set several related shadow properties in one function call. More... | |
Public Types | |
using | ShadowId = RHI::Handle< uint16_t, ProjectedShadowFeatureProcessorInterface > |
Public Member Functions | |
AZ_RTTI (AZ::Render::ProjectedShadowFeatureProcessorInterface, "{C5651D73-3448-4D76-91C0-0E636A197F63}", AZ::RPI::FeatureProcessor) | |
virtual ShadowId | AcquireShadow ()=0 |
Creates a new projected shadow and returns a handle that can be used to reference it later. | |
virtual void | ReleaseShadow (ShadowId id)=0 |
Releases a projected shadow given its ID. | |
virtual void | SetShadowTransform (ShadowId id, Transform transform)=0 |
Sets the world space transform of where the shadow is cast from. | |
virtual void | SetNearFarPlanes (ShadowId id, float nearPlaneDistance, float farPlaneDistance)=0 |
Sets the near and far plane distances for the shadow. | |
virtual void | SetAspectRatio (ShadowId id, float aspectRatio)=0 |
Sets the aspect ratio for the shadow. | |
virtual void | SetFieldOfViewY (ShadowId id, float fieldOfView)=0 |
Sets the field of view for the shadow in radians in the Y direction. | |
virtual void | SetShadowmapMaxResolution (ShadowId id, ShadowmapSize size)=0 |
Sets the maximum resolution of the shadow map. | |
virtual void | SetShadowBias (ShadowId id, float bias)=0 |
Sets the shadow bias. | |
virtual void | SetNormalShadowBias (ShadowId id, float normalShadowBias)=0 |
Sets the normal shadow bias. | |
virtual void | SetShadowFilterMethod (ShadowId id, ShadowFilterMethod method)=0 |
Sets the shadow filter method. | |
virtual void | SetFilteringSampleCount (ShadowId id, uint16_t count)=0 |
Sets the sample count for filtering of the shadow boundary, max 64. | |
virtual void | SetUseCachedShadows (ShadowId id, bool useCachedShadows)=0 |
virtual void | SetShadowProperties (ShadowId id, const ProjectedShadowDescriptor &descriptor)=0 |
Sets all of the shadow properties in one call. | |
virtual const ProjectedShadowDescriptor & | GetShadowProperties (ShadowId id)=0 |
Gets the current shadow properties. Useful for updating several properties at once in SetShadowProperties() without having to set every property. | |
Public Member Functions inherited from AZ::RPI::FeatureProcessor | |
AZ_RTTI (FeatureProcessor, "{B8027170-C65C-4237-964D-B557FC9D7575}") | |
AZ_CLASS_ALLOCATOR (FeatureProcessor, AZ::SystemAllocator) | |
Scene * | GetParentScene () const |
virtual void | Activate () |
Perform any necessary activation and gives access to owning Scene. | |
virtual void | Deactivate () |
Perform any necessary deactivation. | |
virtual void | ApplyRenderPipelineChange (RenderPipeline *pipeline) |
virtual void | AddRenderPasses (RenderPipeline *pipeline) |
virtual void | PrepareViews (const PrepareViewsPacket &, AZStd::vector< AZStd::pair< PipelineViewTag, ViewPtr > > &) |
virtual void | Simulate (const SimulatePacket &) |
virtual void | Render (const RenderPacket &) |
virtual void | OnEndCulling (const RenderPacket &) |
virtual void | OnRenderEnd () |
Static Public Attributes | |
static constexpr float | MaxProjectedShadowRadians = AZ::DegToRad(150.0f) |
Additional Inherited Members | |
Protected Member Functions inherited from AZ::RPI::FeatureProcessor | |
void | EnableSceneNotification () |
void | DisableSceneNotification () |
This feature processor handles projected shadows for various lights.
|
pure virtual |
Creates a new projected shadow and returns a handle that can be used to reference it later.
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.
|
pure virtual |
Gets the current shadow properties. Useful for updating several properties at once in SetShadowProperties() without having to set every property.
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.
|
pure virtual |
Releases a projected shadow given its ID.
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.
|
pure virtual |
Sets the aspect ratio for the shadow.
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.
|
pure virtual |
Sets the field of view for the shadow in radians in the Y direction.
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.
|
pure virtual |
Sets the sample count for filtering of the shadow boundary, max 64.
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.
|
pure virtual |
Sets the near and far plane distances for the shadow.
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.
|
pure virtual |
Sets the normal shadow bias.
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.
|
pure virtual |
Sets the shadow bias.
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.
|
pure virtual |
Sets the shadow filter method.
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.
|
pure virtual |
Sets the maximum resolution of the shadow map.
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.
|
pure virtual |
Sets all of the shadow properties in one call.
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.
|
pure virtual |
Sets the world space transform of where the shadow is cast from.
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.
|
pure virtual |
Sets if this shadow should be rendered every frame or only when it detects a change. Changes are detected by the presence of a flag on the view which tracks if any of the draws submitted to it contained that flag. The mesh feature processor sets this flag on any cullable that moves, and it is combined with all other flags for draws submitted to each view. See MeshCommon::MeshMovedName for the name of the flag used to track movement See RPI::Scene::GetViewTagBitRegistry() for where the flag bits are determined See RPI::View::GetOrFlags() for how the bits are retrieved
Implemented in AZ::Render::ProjectedShadowFeatureProcessor.