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

Template class implementing base functionality for a shader resource binding. More...

Inheritance diagram for Diligent::ShaderResourceBindingBase< BaseInterface, SRBAllocator >:
Diligent::ObjectBase< BaseInterface, SRBAllocator > Diligent::RefCountedObject< BaseInterface, SRBAllocator >

Public Member Functions

 ShaderResourceBindingBase (SRBAllocator &ObjAllocator, IPipelineState *pPSO, bool IsInternal=false)
 
virtual IPipelineStateGetPipelineState () override final
 Implementation of IShaderResourceBinding::GetPipelineState().
 

Protected Attributes

Diligent::RefCntAutoPtr< IPipelineStatem_spPSO
 Strong reference to PSO. We must use strong reference, because shader resource binding uses PSO's memory allocator to allocate memory for shader resource cache.
 

Detailed Description

template<class BaseInterface, class SRBAllocator>
class Diligent::ShaderResourceBindingBase< BaseInterface, SRBAllocator >

Template class implementing base functionality for a shader resource binding.

Template Parameters
BaseInterface- base interface that this class will inheret (Diligent::IShaderResourceBindingGL, Diligent::IShaderResourceBindingD3D11, or Diligent::IShaderResourceBindingD3D12).
SRBAllocator- type of the allocator that is used to allocate memory for the shader resource binding object instances

Constructor & Destructor Documentation

template<class BaseInterface, class SRBAllocator>
Diligent::ShaderResourceBindingBase< BaseInterface, SRBAllocator >::ShaderResourceBindingBase ( SRBAllocator &  ObjAllocator,
IPipelineState pPSO,
bool  IsInternal = false 
)
inline
Parameters
ObjAllocator- allocator that was used to allocate memory for this instance of the shader resource binding object
pPSO- pipeline state that this SRB belongs to.
IsInternal- flag indicating if the shader resource binding is an internal PSO object and must not keep a strong reference to the PSO.