Diligent Engine API Reference
Public Member Functions | Protected Attributes | List of all members
Diligent::BufferViewBase< BaseInterface, BuffViewObjAllocator > Class Template Reference

Template class implementing base functionality for a buffer view object. More...

Inheritance diagram for Diligent::BufferViewBase< BaseInterface, BuffViewObjAllocator >:
Diligent::DeviceObjectBase< BaseInterface, BufferViewDesc, BuffViewObjAllocator > Diligent::ObjectBase< BaseInterface, BuffViewObjAllocator > Diligent::RefCountedObject< BaseInterface, BuffViewObjAllocator >

Public Member Functions

 BufferViewBase (BuffViewObjAllocator &ObjAllocator, class IRenderDevice *pDevice, const BufferViewDesc &ViewDesc, class IBuffer *pBuffer, bool bIsDefaultView)
 
virtual IBufferGetBuffer () override final
 Implementation of IBufferView::GetBuffer()
 
- Public Member Functions inherited from Diligent::DeviceObjectBase< BaseInterface, BufferViewDesc, BuffViewObjAllocator >
 DeviceObjectBase (BuffViewObjAllocator &ObjAllocator, class IRenderDevice *pDevice, const BufferViewDesc &ObjDesc, IObject *pOwner=nullptr, bool bIsDeviceInternal=false)
 
UniqueIdentifier GetUniqueID () const
 Returns unique identifier. More...
 

Protected Attributes

IBuffer *const m_pBuffer
 Pointer to the buffer.
 
Diligent::RefCntAutoPtr< IBufferm_spBuffer
 Strong reference to the buffer. Used for non-default views to keep the buffer alive.
 
- Protected Attributes inherited from Diligent::DeviceObjectBase< BaseInterface, BufferViewDesc, BuffViewObjAllocator >
const String m_ObjectNameCopy
 Copy of a device object name. More...
 
BufferViewDesc m_Desc
 Object description.
 

Detailed Description

template<class BaseInterface, class BuffViewObjAllocator>
class Diligent::BufferViewBase< BaseInterface, BuffViewObjAllocator >

Template class implementing base functionality for a buffer view object.

Template Parameters
BaseInterface- base interface that this class will inheret (Diligent::IBufferViewD3D11, Diligent::IBufferViewD3D12 or Diligent::IBufferViewGL).
BuffViewObjAllocator- type of the allocator that is used to allocate memory for the buffer view object instances

Constructor & Destructor Documentation

template<class BaseInterface, class BuffViewObjAllocator>
Diligent::BufferViewBase< BaseInterface, BuffViewObjAllocator >::BufferViewBase ( BuffViewObjAllocator &  ObjAllocator,
class IRenderDevice pDevice,
const BufferViewDesc ViewDesc,
class IBuffer pBuffer,
bool  bIsDefaultView 
)
inline
Parameters
ObjAllocator- allocator that was used to allocate memory for this instance of the buffer view object
pDevice- pointer to the render device.
ViewDesc- buffer view description.
pBuffer- pointer to the buffer that the view is to be created for.
bIsDefaultView- flag indicating if the view is default view, and is thus part of the buffer object. In this case the view will attach to the buffer's reference counters.