XII Release 0.1.0
Loading...
Searching...
No Matches
xiiGALDeviceD3D12 Class Referencefinal
Inheritance diagram for xiiGALDeviceD3D12:
[legend]

Public Member Functions

virtual xiiGALCommandQueueGetCommandQueue (xiiBitflags< xiiGALCommandQueueFlags > queueFlags) const override final
 Retrieves a pointer to the compute queue if available, null otherwise.
 
XII_ALWAYS_INLINE xiiAllocatorBaseGetAllocator () const
 
XII_ALWAYS_INLINE ID3D12Device1 * GetD3D12Device () const
 
XII_ALWAYS_INLINE IDXGIAdapter1 * GetDXGIAdapter () const
 
XII_ALWAYS_INLINE IDXGIFactory4 * GetDXGIFactory () const
 
XII_ALWAYS_INLINE xiiMemoryAllocatorD3D12GetD3D12Allocator () const
 
void ReportLiveGPUObjects ()
 
- Public Member Functions inherited from xiiGALDevice
xiiResult Initialize ()
 Initialize device.
 
void BeginFrame ()
 Begins a render frame.
 
void EndFrame ()
 Ends a render frame.
 
void WaitIdle ()
 Waits until all outstanding operations on the GPU are complete and destroys any pending resources and GPU objects.
 
const xiiGALDeviceCreationDescriptionGetDescription () const
 Returns the creation description for this device.
 
const xiiGALGraphicsDeviceAdapterDescriptionGetGraphicsDeviceAdapterProperties () const
 This retrieves the device properties. See xiiGraphicsDeviceAdapterDescription.
 
const xiiGALDeviceFeaturesGetFeatures () const
 This retrieves the device feature states. See xiiGALDeviceFeatures.
 
const xiiGALDeviceLimitsGetLimits () const
 This retrieves the device limits. See xiiGALDeviceLimits.
 
xiiEnum< xiiGALGraphicsDeviceTypeGetGraphicsDeviceType () const
 This retrieves the device graphics API type. See xiiGALGraphicsDeviceType.
 
xiiMutexGetMutex () const
 This returns critical section lock.
 
xiiSharedPtr< xiiGALSwapChainCreateSwapChain (const xiiGALSwapChainCreationDescription &description)
 This creates a swap chain object.
 
xiiSharedPtr< xiiGALCommandListCreateCommandList (const xiiGALCommandListCreationDescription &description)
 This creates a command list object.
 
xiiSharedPtr< xiiGALBlendStateCreateBlendState (const xiiGALBlendStateCreationDescription &description)
 This creates a new blend state object.
 
xiiSharedPtr< xiiGALDepthStencilStateCreateDepthStencilState (const xiiGALDepthStencilStateCreationDescription &description)
 This creates a new depth stencil state object.
 
xiiSharedPtr< xiiGALRasterizerStateCreateRasterizerState (const xiiGALRasterizerStateCreationDescription &description)
 This creates a new rasterizer state object.
 
xiiSharedPtr< xiiGALShaderCreateShader (const xiiGALShaderCreationDescription &description)
 This creates a new shader object.
 
xiiSharedPtr< xiiGALBufferCreateBuffer (const xiiGALBufferCreationDescription &description, const xiiGALBufferData *pInitialData=nullptr, xiiBitflags< xiiGALExternalMemoryKind > externalMemoryKind=xiiGALExternalMemoryKind::None)
 This creates a new buffer object.
 
xiiSharedPtr< xiiGALTextureCreateTexture (const xiiGALTextureCreationDescription &description, const xiiGALTextureData *pInitialData=nullptr, xiiBitflags< xiiGALExternalMemoryKind > externalMemoryKind=xiiGALExternalMemoryKind::None)
 This creates a new texture object.
 
xiiSharedPtr< xiiGALSamplerCreateSampler (const xiiGALSamplerCreationDescription &description)
 This creates a new sampler object.
 
xiiSharedPtr< xiiGALQueryCreateQuery (const xiiGALQueryCreationDescription &description)
 This creates a new query object.
 
xiiSharedPtr< xiiGALFenceCreateFence (const xiiGALFenceCreationDescription &description)
 This creates a new fence object.
 
xiiSharedPtr< xiiGALRenderPassCreateRenderPass (const xiiGALRenderPassCreationDescription &description)
 This creates a new render pass object.
 
xiiSharedPtr< xiiGALFramebufferCreateFramebuffer (const xiiGALFramebufferCreationDescription &description)
 This creates a new frame buffer object.
 
