LiteFX 0.4.1.2025
Computer Graphics Engine
Loading...
Searching...
No Matches
LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier > Class Template Referenceabstract

Represents the graphics device that a rendering back-end is doing work on. More...

#include <rendering.hpp>

Inherits LiteFX::Rendering::IGraphicsDevice.

Public Types

using surface_type = TSurface
 
using adapter_type = TGraphicsAdapter
 
using swap_chain_type = TSwapChain
 
using command_queue_type = TCommandQueue
 
using command_buffer_type = command_queue_type::command_buffer_type
 
using factory_type = TFactory
 
using barrier_type = TBarrier
 
using descriptor_layout_type = factory_type::descriptor_layout_type
 
using vertex_buffer_type = factory_type::vertex_buffer_type
 
using index_buffer_type = factory_type::index_buffer_type
 
using buffer_type = factory_type::buffer_type
 
using image_type = factory_type::image_type
 
using sampler_type = factory_type::sampler_type
 
using bottom_level_acceleration_structure_type = factory_type::bottom_level_acceleration_structure_type
 
using top_level_acceleration_structure_type = factory_type::top_level_acceleration_structure_type
 
using render_pass_type = TRenderPass
 
using frame_buffer_type = render_pass_type::frame_buffer_type
 
using render_pipeline_type = TRenderPipeline
 
using compute_pipeline_type = TComputePipeline
 
using ray_tracing_pipeline_type = TRayTracingPipeline
 
using pipeline_layout_type = render_pipeline_type::pipeline_layout_type
 
using shader_program_type = render_pipeline_type::shader_program_type
 
using input_assembler_type = render_pipeline_type::input_assembler_type
 
using rasterizer_type = render_pipeline_type::rasterizer_type
 

Public Member Functions

 ~GraphicsDevice () noexcept override=default
 
const surface_typesurface () const noexcept override=0
 Returns the surface, the device draws to.
Returns
A reference of the surface, the device draws to.

 
const adapter_typeadapter () const noexcept override=0
 Returns the graphics adapter, the device uses for drawing.
Returns
A reference of the graphics adapter, the device uses for drawing.

 
const swap_chain_typeswapChain () const noexcept override=0
 Returns the swap chain, that contains the back and front buffers used for presentation.
Returns
The swap chain, that contains the back and front buffers used for presentation.

 
swap_chain_typeswapChain () noexcept override=0
 Returns the swap chain, that contains the back and front buffers used for presentation.
Returns
The swap chain, that contains the back and front buffers used for presentation.

 
const factory_typefactory () const noexcept override=0
 Returns the factory instance, used to create instances from the device.
Returns
The factory instance, used to create instances from the device.

 
virtual const command_queue_typedefaultQueue (QueueType type) const =0
 
virtual SharedPtr< const command_queue_typecreateQueue (QueueType type, QueuePriority priority=QueuePriority::Normal)=0
 
virtual UniquePtr< barrier_typemakeBarrier (PipelineStage syncBefore, PipelineStage syncAfter) const =0
 
SharedPtr< frame_buffer_typemakeFrameBuffer (const Size2d &renderArea) const
 
virtual SharedPtr< frame_buffer_typemakeFrameBuffer (StringView name, const Size2d &renderArea) const =0
 
virtual void computeAccelerationStructureSizes (const bottom_level_acceleration_structure_type &blas, UInt64 &bufferSize, UInt64 &scratchSize, bool forUpdate=false) const =0
 
virtual void computeAccelerationStructureSizes (const top_level_acceleration_structure_type &tlas, UInt64 &bufferSize, UInt64 &scratchSize, bool forUpdate=false) const =0
 
- Public Member Functions inherited from LiteFX::Rendering::IGraphicsDevice
 ~IGraphicsDevice () noexcept override=default
 
virtual DeviceStatestate () const noexcept=0
 Returns the device state that can be used to manage resources.
 
const ICommandQueuedefaultQueue (QueueType type) const
 Returns the instance of the default ICommandQueue that supports the combination of queue types specified by the type parameter.
 
SharedPtr< const ICommandQueuecreateQueue (QueueType type, QueuePriority priority=QueuePriority::Normal)
 Attempts to create a new queue that supports the combination of queue types specified by the type parameter.
 
