Open 3D Engine Atom Gem API Reference 23.10.0
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
AZ::RPI::PassSystemInterface Class Referenceabstract

Inherited by AZ::RPI::PassSystem.

Public Types

using OnReadyLoadTemplatesEvent = AZ::Event<>
 

Public Member Functions

 AZ_RTTI (PassSystemInterface, "{19DE806F-F1B2-4B1E-A0F2-F8BA85B4552E}")
 
 AZ_DISABLE_COPY_MOVE (PassSystemInterface)
 
virtual const Ptr< ParentPass > & GetRootPass ()=0
 Returns the root of the pass hierarchy.
 
virtual void AddRenderPipeline (RenderPipeline *renderPipeline)=0
 Registers a render pipeline with the pass system.
 
virtual void RemoveRenderPipeline (RenderPipeline *renderPipeline)=0
 Removes a render pipeline from the pass system.
 
virtual void AddPassWithoutPipeline (const Ptr< Pass > &pass)=0
 Used to add passes that do not belong to any render pipeline.
 
virtual void ProcessQueuedChanges ()=0
 
virtual bool LoadPassTemplateMappings (const AZStd::string &templateMappingPath)=0
 
virtual void WriteTemplateToFile (const PassTemplate &passTemplate, AZStd::string_view assetFilePath)=0
 
virtual void DebugPrintPassHierarchy ()=0
 Prints the entire pass hierarchy from the root.
 
virtual void SetTargetedPassDebuggingName (const AZ::Name &targetPassName)=0
 
virtual const AZ::Name & GetTargetedPassDebuggingName () const =0
 
virtual SwapChainPassFindSwapChainPass (AzFramework::NativeWindowHandle windowHandle) const =0
 Find the SwapChainPass associated with window Handle.
 
virtual void ConnectEvent (OnReadyLoadTemplatesEvent::Handler &handler)=0
 
virtual PassSystemState GetState () const =0
 
virtual void IncrementFrameDrawItemCount (u32 numDrawItems)=0
 
virtual void IncrementFrameRenderPassCount ()=0
 
virtual PassSystemFrameStatistics GetFrameStatistics ()=0
 
virtual void DebugBreakOnPass (const Pass *pass) const =0
 
template<typename PassType >
Ptr< PassType > CreatePass (const PassDescriptor &descriptor)
 Directly creates a pass given a PassDescriptor.
 
template<typename PassType >
Ptr< PassType > CreatePass (Name name)
 Directly creates a pass given a Name.
 
virtual void AddPassCreator (Name className, PassCreator createFunction)=0
 Registers a PassCreator with the PassFactory.
 
virtual Ptr< PassCreatePassFromClass (Name passClassName, Name passName)=0
 Creates a Pass using the name of the Pass class.
 
virtual Ptr< PassCreatePassFromTemplate (const AZStd::shared_ptr< const PassTemplate > &passTemplate, Name passName)=0
 Creates a Pass using a PassTemplate.
 
virtual Ptr< PassCreatePassFromTemplate (Name templateName, Name passName)=0
 Creates a Pass using the name of a PassTemplate.
 
virtual Ptr< PassCreatePassFromRequest (const PassRequest *passRequest)=0
 Creates a Pass using a PassRequest.
 
virtual bool HasCreatorForClass (Name passClassName)=0
 Returns true if the factory has a creator for a given pass class name.
 
virtual bool HasTemplate (const Name &templateName) const =0
 Returns true if the pass library contains a pass template with the given template name.
 
virtual bool HasPassesForTemplateName (const Name &templateName) const =0
 Returns true if the pass factory contains passes created with the given template name.
 
virtual bool AddPassTemplate (const Name &name, const AZStd::shared_ptr< PassTemplate > &passTemplate)=0
 Adds a PassTemplate to the library.
 
virtual const AZStd::shared_ptr< const PassTemplateGetPassTemplate (const Name &name) const =0
 Retrieves a PassTemplate from the library.
 
virtual void RemovePassTemplate (const Name &name)=0
 See remarks in PassLibrary.h for the function with this name.
 
