Diligent Engine API Reference
Public Member Functions | List of all members
Diligent::BufferD3D12Impl Class Reference

Implementation of the Diligent::IBufferD3D12 interface. More...

Inheritance diagram for Diligent::BufferD3D12Impl:
Diligent::BufferBase< IBufferD3D12, BufferViewD3D12Impl, FixedBlockMemoryAllocator, FixedBlockMemoryAllocator > Diligent::D3D12ResourceBase Diligent::DeviceObjectBase< IBufferD3D12, BufferDesc, FixedBlockMemoryAllocator > Diligent::ObjectBase< IBufferD3D12, FixedBlockMemoryAllocator > Diligent::RefCountedObject< IBufferD3D12, FixedBlockMemoryAllocator > Diligent::IBufferD3D12 Diligent::IBuffer Diligent::IDeviceObject Diligent::IObject

Public Member Functions

virtual void QueryInterface (const Diligent::INTERFACE_ID &IID, IObject **ppInterface) override
 Queries the specific interface, see IObject::QueryInterface() for details.
 
virtual void UpdateData (IDeviceContext *pContext, Uint32 Offset, Uint32 Size, const PVoid pData) override
 Base implementation of IBuffer::UpdateData(); validates input parameters.
 
virtual void CopyData (IDeviceContext *pContext, IBuffer *pSrcBuffer, Uint32 SrcOffset, Uint32 DstOffset, Uint32 Size) override
 Base implementation of IBuffer::CopyData(); validates input parameters.
 
virtual void Map (IDeviceContext *pContext, MAP_TYPE MapType, Uint32 MapFlags, PVoid &pMappedData) override
 Base implementation of IBuffer::Map(); validates input parameters.
 
virtual void Unmap (IDeviceContext *pContext, MAP_TYPE MapType) override
 Base implementation of IBuffer::Unmap()
 
virtual ID3D12Resource * GetD3D12Buffer (size_t &DataStartByteOffset, Uint32 ContextId) override final
 Returns a pointer to the ID3D12Resource interface of the internal Direct3D12 object. More...
 
- Public Member Functions inherited from Diligent::BufferBase< IBufferD3D12, BufferViewD3D12Impl, FixedBlockMemoryAllocator, FixedBlockMemoryAllocator >
 BufferBase (FixedBlockMemoryAllocator &BuffObjAllocator, FixedBlockMemoryAllocator &BuffViewObjAllocator, IRenderDevice *pDevice, const BufferDesc &BuffDesc, bool bIsDeviceInternal=false)
 
virtual void CreateView (const struct BufferViewDesc &ViewDesc, IBufferView **ppView) override
 Implementation of IBuffer::CreateView(); calls CreateViewInternal() virtual function that creates buffer view for the specific engine implementation.
 
virtual IBufferViewGetDefaultView (BUFFER_VIEW_TYPE ViewType) override
 Implementation of IBuffer::GetDefaultView().
 
void CreateDefaultViews ()
 Creates default buffer views. More...
 
- Public Member Functions inherited from Diligent::DeviceObjectBase< IBufferD3D12, BufferDesc, FixedBlockMemoryAllocator >
 DeviceObjectBase (FixedBlockMemoryAllocator &ObjAllocator, class IRenderDevice *pDevice, const BufferDesc &ObjDesc, IObject *pOwner=nullptr, bool bIsDeviceInternal=false)
 
virtual const BufferDescGetDesc () const override final
 
UniqueIdentifier GetUniqueID () const
 Returns unique identifier. More...
 
- Public Member Functions inherited from Diligent::RefCountedObject< IBufferD3D12, FixedBlockMemoryAllocator >
virtual IReferenceCountersGetReferenceCounters () const override final
 
virtual Atomics::Long AddRef () override
 
virtual Atomics::Long Release () override
 

Additional Inherited Members

- Protected Member Functions inherited from Diligent::BufferBase< IBufferD3D12, BufferViewD3D12Impl, FixedBlockMemoryAllocator, FixedBlockMemoryAllocator >
void CorrectBufferViewDesc (struct BufferViewDesc &ViewDesc)
 Corrects buffer view description and validates view parameters.
 
- Protected Attributes inherited from Diligent::BufferBase< IBufferD3D12, BufferViewD3D12Impl, FixedBlockMemoryAllocator, FixedBlockMemoryAllocator >
std::unique_ptr< BufferViewD3D12Impl, STDDeleter< BufferViewD3D12Impl, FixedBlockMemoryAllocator > > m_pDefaultUAV
 Default UAV addressing the entire buffer.
 
std::unique_ptr< BufferViewD3D12Impl, STDDeleter< BufferViewD3D12Impl, FixedBlockMemoryAllocator > > m_pDefaultSRV
 Default SRV addressing the entire buffer.
 
- Protected Attributes inherited from Diligent::DeviceObjectBase< IBufferD3D12, BufferDesc, FixedBlockMemoryAllocator >
const String m_ObjectNameCopy
 Copy of a device object name. More...
 
BufferDesc m_Desc
 Object description.
 
- Protected Attributes inherited from Diligent::D3D12ResourceBase
CComPtr< ID3D12Resource > m_pd3d12Resource
 D3D12 buffer object.
 

Detailed Description

Implementation of the Diligent::IBufferD3D12 interface.

Member Function Documentation

virtual ID3D12Resource* Diligent::BufferD3D12Impl::GetD3D12Buffer ( size_t &  DataStartByteOffset,
Uint32  ContextId 
)
inlinefinaloverridevirtual

Returns a pointer to the ID3D12Resource interface of the internal Direct3D12 object.

The method does NOT call AddRef() on the returned interface, so Release() must not be called.

Parameters
[in]DataStartByteOffset- Offset from the beginning of the buffer to the start of the data. This parameter is required for dynamic buffers, which are suballocated in a dynamic upload heap
[in]ContextId- Id of the context within which address of the buffer is requested.

Implements Diligent::IBufferD3D12.