Template class implementing base functionality of the buffer object. More...
#include <BufferBase.hpp>
Public Member Functions | |
BufferBase (IReferenceCounters *pRefCounters, TBuffViewObjAllocator &BuffViewObjAllocator, RenderDeviceImplType *pDevice, const BufferDesc &BuffDesc, bool bIsDeviceInternal) | |
virtual void DILIGENT_CALL_TYPE | CreateView (const struct BufferViewDesc &ViewDesc, IBufferView **ppView) override |
virtual IBufferView *DILIGENT_CALL_TYPE | GetDefaultView (BUFFER_VIEW_TYPE ViewType) override |
Implementation of IBuffer::GetDefaultView(). | |
void | CreateDefaultViews () |
Creates default buffer views. | |
![]() | |
DeviceObjectBase (IReferenceCounters *pRefCounters, RenderDeviceImplType *pDevice, const BufferDesc &ObjDesc, bool bIsDeviceInternal=false) | |
virtual Int32 DILIGENT_CALL_TYPE | GetUniqueID () const override final |
Returns unique identifier. | |
virtual void DILIGENT_CALL_TYPE | SetUserData (IObject *pUserData) override final |
Implementation of IDeviceObject::SetUserData. | |
virtual IObject *DILIGENT_CALL_TYPE | GetUserData () const override final |
Implementation of IDeviceObject::GetUserData. | |
Protected Member Functions | |
virtual void | CreateViewInternal (const struct BufferViewDesc &ViewDesc, IBufferView **ppView, bool bIsDefaultView)=0 |
Pure virtual function that creates buffer view for the specific engine implementation. | |
Protected Attributes | |
std::unique_ptr< BufferViewImplType, STDDeleter< BufferViewImplType, TBuffViewObjAllocator > > | m_pDefaultUAV |
Default UAV addressing the entire buffer. | |
std::unique_ptr< BufferViewImplType, STDDeleter< BufferViewImplType, TBuffViewObjAllocator > > | m_pDefaultSRV |
Default SRV addressing the entire buffer. | |
![]() | |
RenderDeviceImplType *const | m_pDevice |
Pointer to the device. | |
BufferDesc | m_Desc |
Object description. | |
Template class implementing base functionality of the buffer object.
EngineImplTraits | - Engine implementation type traits. |
|
inline |
pRefCounters | - Reference counters object that controls the lifetime of this buffer. |
BuffViewObjAllocator | - Allocator that is used to allocate memory for the buffer view instances. This parameter is only used for debug purposes. |
pDevice | - Pointer to the device. |
BuffDesc | - Buffer description. |
bIsDeviceInternal | - Flag indicating if the buffer is an internal device object and must not keep a strong reference to the device. |
|
inline |
Creates default buffer views.
The function calls CreateViewInternal().
|
inlineoverridevirtual |
Implementation of IBuffer::CreateView(); calls CreateViewInternal() virtual function that creates buffer view for the specific engine implementation.