LiteFX::Rendering::GraphicsFactory¶
Describes a factory that creates objects for a GraphicsDevice.
Synopsis¶
Declared in <litefx/rendering.hpp>
template<
typename TDescriptorLayout,
typename TBuffer,
typename TVertexBuffer,
typename TIndexBuffer,
typename TImage,
typename TSampler,
typename TBLAS,
typename TTLAS>
requires meta::implements<TDescriptorLayout, IDescriptorLayout> &&
std::derived_from<TVertexBuffer, VertexBuffer<typename TVertexBuffer::vertex_buffer_layout_type>> &&
std::derived_from<TIndexBuffer, IndexBuffer<typename TIndexBuffer::index_buffer_layout_type>> &&
std::derived_from<TImage, IImage> &&
std::derived_from<TBuffer, IBuffer> &&
std::derived_from<TSampler, ISampler> &&
std::derived_from<TBLAS, IBottomLevelAccelerationStructure> &&
std::derived_from<TTLAS, ITopLevelAccelerationStructure>
class GraphicsFactory
: public IGraphicsFactory
Base Classes¶
| Name | Description |
|---|---|
IGraphicsFactory | The interface for a graphics factory. |
Type Aliases¶
Member Functions¶
| Name | Description |
|---|---|
~GraphicsFactory [destructor] [virtual] | Destructor |
allocate | allocate overloads |
beginDefragmentation [virtual] | Starts a defragmentation process for the resources allocated from the factory. |
beginDefragmentationPass [virtual] | Starts a new defragmentation pass. |
canAlias [virtual] | Checks if the resources described by allocationInfos can be overlapped. |
createAllocator [virtual] | Creates a virtual allocator that can be used to manage allocation from a custom block of memory. |
createBottomLevelAccelerationStructure | Creates a bottom-level acceleration structure. |
createBuffer | createBuffer overloads |
createIndexBuffer | Creates an index buffer, based on the layout. |
createSampler | Creates a texture sampler. |
createSamplers [virtual] | Creates a series of texture samplers. |
createTexture | Creates a texture. |
createTextures [virtual] | Creates a series of textures. |
createTopLevelAccelerationStructure | Creates a top-level acceleration structure. |
createVertexBuffer | Creates a vertex buffer, based on the layout. |
detailedMemoryStatistics [virtual] | Returns detailed memory statistics. |
endDefragmentationPass [virtual] | Ends a defragmentation pass. |
memoryStatistics [virtual] | Returns an array of objects, that contain information about the current memory usage and available memory for a memory heap. |
shared_from_this | Returns a shared pointer to the current object instance. |
supportsResizableBaseAddressRegister [virtual] | Returns true, if the GPU supports resizable base address register (ReBAR) and false otherwise. |
tryCreateBuffer | tryCreateBuffer overloads |
tryCreateIndexBuffer | Tries to create an index buffer, based on the layout. |
tryCreateTexture | Tries to create a texture. |
tryCreateVertexBuffer | Tries to create a vertex buffer, based on the layout. |
weak_from_this | Returns a weak pointer to the current object instance. |
Using Declarations¶
| Name |
|---|
createBuffer |
createIndexBuffer |
createSampler |
createSamplers |
createTexture |
createTextures |
createVertexBuffer |
tryCreateBuffer |
tryCreateIndexBuffer |
tryCreateTexture |
tryCreateVertexBuffer |
Protected Types¶
| Name | Description |
|---|---|
Allocator | An allocator used to allocate the shared object. |
Protected Member Functions¶
| Name | Description |
|---|---|
GraphicsFactory [constructor] | Constructors |
operator= | Assignment operators |
Protected Static Member Functions¶
| Name | Description |
|---|---|
create | Generic factory method used to create instances of the shared object. |
Template Parameters¶
| Name | Description |
|---|---|
| TDescriptorLayout | The type of the descriptor layout. Must implement IDescriptorLayout. |
| TVertexBuffer | The type of the vertex buffer. Must implement VertexBuffer. |
| TIndexBuffer | The type of the index buffer. Must implement IndexBuffer. |
| TImage | The type of the image. Must inherit from IImage. |
| TBuffer | The type of the buffer. Must inherit from IBuffer. |
| TSampler | The type of the sampler. Must inherit from ISampler. |
| TBLAS | The type of the bottom-level acceleration structure. Must implement IBottomLevelAccelerationStructure. |
| TTLAS | The type of the top-level acceleration structure. Must implement ITopLevelAccelerationStructure. |
Derived Classes¶
| Name | Description |
|---|---|
DirectX12GraphicsFactory | A graphics factory that produces objects for a DirectX12Device. |
VulkanGraphicsFactory | A graphics factory that produces objects for a VulkanDevice. |