virtual void RemovePassFromLibrary (Pass *pass)=0
 Removes all references to the given pass from the pass library.
 
virtual void ForEachPass (const PassFilter &filter, AZStd::function< PassFilterExecutionFlow(Pass *)> passFunction)=0
 
virtual PassFindFirstPass (const PassFilter &filter)=0
 

Static Public Member Functions

static PassSystemInterfaceGet ()
 

Friends

class Pass
 
class ParentPass
 
class PassTests
 

Member Function Documentation

◆ AddPassCreator()

virtual void AZ::RPI::PassSystemInterface::AddPassCreator ( Name  className,
PassCreator  createFunction 
)
pure virtual

Registers a PassCreator with the PassFactory.

Implemented in AZ::RPI::PassSystem.

◆ AddPassTemplate()

virtual bool AZ::RPI::PassSystemInterface::AddPassTemplate ( const Name &  name,
const AZStd::shared_ptr< PassTemplate > &  passTemplate 
)
pure virtual

Adds a PassTemplate to the library.

Implemented in AZ::RPI::PassSystem.

◆ AddPassWithoutPipeline()

virtual void AZ::RPI::PassSystemInterface::AddPassWithoutPipeline ( const Ptr< Pass > &  pass)
pure virtual

Used to add passes that do not belong to any render pipeline.

Implemented in AZ::RPI::PassSystem.

◆ AddRenderPipeline()

virtual void AZ::RPI::PassSystemInterface::AddRenderPipeline ( RenderPipeline renderPipeline)
pure virtual

Registers a render pipeline with the pass system.

Implemented in AZ::RPI::PassSystem.

◆ ConnectEvent()

virtual void AZ::RPI::PassSystemInterface::ConnectEvent ( OnReadyLoadTemplatesEvent::Handler &  handler)
pure virtual

Connect a handler to listen to the event that the pass system is ready to load pass templates The event is triggered when pass system is initialized and asset system is ready. The handler can add new pass templates or load pass template mappings from assets

Implemented in AZ::RPI::PassSystem.

◆ CreatePassFromClass()

virtual Ptr< Pass > AZ::RPI::PassSystemInterface::CreatePassFromClass ( Name  passClassName,
Name  passName 
)
pure virtual

Creates a Pass using the name of the Pass class.

Implemented in AZ::RPI::PassSystem.

◆ CreatePassFromRequest()

virtual Ptr< Pass > AZ::RPI::PassSystemInterface::CreatePassFromRequest ( const PassRequest passRequest)
pure virtual

Creates a Pass using a PassRequest.

Implemented in AZ::RPI::PassSystem.

◆ CreatePassFromTemplate() [1/2]

virtual Ptr< Pass > AZ::RPI::PassSystemInterface::CreatePassFromTemplate ( const AZStd::shared_ptr< const PassTemplate > &  passTemplate,
Name  passName 
)
pure virtual

Creates a Pass using a PassTemplate.

Implemented in AZ::RPI::PassSystem.

◆ CreatePassFromTemplate() [2/2]

virtual Ptr< Pass > AZ::RPI::PassSystemInterface::CreatePassFromTemplate ( Name  templateName,
Name  passName 
)
pure virtual

Creates a Pass using the name of a PassTemplate.

Implemented in AZ::RPI::PassSystem.

◆ DebugPrintPassHierarchy()

virtual void AZ::RPI::PassSystemInterface::DebugPrintPassHierarchy ( )
pure virtual

Prints the entire pass hierarchy from the root.

Implemented in AZ::RPI::PassSystem.

◆ FindFirstPass()

virtual Pass * AZ::RPI::PassSystemInterface::FindFirstPass ( const PassFilter filter)
pure virtual

Find the first matching pass from registered passes with specified filter Note: this function SHOULD ONLY be used when you are certain you only need to handle the first pass found

Implemented in AZ::RPI::PassSystem.

◆ FindSwapChainPass()

virtual SwapChainPass * AZ::RPI::PassSystemInterface::FindSwapChainPass ( AzFramework::NativeWindowHandle  windowHandle) const
pure virtual

Find the SwapChainPass associated with window Handle.