UniquePtr< IBarriermakeBarrier (PipelineStage syncBefore, PipelineStage syncAfter) const
 Creates a memory barrier instance.
 
SharedPtr< IFrameBuffermakeFrameBuffer (const Size2d &renderArea) const
 Creates a new frame buffer instance.
 
SharedPtr< IFrameBuffermakeFrameBuffer (StringView name, const Size2d &renderArea) const
 Creates a new frame buffer instance.
 
virtual MultiSamplingLevel maximumMultiSamplingLevel (Format format) const noexcept=0
 Queries the device for the maximum supported number of multi-sampling levels.
 
virtual double ticksPerMillisecond () const noexcept=0
 Returns the number of GPU ticks per milliseconds.
 
void computeAccelerationStructureSizes (const IBottomLevelAccelerationStructure &blas, UInt64 &bufferSize, UInt64 &scratchSize, bool forUpdate=false) const
 Computes the required amount of device memory for an IBottomLevelAccelerationStructure.
 
void computeAccelerationStructureSizes (const ITopLevelAccelerationStructure &tlas, UInt64 &bufferSize, UInt64 &scratchSize, bool forUpdate=false) const
 Computes the required amount of device memory for an ITopLevelAccelerationStructure.
 
virtual void wait () const =0
 Waits until all queues allocated from the device have finished the work issued prior to this point.
 
- Public Member Functions inherited from LiteFX::SharedObject
virtual ~SharedObject () noexcept=default
 Destroys the shared object.
 
template<typename TSelf >
auto shared_from_this (this TSelf &&self) noexcept
 Returns a shared pointer to the current object instance.
 
template<typename TSelf >
auto weak_from_this (this TSelf &&self) noexcept -> WeakPtr< std::remove_reference_t< TSelf > >
 Returns a weak pointer to the current object instance.
 

Protected Member Functions

 GraphicsDevice () noexcept=default
 
 GraphicsDevice (GraphicsDevice &&) noexcept=default
 
 GraphicsDevice (const GraphicsDevice &)=default
 
GraphicsDeviceoperator= (GraphicsDevice &&) noexcept=default
 
GraphicsDeviceoperator= (const GraphicsDevice &)=default
 
- Protected Member Functions inherited from LiteFX::Rendering::IGraphicsDevice
 IGraphicsDevice () noexcept=default
 
 IGraphicsDevice (IGraphicsDevice &&) noexcept=default
 
 IGraphicsDevice (const IGraphicsDevice &)=default
 
IGraphicsDeviceoperator= (const IGraphicsDevice &)=default
 
IGraphicsDeviceoperator= (IGraphicsDevice &&) noexcept=default
 
- Protected Member Functions inherited from LiteFX::SharedObject
 SharedObject () noexcept=default
 Initializes a new shared object.
 
 SharedObject (SharedObject &&) noexcept=default
 
 SharedObject (const SharedObject &)=default
 
SharedObjectoperator= (SharedObject &&) noexcept=default
 
SharedObjectoperator= (const SharedObject &)=default
 

Additional Inherited Members

- Static Protected Member Functions inherited from LiteFX::SharedObject
template<typename T , typename... TArgs>
static auto create (TArgs &&... args) -> SharedPtr< T >
 Generic factory method used to create instances of the shared object.
 

Detailed Description

template<typename TFactory, typename TSurface, typename TGraphicsAdapter, typename TSwapChain, typename TCommandQueue, typename TRenderPass, typename TRenderPipeline, typename TComputePipeline, typename TRayTracingPipeline, typename TBarrier>
requires meta::implements<TSurface, ISurface> && meta::implements<TGraphicsAdapter, IGraphicsAdapter> && meta::implements<TSwapChain, SwapChain<typename TFactory::image_type>> && meta::implements<TCommandQueue, CommandQueue<typename TCommandQueue::command_buffer_type>> && meta::implements<TFactory, GraphicsFactory<typename TFactory::descriptor_layout_type, typename TFactory::buffer_type, typename TFactory::vertex_buffer_type, typename TFactory::index_buffer_type, typename TFactory::image_type, typename TFactory::sampler_type, typename TFactory::bottom_level_acceleration_structure_type, typename TFactory::top_level_acceleration_structure_type>> && meta::implements<TRenderPass, RenderPass<TCommandQueue, typename TRenderPass::frame_buffer_type>> && meta::implements<TRenderPipeline, RenderPipeline<typename TRenderPipeline::pipeline_layout_type, typename TRenderPipeline::shader_program_type, typename TRenderPipeline::input_assembler_type, typename TRenderPipeline::rasterizer_type>> && meta::implements<TComputePipeline, ComputePipeline<typename TComputePipeline::pipeline_layout_type, typename TComputePipeline::shader_program_type>> && meta::implements<TRayTracingPipeline, RayTracingPipeline<typename TRayTracingPipeline::pipeline_layout_type, typename TRayTracingPipeline::shader_program_type>> && meta::implements<TBarrier, Barrier<typename TFactory::buffer_type, typename TFactory::image_type>>
class LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >

Represents the graphics device that a rendering back-end is doing work on.

The graphics device is the central instance of a renderer. It has two major roles. First, it maintains the GraphicsFactory instance, that is used to facilitate common objects. Second, it owns the device state, which contains objects required for communication between your application and the graphics driver. Most notably, those objects contain the SwapChain instance and the CommandQueue instances used for data and command transfer.

Template Parameters
TFactoryThe type of the graphics factory. Must implement GraphicsFactory.
TSurfaceThe type of the surface. Must implement ISurface.
TGraphicsAdapterThe type of the graphics adapter. Must implement IGraphicsAdapter.
TSwapChainThe type of the swap chain. Must implement SwapChain.
TCommandQueueThe type of the command queue. Must implement CommandQueue.
TRenderPassThe type of the render pass. Must implement RenderPass.
TRenderPipelineThe type of the render pipeline. Must implement RenderPipeline.
TComputePipelineThe type of the compute pipeline. Must implement ComputePipeline.
TRayTracingPipelineThe type of the ray-tracing pipeline. Must implement RayTracingPipeline.
TBarrierThe type of the memory barrier. Must implement Barrier.

Member Typedef Documentation

◆ adapter_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::adapter_type = TGraphicsAdapter

◆ barrier_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::barrier_type = TBarrier

◆ bottom_level_acceleration_structure_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::bottom_level_acceleration_structure_type = factory_type::bottom_level_acceleration_structure_type

◆ buffer_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::buffer_type = factory_type::buffer_type

◆ command_buffer_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::command_buffer_type = command_queue_type::command_buffer_type

◆ command_queue_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::command_queue_type = TCommandQueue

◆ compute_pipeline_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::compute_pipeline_type = TComputePipeline

◆ descriptor_layout_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::descriptor_layout_type = factory_type::descriptor_layout_type

◆ factory_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::factory_type = TFactory

◆ frame_buffer_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::frame_buffer_type = render_pass_type::frame_buffer_type

◆ image_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::image_type = factory_type::image_type

◆ index_buffer_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::index_buffer_type = factory_type::index_buffer_type

◆ input_assembler_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::input_assembler_type = render_pipeline_type::input_assembler_type

◆ pipeline_layout_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::pipeline_layout_type = render_pipeline_type::pipeline_layout_type

◆ rasterizer_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::rasterizer_type = render_pipeline_type::rasterizer_type

◆ ray_tracing_pipeline_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::ray_tracing_pipeline_type = TRayTracingPipeline

◆ render_pass_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::render_pass_type = TRenderPass

◆ render_pipeline_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::render_pipeline_type = TRenderPipeline

◆ sampler_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::sampler_type = factory_type::sampler_type

◆ shader_program_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::shader_program_type = render_pipeline_type::shader_program_type

◆ surface_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::surface_type = TSurface

◆ swap_chain_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::swap_chain_type = TSwapChain

◆ top_level_acceleration_structure_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::top_level_acceleration_structure_type = factory_type::top_level_acceleration_structure_type

◆ vertex_buffer_type

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
using LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::vertex_buffer_type = factory_type::vertex_buffer_type

Constructor & Destructor Documentation

◆ GraphicsDevice() [1/3]

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::GraphicsDevice ( )
protecteddefaultnoexcept

◆ GraphicsDevice() [2/3]

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::GraphicsDevice ( GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier > && )
protecteddefaultnoexcept

◆ GraphicsDevice() [3/3]

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::GraphicsDevice ( const GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier > & )
protecteddefault

◆ ~GraphicsDevice()

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::~GraphicsDevice ( )
overridedefaultnoexcept

Member Function Documentation

◆ adapter()

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
const adapter_type & LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::adapter ( ) const
overridepure virtualnoexcept

Returns the graphics adapter, the device uses for drawing.

Returns
A reference of the graphics adapter, the device uses for drawing.

Implements LiteFX::Rendering::IGraphicsDevice.

Implemented in LiteFX::Rendering::Backends::DirectX12Device, and LiteFX::Rendering::Backends::VulkanDevice.

◆ computeAccelerationStructureSizes() [1/2]

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
virtual void LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::computeAccelerationStructureSizes ( const bottom_level_acceleration_structure_type & blas,
UInt64 & bufferSize,
UInt64 & scratchSize,
bool forUpdate = false ) const
pure virtual

◆ computeAccelerationStructureSizes() [2/2]

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
virtual void LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::computeAccelerationStructureSizes ( const top_level_acceleration_structure_type & tlas,
UInt64 & bufferSize,
UInt64 & scratchSize,
bool forUpdate = false ) const
pure virtual

◆ createQueue()

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
virtual SharedPtr< const command_queue_type > LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::createQueue ( QueueType type,
QueuePriority priority = QueuePriority::Normal )
pure virtual

◆ defaultQueue()

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
virtual const command_queue_type & LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::defaultQueue ( QueueType type) const
pure virtual

◆ factory()

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
const factory_type & LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::factory ( ) const
overridepure virtualnoexcept

Returns the factory instance, used to create instances from the device.

Returns
The factory instance, used to create instances from the device.

Implements LiteFX::Rendering::IGraphicsDevice.

Implemented in LiteFX::Rendering::Backends::DirectX12Device, and LiteFX::Rendering::Backends::VulkanDevice.

◆ makeBarrier()

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
virtual UniquePtr< barrier_type > LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::makeBarrier ( PipelineStage syncBefore,
PipelineStage syncAfter ) const
nodiscardpure virtual

◆ makeFrameBuffer() [1/2]

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
SharedPtr< frame_buffer_type > LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::makeFrameBuffer ( const Size2d & renderArea) const
inlinenodiscard

◆ makeFrameBuffer() [2/2]

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
virtual SharedPtr< frame_buffer_type > LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::makeFrameBuffer ( StringView name,
const Size2d & renderArea ) const
nodiscardpure virtual

◆ operator=() [1/2]

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
GraphicsDevice & LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::operator= ( const GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier > & )
protecteddefault

◆ operator=() [2/2]

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
GraphicsDevice & LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::operator= ( GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier > && )
protecteddefaultnoexcept

◆ surface()

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
const surface_type & LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::surface ( ) const
overridepure virtualnoexcept

Returns the surface, the device draws to.

Returns
A reference of the surface, the device draws to.

Implements LiteFX::Rendering::IGraphicsDevice.

Implemented in LiteFX::Rendering::Backends::DirectX12Device, and LiteFX::Rendering::Backends::VulkanDevice.

◆ swapChain() [1/2]

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
const swap_chain_type & LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::swapChain ( ) const
overridepure virtualnoexcept

Returns the swap chain, that contains the back and front buffers used for presentation.

Returns
The swap chain, that contains the back and front buffers used for presentation.

Implements LiteFX::Rendering::IGraphicsDevice.

Implemented in LiteFX::Rendering::Backends::DirectX12Device, and LiteFX::Rendering::Backends::VulkanDevice.

◆ swapChain() [2/2]

template<typename TFactory , typename TSurface , typename TGraphicsAdapter , typename TSwapChain , typename TCommandQueue , typename TRenderPass , typename TRenderPipeline , typename TComputePipeline , typename TRayTracingPipeline , typename TBarrier >
swap_chain_type & LiteFX::Rendering::GraphicsDevice< TFactory, TSurface, TGraphicsAdapter, TSwapChain, TCommandQueue, TRenderPass, TRenderPipeline, TComputePipeline, TRayTracingPipeline, TBarrier >::swapChain ( )
overridepure virtualnoexcept

Returns the swap chain, that contains the back and front buffers used for presentation.

Returns
The swap chain, that contains the back and front buffers used for presentation.

Implements LiteFX::Rendering::IGraphicsDevice.

Implemented in LiteFX::Rendering::Backends::DirectX12Device, and LiteFX::Rendering::Backends::VulkanDevice.