Diligent Engine API Reference: Diligent::ShaderBase< BaseInterface, RenderDeviceBaseInterface > Class Template Reference

Diligent Engine API Reference

Public Member Functions | Protected Attributes | List of all members
Diligent::ShaderBase< BaseInterface, RenderDeviceBaseInterface > Class Template Reference

Template class implementing base functionality for a shader object. More...

Inheritance diagram for Diligent::ShaderBase< BaseInterface, RenderDeviceBaseInterface >:

## Public Member Functions
| ShaderBase (IReferenceCounters *pRefCounters, IRenderDevice *pDevice, const ShaderDesc &ShdrDesc, bool bIsDeviceInternal=false)
Public Member Functions inherited from Diligent::DeviceObjectBase< BaseInterface, ShaderDesc >
| DeviceObjectBase (IReferenceCounters *pRefCounters, IRenderDevice *pDevice, const ShaderDesc &ObjDesc, bool bIsDeviceInternal=false)
UniqueIdentifier | GetUniqueID () const
| Returns unique identifier. More...

## Protected Attributes
DummyShaderVariable | m_DummyShaderVar
| Dummy shader variable.
std::vector< ShaderVariableDesc, STDAllocatorRawMem< ShaderVariableDesc > > | m_VariablesDesc
| Shader variable descriptions.
std::vector< String, STDAllocatorRawMem< String > > | m_StringPool
| String pool that is used to hold copies of variable names and static sampler names.
std::vector< StaticSamplerDesc, STDAllocatorRawMem< StaticSamplerDesc > > | m_StaticSamplers
| Static sampler descriptions.
Protected Attributes inherited from Diligent::DeviceObjectBase< BaseInterface, ShaderDesc >
const String | m_ObjectNameCopy
| Copy of a device object name. More...
ShaderDesc | m_Desc
| Object description.

## Detailed Description

### template<class BaseInterface, class RenderDeviceBaseInterface>
class Diligent::ShaderBase< BaseInterface, RenderDeviceBaseInterface >

Template class implementing base functionality for a shader object.

Template Parameters

  BaseInterface | - base interface that this class will inheret (Diligent::IShaderD3D11, Diligent::IShaderD3D12 or Diligent::IShaderGL).
  RenderDeviceBaseInterface | - base interface for the render device (Diligent::IRenderDeviceD3D11, Diligent::IRenderDeviceD3D12, Diligent::IRenderDeviceGL, or Diligent::IRenderDeviceGLES).

## Constructor & Destructor Documentation

## ◆ ShaderBase()

template<class BaseInterface, class RenderDeviceBaseInterface>

Diligent::ShaderBase< BaseInterface, RenderDeviceBaseInterface >::ShaderBase | ( | IReferenceCounters * | pRefCounters,
|  | IRenderDevice * | pDevice,
|  | const ShaderDesc & | ShdrDesc,
|  | bool | bIsDeviceInternal = `false`
| ) |  |
| inline

Parameters

  pRefCounters | - reference counters object that controls the lifetime of this shader.
  pDevice | - pointer to the device.
  ShdrDesc | - shader description.
  bIsDeviceInternal | - flag indicating if the shader is an internal device object and must not keep a strong reference to the device.