Implemented in AZ::RPI::PassSystem.

◆ ForEachPass()

virtual void AZ::RPI::PassSystemInterface::ForEachPass ( const PassFilter filter,
AZStd::function< PassFilterExecutionFlow(Pass *)>  passFunction 
)
pure virtual

Visit the matching passes from registered passes with specified filter The return value of the passFunction decides if the search continues or not Note: this function will find all the passes which match the pass filter even they are for render pipelines which are not added to a scene This function is fast if a pass name or a pass template name is specified.

Implemented in AZ::RPI::PassSystem.

◆ GetPassTemplate()

virtual const AZStd::shared_ptr< const PassTemplate > AZ::RPI::PassSystemInterface::GetPassTemplate ( const Name &  name) const
pure virtual

Retrieves a PassTemplate from the library.

Implemented in AZ::RPI::PassSystem.

◆ HasCreatorForClass()

virtual bool AZ::RPI::PassSystemInterface::HasCreatorForClass ( Name  passClassName)
pure virtual

Returns true if the factory has a creator for a given pass class name.

Implemented in AZ::RPI::PassSystem.

◆ HasPassesForTemplateName()

virtual bool AZ::RPI::PassSystemInterface::HasPassesForTemplateName ( const Name &  templateName) const
pure virtual

Returns true if the pass factory contains passes created with the given template name.

Implemented in AZ::RPI::PassSystem.

◆ HasTemplate()

virtual bool AZ::RPI::PassSystemInterface::HasTemplate ( const Name &  templateName) const
pure virtual

Returns true if the pass library contains a pass template with the given template name.

Implemented in AZ::RPI::PassSystem.

◆ LoadPassTemplateMappings()

virtual bool AZ::RPI::PassSystemInterface::LoadPassTemplateMappings ( const AZStd::string &  templateMappingPath)
pure virtual

Load pass templates listed in a name-assetid mapping asset This function should be called before the render pipelines which use templates from this mappings are created. To load pass template mapping before any render pipelines are created, use OnReadyLoadTemplatesEvent::Handler to load desired pass template mappings

Implemented in AZ::RPI::PassSystem.

◆ ProcessQueuedChanges()

virtual void AZ::RPI::PassSystemInterface::ProcessQueuedChanges ( )
pure virtual

Processes pass tree changes that were queued by QueueFor*() functions. This is called automatically in FrameUpdate(), but may be called manually when needed, like when initializing a scene;

Implemented in AZ::RPI::PassSystem.

◆ RemovePassFromLibrary()

virtual void AZ::RPI::PassSystemInterface::RemovePassFromLibrary ( Pass pass)
pure virtual

Removes all references to the given pass from the pass library.

Implemented in AZ::RPI::PassSystem.

◆ RemovePassTemplate()

virtual void AZ::RPI::PassSystemInterface::RemovePassTemplate ( const Name &  name)
pure virtual

See remarks in PassLibrary.h for the function with this name.

Implemented in AZ::RPI::PassSystem.

◆ RemoveRenderPipeline()

virtual void AZ::RPI::PassSystemInterface::RemoveRenderPipeline ( RenderPipeline renderPipeline)
pure virtual

Removes a render pipeline from the pass system.

Implemented in AZ::RPI::PassSystem.

◆ SetTargetedPassDebuggingName()

virtual void AZ::RPI::PassSystemInterface::SetTargetedPassDebuggingName ( const AZ::Name &  targetPassName)
pure virtual

The pass system enables targeted debugging of a specific pass given the name of the pass These are the setters and getters for the specific Pass's name To break in your pass code for a specified pass name, use the macro below

Implemented in AZ::RPI::PassSystem.

◆ WriteTemplateToFile()

virtual void AZ::RPI::PassSystemInterface::WriteTemplateToFile ( const PassTemplate passTemplate,
AZStd::string_view  assetFilePath 
)
pure virtual

Writes a pass template to a .pass file which can then be used as a pass asset. Useful for quickly authoring a pass template in code and then outputting it as a pass asset using JSON

Implemented in AZ::RPI::PassSystem.


The documentation for this class was generated from the following file: