#include <Factory.h>
Inherited by AZ::DX12::SystemComponent, AZ::Metal::SystemComponent, AZ::Null::SystemComponent, and AZ::Vulkan::SystemComponent.
Public Member Functions | |
AZ_TYPE_INFO (Factory, "{2C0231FD-DD11-4154-A4F5-177181E26D8E}") | |
AZ_DISABLE_COPY_MOVE (Factory) | |
virtual Name | GetName ()=0 |
Returns the name of the Factory. | |
virtual APIType | GetType ()=0 |
Returns the APIType of the factory. | |
virtual APIPriority | GetDefaultPriority ()=0 |
Returns the default priority of the factory in case there's no priorities set in the FactoryManager. | |
virtual bool | SupportsXR () const =0 |
Returns true if the factory supports XR api. | |
virtual uint32_t | GetAPIUniqueIndex () const =0 |
virtual PhysicalDeviceList | EnumeratePhysicalDevices ()=0 |
virtual Ptr< Buffer > | CreateBuffer ()=0 |
virtual Ptr< BufferPool > | CreateBufferPool ()=0 |
virtual Ptr< BufferView > | CreateBufferView ()=0 |
virtual Ptr< Device > | CreateDevice ()=0 |
virtual Ptr< Fence > | CreateFence ()=0 |
virtual Ptr< FrameGraphCompiler > | CreateFrameGraphCompiler ()=0 |
virtual Ptr< FrameGraphExecuter > | CreateFrameGraphExecuter ()=0 |
virtual Ptr< Image > | CreateImage ()=0 |
virtual Ptr< ImagePool > | CreateImagePool ()=0 |
virtual Ptr< ImageView > | CreateImageView ()=0 |
virtual Ptr< StreamingImagePool > | CreateStreamingImagePool ()=0 |
virtual Ptr< PipelineState > | CreatePipelineState ()=0 |
virtual Ptr< PipelineLibrary > | CreatePipelineLibrary ()=0 |
virtual Ptr< Scope > | CreateScope ()=0 |
virtual Ptr< ShaderResourceGroup > | CreateShaderResourceGroup ()=0 |
virtual Ptr< ShaderResourceGroupPool > | CreateShaderResourceGroupPool ()=0 |
virtual Ptr< SwapChain > | CreateSwapChain ()=0 |
virtual Ptr< TransientAttachmentPool > | CreateTransientAttachmentPool ()=0 |
virtual Ptr< QueryPool > | CreateQueryPool ()=0 |
virtual Ptr< Query > | CreateQuery ()=0 |
virtual Ptr< IndirectBufferSignature > | CreateIndirectBufferSignature ()=0 |
virtual Ptr< IndirectBufferWriter > | CreateIndirectBufferWriter ()=0 |
virtual Ptr< RayTracingBufferPools > | CreateRayTracingBufferPools ()=0 |
virtual Ptr< RayTracingBlas > | CreateRayTracingBlas ()=0 |
virtual Ptr< RayTracingTlas > | CreateRayTracingTlas ()=0 |
virtual Ptr< RayTracingPipelineState > | CreateRayTracingPipelineState ()=0 |
virtual Ptr< RayTracingShaderTable > | CreateRayTracingShaderTable ()=0 |
Static Public Member Functions | |
static uint32_t | GetComponentService () |
Returns the component service name CRC used by the platform RHI system component. | |
static uint32_t | GetManagerComponentService () |
Returns the component service name CRC used by the Factory manager component. | |
static uint32_t | GetPlatformService () |
Returns the component service name CRC used by the platform RHI system component. | |
static void | Register (Factory *instance) |
Registers the global factory instance. | |
static void | Unregister (Factory *instance) |
Unregisters the global factory instance. | |
static bool | IsReady () |
Returns whether the factory is initialized and active in this module. | |
static Factory & | Get () |
Access the global factory instance. | |
static bool | IsRenderDocModuleLoaded () |
Returns true if RenderDoc dll is loaded. | |
static bool | IsPixModuleLoaded () |
Returns true if Pix dll is loaded. | |
static bool | PixGpuEventsEnabled () |
Returns true if Pix GPU events should be emitted. | |
static bool | UsingWarpDevice () |
Returns true if Warp is enabled. | |
The factory is an interface for creating RHI data structures. The platform system should register itself with the factory by calling Register, and unregister on shutdown with Unregister.
A call to Get will return the active instance. In the event that it's unclear whether a platform instance exists, you must call IsReady to determine whether it's safe to call Get. Calling Get without a registered platform will result in an assert.
|
pure virtual |
Factory Creation Methods:
Returns the platform-specific derived variant of the RHI type. All instances are created in an uninitialized state; the operation simply allocates the memory for the appropriate platform type and returns the pointer.
Implemented in AZ::DX12::SystemComponent, AZ::Metal::SystemComponent, AZ::Null::SystemComponent, and AZ::Vulkan::SystemComponent.
|
pure virtual |
Collects the set of physical devices on the system and returns a list of them. Physical devices represent the hardware attached to the system. Physical devices can be grouped into nodes for linked setups (e.g. SLI / Crossfire). They can also represent software reference implementations. Check the PhysicalDeviceType on the descriptor to inspect this information.
Implemented in AZ::DX12::SystemComponent, AZ::Metal::SystemComponent, AZ::Null::SystemComponent, and AZ::Vulkan::SystemComponent.
|
pure virtual |
Purpose: The API Unique Index will be encoded in the 2 Most Significant Bits of a ShaderVariantAsset ProductSubId (a 32bits integer). Returns a number in the range [0..3]. In theory any given AssetBuilderSdk::PlatformInfo can support several RHI::APITypes. In reality "pc" only supports DX12 & Vulkan. "ios" supports only Metal. "mac" supports only Metal. "android" supports only Vulkan. So, for all practical purposes, a single PlatformInfo won't support more than 2 ShaderPlatformInterfaces, but for the sake of hedging our bets into the future We assume no more than 4 ShaderPlatformInterfaces will ever be supported for any given PlatformInfo. REMARK: It is the responsibility of the Factory subclass to return a unique number between 0...3. For example DX12 can return 0, while Vulkan should return 1 (Satisfies "pc", "android" and "linux"). Metal can return 0 because it is the only ShaderPlatformInterface for "ios", "mac" and "appletv". See AZ::RHI::Limits::APIType::PerPlatformApiUniqueIndexMax.
Implemented in AZ::DX12::SystemComponent, AZ::Metal::SystemComponent, AZ::Null::SystemComponent, and AZ::Vulkan::SystemComponent.
|
pure virtual |
Returns the default priority of the factory in case there's no priorities set in the FactoryManager.
Implemented in AZ::DX12::SystemComponent, AZ::Metal::SystemComponent, AZ::Null::SystemComponent, and AZ::Vulkan::SystemComponent.
|
pure virtual |
Returns the name of the Factory.
Implemented in AZ::DX12::SystemComponent, AZ::Metal::SystemComponent, AZ::Null::SystemComponent, and AZ::Vulkan::SystemComponent.
|
pure virtual |
Returns the APIType of the factory.
Implemented in AZ::DX12::SystemComponent, AZ::Metal::SystemComponent, AZ::Null::SystemComponent, and AZ::Vulkan::SystemComponent.
|
pure virtual |
Returns true if the factory supports XR api.
Implemented in AZ::DX12::SystemComponent, AZ::Metal::SystemComponent, AZ::Null::SystemComponent, and AZ::Vulkan::SystemComponent.