xiiSharedPtr< xiiGALBottomLevelASCreateBottomLevelAS (const xiiGALBottomLevelASCreationDescription &description)
 This creates a new bottom-level acceleration structure object.
 
xiiSharedPtr< xiiGALTopLevelASCreateTopLevelAS (const xiiGALTopLevelASCreationDescription &description)
 This creates a new top-level acceleration structure object.
 
xiiSharedPtr< xiiGALPipelineResourceSignatureCreatePipelineResourceSignature (xiiGALPipelineResourceSignatureCreationDescription &description)
 This creates a new pipeline resource signature object.
 
xiiSharedPtr< xiiGALGraphicsPipelineStateCreateGraphicsPipelineState (const xiiGALGraphicsPipelineStateCreationDescription &description)
 This creates a new graphics pipeline state object.
 
xiiSharedPtr< xiiGALComputePipelineStateCreateComputePipelineState (const xiiGALComputePipelineStateCreationDescription &description)
 This creates a new compute pipeline state object.
 
xiiSharedPtr< xiiGALRayTracingPipelineStateCreateRayTracingPipelineState (const xiiGALRayTracingPipelineStateCreationDescription &description)
 This creates a new ray tracing pipeline state object.
 
xiiSharedPtr< xiiGALTilePipelineStateCreateTilePipelineState (const xiiGALTilePipelineStateCreationDescription &description)
 This creates a new tile pipeline state object.
 
- Public Member Functions inherited from xiiGALObject
XII_ALWAYS_INLINE xiiStringView GetDebugName () const
 Returns the debug name of this resource.
 
void SetDebugName (xiiStringView sDebugName) const
 Sets the debug name for this resource.
 
- Public Member Functions inherited from xiiReflectedClass
virtual const xiiRTTIGetDynamicRTTI () const
 
bool IsInstanceOf (const xiiRTTI *pType) const
 Returns whether the type of this instance is of the given type or derived from it.
 
template<typename T>
XII_ALWAYS_INLINE bool IsInstanceOf () const
 Returns whether the type of this instance is of the given type or derived from it.
 
- Public Member Functions inherited from xiiRefCounted
virtual ~xiiRefCounted ()=default
 Adds a virtual destructor.
 
- Public Member Functions inherited from xiiRefCountingImpl
 xiiRefCountingImpl ()=default
 Constructor.
 
 xiiRefCountingImpl (const xiiRefCountingImpl &rhs)
 
void operator= (const xiiRefCountingImpl &rhs)
 
xiiUInt32 AddRef () const
 Increments the reference counter. Returns the new reference count.
 
xiiUInt32 ReleaseRef () const
 Decrements the reference counter. Returns the new reference count.
 
bool IsReferenced () const
 Returns true if the reference count is greater than 0, false otherwise.
 
xiiUInt32 GetRefCount () const
 Returns the current reference count.
 

Protected Member Functions

virtual xiiResult InitializePlatform () override final
 
virtual xiiResult PostInitializePlatform () override final
 
virtual void BeginFramePlatform () override final
 
virtual void EndFramePlatform () override final
 
virtual xiiInternal::NewInstance< xiiGALSwapChainCreateSwapChainPlatform (const xiiGALSwapChainCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALCommandListCreateCommandListPlatform (const xiiGALCommandListCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALBlendStateCreateBlendStatePlatform (const xiiGALBlendStateCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALDepthStencilStateCreateDepthStencilStatePlatform (const xiiGALDepthStencilStateCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALRasterizerStateCreateRasterizerStatePlatform (const xiiGALRasterizerStateCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALShaderCreateShaderPlatform (const xiiGALShaderCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALBufferCreateBufferPlatform (const xiiGALBufferCreationDescription &description, const xiiGALBufferData *pInitialData, xiiBitflags< xiiGALExternalMemoryKind > externalMemoryKind) override final
 
virtual xiiInternal::NewInstance< xiiGALTextureCreateTexturePlatform (const xiiGALTextureCreationDescription &description, const xiiGALTextureData *pInitialData, xiiBitflags< xiiGALExternalMemoryKind > externalMemoryKind) override final
 
virtual xiiInternal::NewInstance< xiiGALSamplerCreateSamplerPlatform (const xiiGALSamplerCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALQueryCreateQueryPlatform (const xiiGALQueryCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALFenceCreateFencePlatform (const xiiGALFenceCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALRenderPassCreateRenderPassPlatform (const xiiGALRenderPassCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALFramebufferCreateFramebufferPlatform (const xiiGALFramebufferCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALBottomLevelASCreateBottomLevelASPlatform (const xiiGALBottomLevelASCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALTopLevelASCreateTopLevelASPlatform (const xiiGALTopLevelASCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALPipelineResourceSignatureCreatePipelineResourceSignaturePlatform (const xiiGALPipelineResourceSignatureCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALGraphicsPipelineStateCreateGraphicsPipelineStatePlatform (const xiiGALGraphicsPipelineStateCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALComputePipelineStateCreateComputePipelineStatePlatform (const xiiGALComputePipelineStateCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALRayTracingPipelineStateCreateRayTracingPipelineStatePlatform (const xiiGALRayTracingPipelineStateCreationDescription &description) override final
 
virtual xiiInternal::NewInstance< xiiGALTilePipelineStateCreateTilePipelineStatePlatform (const xiiGALTilePipelineStateCreationDescription &description) override final
 
virtual void WaitIdlePlatform () override final
 
virtual xiiResult FillCapabilitiesPlatform () override final
 
- Protected Member Functions inherited from xiiGALDevice
 xiiGALDevice (xiiAllocatorBase *pAllocator, const xiiGALDeviceCreationDescription &creationDescription)
 
xiiResult PostInitialize ()
 Initialization after device capabilities are known.
 
void VerifyMultithreadedAccess () const
 Asserts that either this device supports multi-threaded resource creation, or that this function is executed on the main thread.
 
void FinalizeTextureInternal (const xiiGALTextureCreationDescription &description, xiiSharedPtr< xiiGALTexture > &pTexture)
 
void FinalizeBufferInternal (const xiiGALBufferCreationDescription &description, xiiSharedPtr< xiiGALBuffer > &pBuffer)
 
- Protected Member Functions inherited from xiiGALObject
virtual XII_ALWAYS_INLINE void SetDebugNamePlatform (xiiStringView sName) const
 

Friends

xiiInternal::NewInstance< xiiGALDeviceCreateD3D12Device (xiiAllocatorBase *pAllocator, const xiiGALDeviceCreationDescription &description)
 

Additional Inherited Members

- Static Public Member Functions inherited from xiiGALDevice
static void SetDefaultDevice (xiiSharedPtr< xiiGALDevice > pDefaultDevice)
 Sets a default graphics device.
 
static xiiSharedPtr< xiiGALDeviceGetDefaultDevice ()
 Retrieves the default device. This will be nullptr if none is set.
 
static bool HasDefaultDevice ()
 This returns true if there is a set default device.
 
- Static Public Member Functions inherited from xiiNoBase
static const xiiRTTIGetStaticRTTI ()
 
- Static Public Attributes inherited from xiiGALDevice
static xiiEvent< const xiiGALDeviceEvent &, xiiMutexs_Events
 Registers event handlers.
 
- Protected Attributes inherited from xiiGALDevice
xiiGALDeviceCreationDescription m_Description
 
xiiProxyAllocator m_Allocator
 
xiiLocalAllocatorWrapper m_AllocatorWrapper
 
xiiMutex m_Mutex
 
xiiGALGraphicsDeviceAdapterDescription m_AdapterDescription
 

Member Function Documentation

◆ FillCapabilitiesPlatform()

xiiResult xiiGALDeviceD3D12::FillCapabilitiesPlatform ( )
finaloverrideprotectedvirtual
Todo
GraphicsD3D12: Assert that structure sizes has not been modified.

◆ GetCommandQueue()

xiiGALCommandQueue * xiiGALDeviceD3D12::GetCommandQueue ( xiiBitflags< xiiGALCommandQueueFlags > queueFlags) const
finaloverridevirtual

Retrieves a pointer to the compute queue if available, null otherwise.

Parameters
queueType- The queue type that has the required feature.
Note
The default graphics queue is guaranteed to exist, for a successful device initialization.

Implements xiiGALDevice.

◆ InitializePlatform()

xiiResult xiiGALDeviceD3D12::InitializePlatform ( )
finaloverrideprotectedvirtual
Todo
GraphicsD3D12: Select best adapter ID by default, based on memory size, number of command queues, and prefer Discrete over Integrated over Software adapters.

◆ WaitIdlePlatform()

void xiiGALDeviceD3D12::WaitIdlePlatform ( )
finaloverrideprotectedvirtual
Todo
Idle all command queues.
Todo
Release stale resources.

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