Go to the documentation of this file.
96 static_cast<int>(DepthStencilDesc.
DepthFunc),
112 static_cast<int>(RasterizerDesc.
CullMode),
129 std::size_t Seed = 0;
130 for (
size_t i = 0; i < Diligent::MAX_RENDER_TARGETS; ++i)
135 static_cast<int>(rt.SrcBlend),
136 static_cast<int>(rt.DestBlend),
137 static_cast<int>(rt.BlendOp),
138 static_cast<int>(rt.SrcBlendAlpha),
139 static_cast<int>(rt.DestBlendAlpha),
140 static_cast<int>(rt.BlendOpAlpha),
141 rt.RenderTargetWriteMask);
157 std::size_t Seed = 0;
184 template <
typename EngineImplTraits>
219 Uint32 NumDeferredContexts) :
226 m_wpDeferredContexts (NumDeferredContexts, RefCntWeakPtr<IDeviceContext>(),
STD_ALLOCATOR_RAW_MEM(RefCntWeakPtr<IDeviceContext>, RawMemAllocator,
"Allocator for vector< RefCntWeakPtr<IDeviceContext> >")),
313 DEV_CHECK_ERR(ppMapping !=
nullptr,
"Null pointer provided");
314 if (ppMapping ==
nullptr)
316 DEV_CHECK_ERR(*ppMapping ==
nullptr,
"Overwriting reference to existing object may cause memory leaks");
319 pResourceMapping->QueryInterface(IID_ResourceMapping,
reinterpret_cast<IObject**
>(ppMapping));
320 if (MappingDesc.pEntries)
322 for (
auto* pEntry = MappingDesc.pEntries; pEntry->Name && pEntry->pObject; ++pEntry)
324 (*ppMapping)->AddResourceArray(pEntry->Name, pEntry->ArrayIndex, &pEntry->pObject, 1,
true);
347 VERIFY(TexFmtInfo.Format == TexFormat,
"Sanity check failed");
356 VERIFY(TexFmtInfo.Format == TexFormat,
"Sanity check failed");
359 if (TexFmtInfo.Supported)
413 template <
typename ObjectType,
typename ObjectDescType,
typename ObjectConstructorType>
415 const ObjectDescType& Desc,
416 ObjectType** ppObject,
417 ObjectConstructorType ConstructObject)
423 DEV_CHECK_ERR(*ppObject ==
nullptr,
"Overwriting reference to existing object may cause memory leaks");
440 VERIFY(*ppObject ==
nullptr,
"Object was created despite error");
443 (*ppObject)->Release();
447 if (!ObjectDescString.empty())
449 LOG_ERROR(
"Failed to create ", ObjectTypeName,
" object '", (Desc.Name ? Desc.Name :
""),
"'\n", ObjectDescString);
453 LOG_ERROR(
"Failed to create ", ObjectTypeName,
" object '", (Desc.Name ? Desc.Name :
""),
"'");
458 template <
typename PSOCreateInfoType,
typename... ExtraArgsType>
464 auto* pPipelineStateImpl{NEW_RC_OBJ(m_PSOAllocator,
"Pipeline State instance", PipelineStateImplType)(static_cast<RenderDeviceImplType*>(this), PSOCreateInfo, ExtraArgs...)};
469 template <
typename... ExtraArgsType>
472 CreateDeviceObject(
"Buffer", BuffDesc, ppBuffer,
476 pBufferImpl->QueryInterface(IID_Buffer,
reinterpret_cast<IObject**
>(ppBuffer));
477 pBufferImpl->CreateDefaultViews();
481 template <
typename... ExtraArgsType>
484 CreateDeviceObject(
"Texture", TexDesc, ppTexture,
488 pTextureImpl->QueryInterface(IID_Texture,
reinterpret_cast<IObject**
>(ppTexture));
489 pTextureImpl->CreateDefaultViews();
493 template <
typename... ExtraArgsType>
496 CreateDeviceObject(
"Shader", ShaderCI.
Desc, ppShader,
499 auto* pShaderImpl{NEW_RC_OBJ(m_ShaderObjAllocator,
"Shader instance", ShaderImplType)(static_cast<RenderDeviceImplType*>(this), ShaderCI, ExtraArgs...)};
504 template <
typename... ExtraArgsType>
507 CreateDeviceObject(
"Sampler",
SamplerDesc, ppSampler,
511 if (*ppSampler ==
nullptr)
514 pSamplerImpl->QueryInterface(IID_Sampler,
reinterpret_cast<IObject**
>(ppSampler));
522 CreateDeviceObject(
"Fence", Desc, ppFence,
526 pFenceImpl->QueryInterface(IID_Fence,
reinterpret_cast<IObject**
>(ppFence));
532 CreateDeviceObject(
"Query", Desc, ppQuery,
536 pQueryImpl->QueryInterface(IID_Query,
reinterpret_cast<IObject**
>(ppQuery));
540 template <
typename... ExtraArgsType>
543 CreateDeviceObject(
"RenderPass", Desc, ppRenderPass,
547 pRenderPassImpl->QueryInterface(IID_RenderPass,
reinterpret_cast<IObject**
>(ppRenderPass));
551 template <
typename... ExtraArgsType>
554 CreateDeviceObject(
"Framebuffer", Desc, ppFramebuffer,
558 pFramebufferImpl->QueryInterface(IID_Framebuffer,
reinterpret_cast<IObject**
>(ppFramebuffer));
562 template <
typename... ExtraArgsType>
565 CreateDeviceObject(
"BottomLevelAS", Desc, ppBLAS,
569 pBottomLevelASImpl->QueryInterface(IID_BottomLevelAS,
reinterpret_cast<IObject**
>(ppBLAS));
573 template <
typename... ExtraArgsType>
576 CreateDeviceObject(
"TopLevelAS", Desc, ppTLAS,
580 pTopLevelASImpl->QueryInterface(IID_TopLevelAS,
reinterpret_cast<IObject**
>(ppTLAS));
586 CreateDeviceObject(
"ShaderBindingTable", Desc, ppSBT,
590 pSBTImpl->QueryInterface(IID_ShaderBindingTable,
reinterpret_cast<IObject**
>(ppSBT));
594 template <
typename... ExtraArgsType>
597 CreateDeviceObject(
"PipelineResourceSignature", Desc, ppSignature,
601 pPRSImpl->QueryInterface(IID_PipelineResourceSignature,
reinterpret_cast<IObject**
>(ppSignature));
typename EngineGLImplTraits ::QueryImplType QueryImplType
Definition: RenderDeviceBase.hpp:201
void CreateFenceImpl(IFence **ppFence, const FenceDesc &Desc)
Definition: RenderDeviceBase.hpp:520
void CreatePipelineStateImpl(IPipelineState **ppPipelineState, const PSOCreateInfoType &PSOCreateInfo, const ExtraArgsType &... ExtraArgs)
Definition: RenderDeviceBase.hpp:459
TEXTURE_FORMAT Format
View format. If default value Diligent::TEX_FORMAT_UNKNOWN is provided, the view format will match th...
Definition: TextureView.h:94
virtual const TextureFormatInfoExt & GetTextureFormatInfoExt(TEXTURE_FORMAT TexFormat) override final
Implementation of IRenderDevice::GetTextureFormatInfoExt().
Definition: RenderDeviceBase.hpp:352
FixedBlockMemoryAllocator m_RenderPassAllocator
Allocator for render pass objects.
Definition: RenderDeviceBase.hpp:638
struct TextureFormatInfoExt TextureFormatInfoExt
Definition: GraphicsTypes.h:2618
void CreateTextureImpl(ITexture **ppTexture, const TextureDesc &TexDesc, const ExtraArgsType &... ExtraArgs)
Definition: RenderDeviceBase.hpp:482
Base interface for a reference counter object that stores the number of strong and weak references an...
Definition: ReferenceCounters.h:44
size_t GetNumDeferredContexts() const
Returns number of deferred contexts.
Definition: RenderDeviceBase.hpp:388
typename EngineGLImplTraits ::TopLevelASImplType TopLevelASImplType
Definition: RenderDeviceBase.hpp:205
char Char
Definition: BasicTypes.h:64
Sampler description.
Definition: Sampler.h:58
@ TEX_FORMAT_RG16_FLOAT
Two-component 32-bit half-precision floating-point format with 16-bit channels. D3D counterpart: DX...
Definition: GraphicsTypes.h:477
@ TEX_FORMAT_R32_FLOAT
Single-component 32-bit floating-point format. D3D counterpart: DXGI_FORMAT_R32_FLOAT....
Definition: GraphicsTypes.h:509
FILTER_TYPE MagFilter
Texture magnification filter, see Diligent::FILTER_TYPE for details. Default value: Diligent::FILTER_...
Definition: Sampler.h:66
typename EngineGLImplTraits ::ShaderBindingTableImplType ShaderBindingTableImplType
Definition: RenderDeviceBase.hpp:206
String GetObjectDescString(const TObjectDescType &)
Helper template function that converts object description into a string.
Definition: GraphicsAccessories.hpp:355
Extended texture format information.
Definition: GraphicsTypes.h:2595
Texture sampler interface.
Definition: Sampler.h:192
Pipeline resource signature interface.
Definition: PipelineResourceSignature.h:226
Bool IndependentBlendEnable
Specifies whether to enable independent blending in simultaneous render targets. If set to False,...
Definition: BlendState.h:382
@ TEX_FORMAT_R24_UNORM_X8_TYPELESS
Two-component 32-bit format with 24 bits for unsigned-normalized-integer data and 8 bits of unreferen...
Definition: GraphicsTypes.h:529
Uint32 MostDetailedMip
Most detailed mip level to use.
Definition: TextureView.h:97
Pipeline resource signature description.
Definition: PipelineResourceSignature.h:166
typename EngineGLImplTraits ::FramebufferImplType FramebufferImplType
Definition: RenderDeviceBase.hpp:203
Shader binding table interface.
Definition: ShaderBindingTable.h:93
typename EngineGLImplTraits ::FenceImplType FenceImplType
Definition: RenderDeviceBase.hpp:200
std::vector< RefCntWeakPtr< IDeviceContext >, STDAllocatorRawMem< RefCntWeakPtr< IDeviceContext > > > m_wpDeferredContexts
Weak references to deferred contexts.
Definition: RenderDeviceBase.hpp:624
@ TEX_FORMAT_RGBA16_SNORM
Four-component 64-bit signed-normalized-integer format with 16-bit channels. D3D counterpart: DXGI_...
Definition: GraphicsTypes.h:392
Top-level AS description.
Definition: TopLevelAS.h:49
Pipeline state interface.
Definition: PipelineState.h:505
Float32 BorderColor[4]
Border color to use if TEXTURE_ADDRESS_BORDER is specified for AddressU, AddressV,...
Definition: Sampler.h:100
RefCntAutoPtr< IDeviceContext > GetImmediateContext()
Definition: RenderDeviceBase.hpp:393
Query description.
Definition: Query.h:150
FixedBlockMemoryAllocator m_SRBAllocator
Allocator for shader resource binding objects.
Definition: RenderDeviceBase.hpp:634
FixedBlockMemoryAllocator & GetSRBAllocator()
Definition: RenderDeviceBase.hpp:398
Implementation of weak pointers.
Definition: RefCntAutoPtr.hpp:40
DeviceCaps m_DeviceCaps
Definition: RenderDeviceBase.hpp:609
struct StencilOpDesc StencilOpDesc
Definition: DepthStencilState.h:148
@ TEX_FORMAT_BC1_UNORM
Four-component unsigned-normalized-integer block-compression format with 5 bits for R,...
Definition: GraphicsTypes.h:647
virtual void TestTextureFormat(TEXTURE_FORMAT TexFormat)=0
Shader interface.
Definition: Shader.h:428
@ TEX_FORMAT_RG16_SNORM
Two-component 32-bit signed-normalized-integer format with 16-bit channels. D3D counterpart: DXGI_F...
Definition: GraphicsTypes.h:493
Base interface for all dynamic objects in the engine.
Definition: Object.h:41
FixedBlockMemoryAllocator & GetTexViewObjAllocator()
Definition: RenderDeviceBase.hpp:396
Uint32 NumMipLevels
Total number of mip levels for the view of the texture. Render target and depth stencil views can add...
Definition: TextureView.h:104
FixedBlockMemoryAllocator m_ShaderObjAllocator
Allocator for shader objects.
Definition: RenderDeviceBase.hpp:631
Bool AlphaToCoverageEnable
Specifies whether to use alpha-to-coverage as a multisampling technique when setting a pixel to a ren...
Definition: BlendState.h:378
DeviceProperties m_DeviceProperties
Definition: RenderDeviceBase.hpp:610
typename EngineGLImplTraits ::RenderPassImplType RenderPassImplType
Definition: RenderDeviceBase.hpp:202
COMPARISON_FUNCTION ComparisonFunc
A function that compares sampled data against existing sampled data when comparsion filter is used....
Definition: Sampler.h:96
Top-level AS interface.
Definition: TopLevelAS.h:151
Bool StencilEnable
Enable stencil opertaions. Default value: False.
Definition: DepthStencilState.h:173
Uint32 NumArraySlices
For a texture array, number of array slices to address in the view. Set to 0 to address all array sli...
Definition: TextureView.h:119
STENCIL_OP StencilDepthFailOp
The stencil operation to perform when stencil testing passes and depth testing fails....
Definition: DepthStencilState.h:106
@ TEX_FORMAT_R11G11B10_FLOAT
Three-component 32-bit format encoding three partial precision channels using 11 bits for red and gre...
Definition: GraphicsTypes.h:445
std::vector< TextureFormatInfoExt, STDAllocatorRawMem< TextureFormatInfoExt > > m_TextureFormatsInfo
Definition: RenderDeviceBase.hpp:616
void CreateSBTImpl(IShaderBindingTable **ppSBT, const ShaderBindingTableDesc &Desc)
Definition: RenderDeviceBase.hpp:584
@ TEX_FORMAT_NUM_FORMATS
Helper member containing the total number of texture formats in the enumeration.
Definition: GraphicsTypes.h:856
@ TEX_FORMAT_RGBA16_FLOAT
Four-component 64-bit half-precision floating-point format with 16-bit channels. D3D counterpart: D...
Definition: GraphicsTypes.h:375
#define LOG_ERROR(...)
Definition: Errors.hpp:76
@ TEX_FORMAT_BC3_UNORM
Four-component unsigned-normalized-integer block-compression format with 5 bits for R,...
Definition: GraphicsTypes.h:699
Uint8 StencilWriteMask
Identify which bits of the depth-stencil buffer are accessed when writing stencil data....
Definition: DepthStencilState.h:181
COMPARISON_FUNCTION StencilFunc
A function that compares stencil data against existing stencil data. Default value: Diligent::COMPARI...
Definition: DepthStencilState.h:114
Framebuffer interface.
Definition: Framebuffer.h:73
FixedBlockMemoryAllocator m_FramebufferAllocator
Allocator for framebuffer objects.
Definition: RenderDeviceBase.hpp:639
Resource mapping description.
Definition: ResourceMapping.h:75
UAV_ACCESS_FLAG AccessFlags
For an unordered access view, allowed access flags. See Diligent::UAV_ACCESS_FLAG for details.
Definition: TextureView.h:128
#define DEV_CHECK_ERR(...)
Definition: DebugUtilities.hpp:90
@ TEX_FORMAT_RGBA8_SNORM
Four-component 32-bit signed-normalized-integer format with 8-bit channels. D3D counterpart: DXGI_F...
Definition: GraphicsTypes.h:465
typename EngineGLImplTraits ::PipelineStateImplType PipelineStateImplType
Definition: RenderDeviceBase.hpp:192
Render pass description.
Definition: RenderPass.h:341
Base interface for all objects created by the render device Diligent::IRenderDevice.
Definition: DeviceObject.h:52
@ TEX_FORMAT_A8_UNORM
Single-component 8-bit unsigned-normalized-integer format for alpha only. D3D counterpart: DXGI_FOR...
Definition: GraphicsTypes.h:611
void CreatePipelineResourceSignatureImpl(IPipelineResourceSignature **ppSignature, const PipelineResourceSignatureDesc &Desc, const ExtraArgsType &... ExtraArgs)
Definition: RenderDeviceBase.hpp:595
Template class implementing base functionality for an object.
Definition: ObjectBase.hpp:66
Shader creation attributes.
Definition: Shader.h:241
virtual const TextureFormatInfo & GetTextureFormatInfo(TEXTURE_FORMAT TexFormat) override final
Implementation of IRenderDevice::GetTextureFormatInfo().
Definition: RenderDeviceBase.hpp:343
@ TEX_FORMAT_R16_SNORM
Single-component 16-bit signed-normalized-integer format. D3D counterpart: DXGI_FORMAT_R16_SNORM....
Definition: GraphicsTypes.h:582
Buffer interface.
Definition: Buffer.h:187
Rasterizer state description.
Definition: RasterizerState.h:96
Float32 MipLODBias
Offset from the calculated mipmap level. For example, if a sampler calculates that a texture should b...
Definition: Sampler.h:89
@ TEX_FORMAT_BC3_UNORM_SRGB
Four-component unsigned-normalized-integer block-compression sRGB format with 5 bits for R,...
Definition: GraphicsTypes.h:708
virtual void QueryInterface(const INTERFACE_ID &IID, IObject **ppInterface)=0
Queries the specific interface.
FixedBlockMemoryAllocator m_SBTAllocator
Allocator for shader binding table objects.
Definition: RenderDeviceBase.hpp:642
@ TEX_FORMAT_UNKNOWN
Unknown format.
Definition: GraphicsTypes.h:331
StencilOpDesc BackFace
Identify stencil operations for the back-facing triangles, see Diligent::StencilOpDesc.
Definition: DepthStencilState.h:187
Definition: STDAllocator.hpp:53
Uint32 MaxAnisotropy
Maximum anisotropy level for the anisotropic filter. Default value: 0.
Definition: Sampler.h:92
Uint8 StencilReadMask
Identify which bits of the depth-stencil buffer are accessed when reading stencil data....
Definition: DepthStencilState.h:177
size_t operator()(const Diligent::RasterizerStateDesc &RasterizerDesc) const
Definition: RenderDeviceBase.hpp:109
FixedBlockMemoryAllocator m_FenceAllocator
Allocator for fence objects.
Definition: RenderDeviceBase.hpp:636
TEXTURE_ADDRESS_MODE AddressW
Texture address mode for W coordinate, see Diligent::TEXTURE_ADDRESS_MODE for details Default value: ...
Definition: Sampler.h:84
Shader binding table description.
Definition: ShaderBindingTable.h:50
int32_t Int32
32-bit signed integer
Definition: BasicTypes.h:46
typename EngineGLImplTraits ::TextureViewImplType TextureViewImplType
Definition: RenderDeviceBase.hpp:197
size_t operator()(const Diligent::DepthStencilStateDesc &DepthStencilDesc) const
Definition: RenderDeviceBase.hpp:92
FixedBlockMemoryAllocator m_ResMappingAllocator
Allocator for resource mapping objects.
Definition: RenderDeviceBase.hpp:635
typename EngineGLImplTraits ::RenderDeviceImplType RenderDeviceImplType
Definition: RenderDeviceBase.hpp:191
@ TEX_FORMAT_BC1_UNORM_SRGB
Four-component unsigned-normalized-integer block-compression sRGB format with 5 bits for R,...
Definition: GraphicsTypes.h:656
@ TEX_FORMAT_BC2_UNORM
Four-component unsigned-normalized-integer block-compression format with 5 bits for R,...
Definition: GraphicsTypes.h:673
TEXTURE_VIEW_TYPE ViewType
Describes the texture view type, see Diligent::TEXTURE_VIEW_TYPE for details.
Definition: TextureView.h:83
Describes stencil operations that are performed based on the results of depth test.
Definition: DepthStencilState.h:98
@ TEX_FORMAT_R8_UNORM
Single-component 8-bit unsigned-normalized-integer format. D3D counterpart: DXGI_FORMAT_R8_UNORM....
Definition: GraphicsTypes.h:594
Texture description.
Definition: Texture.h:47
Uint32 FirstArraySlice
For a texture array, first array slice to address in the view.
Definition: TextureView.h:109
Float32 SlopeScaledDepthBias
Scalar that scales the given pixel's slope before adding to the pixel's depth. Default value: 0.
Definition: RasterizerState.h:136
@ TEX_FORMAT_B5G6R5_UNORM
Three-component 16-bit unsigned-normalized-integer format with 5 bits for blue, 6 bits for green,...
Definition: GraphicsTypes.h:765
@ TEX_FORMAT_BC4_UNORM
One-component unsigned-normalized-integer block-compression format with 8 bits for R channel....
Definition: GraphicsTypes.h:725
RenderDeviceBase(IReferenceCounters *pRefCounters, IMemoryAllocator &RawMemAllocator, IEngineFactory *pEngineFactory, Uint32 NumDeferredContexts)
Definition: RenderDeviceBase.hpp:216
FixedBlockMemoryAllocator m_BufObjAllocator
Allocator for buffer objects.
Definition: RenderDeviceBase.hpp:629
IMemoryAllocator & GetRawAllocator()
Returns raw memory allocator.
Definition: EngineMemory.cpp:51
FixedBlockMemoryAllocator m_TexViewObjAllocator
Allocator for texture view objects.
Definition: RenderDeviceBase.hpp:628
size_t operator()(const Diligent::StencilOpDesc &StOpDesc) const
Definition: RenderDeviceBase.hpp:79
Bool AntialiasedLineEnable
Specifies whether to enable line antialiasing. Default value: False.
Definition: RasterizerState.h:123
struct TextureFormatAttribs TextureFormatAttribs
Definition: GraphicsTypes.h:2542
typename EngineGLImplTraits ::ShaderResourceBindingImplType ShaderResourceBindingImplType
Definition: RenderDeviceBase.hpp:193
IMemoryAllocator & m_RawMemAllocator
Raw memory allocator.
Definition: RenderDeviceBase.hpp:626
@ TEX_FORMAT_R8_SNORM
Single-component 8-bit signed-normalized-integer format. D3D counterpart: DXGI_FORMAT_R8_SNORM....
Definition: GraphicsTypes.h:602
typename EngineGLImplTraits ::PipelineResourceSignatureImplType PipelineResourceSignatureImplType
Definition: RenderDeviceBase.hpp:207
RenderTargetBlendDesc RenderTargets[DILIGENT_MAX_RENDER_TARGETS]
An array of RenderTargetBlendDesc structures that describe the blend states for render targets.
Definition: BlendState.h:386
@ TEX_FORMAT_RGBA32_FLOAT
Four-component 128-bit floating-point format with 32-bit channels. D3D counterpart: DXGI_FORMAT_R32...
Definition: GraphicsTypes.h:339
Bool ScissorEnable
Enable scissor-rectangle culling. All pixels outside an active scissor rectangle are culled....
Definition: RasterizerState.h:119
#define IMPLEMENT_QUERY_INTERFACE_IN_PLACE(InterfaceID, ParentClassName)
Definition: ObjectBase.hpp:59
@ TEX_FORMAT_R16_FLOAT
Single-component 16-bit half-precisoin floating-point format. D3D counterpart: DXGI_FORMAT_R16_FLOA...
Definition: GraphicsTypes.h:562
typename EngineGLImplTraits ::RenderDeviceInterface BaseInterface
Definition: RenderDeviceBase.hpp:188
Device properties.
Definition: GraphicsTypes.h:1970
TEXTURE_VIEW_FLAGS Flags
Texture view flags, see Diligent::TEXTURE_VIEW_FLAGS.
Definition: TextureView.h:131
FixedBlockMemoryAllocator m_BLASAllocator
Allocator for bottom-level acceleration structure objects.
Definition: RenderDeviceBase.hpp:640
Template class that implements reference counting.
Definition: RefCntAutoPtr.hpp:73
void SetDeferredContext(size_t Ctx, IDeviceContext *pDeferredCtx)
Set weak reference to the deferred context.
Definition: RenderDeviceBase.hpp:381
float MaxLOD
Specifies the maximum value that LOD is clamped to before accessing the texture MIP levels....
Definition: Sampler.h:110
@ TEX_FORMAT_RG16_UNORM
Two-component 32-bit unsigned-normalized-integer format with 16-bit channels. D3D counterpart: DXGI...
Definition: GraphicsTypes.h:483
#define DILIGENT_CALL_TYPE
Definition: CommonDefinitions.h:45
COMPARISON_FUNCTION DepthFunc
A function that compares depth data against existing depth data. See Diligent::COMPARISON_FUNCTION fo...
Definition: DepthStencilState.h:170
void CreateRenderPassImpl(IRenderPass **ppRenderPass, const RenderPassDesc &Desc, const ExtraArgsType &... ExtraArgs)
Definition: RenderDeviceBase.hpp:541
struct TextureViewDesc TextureViewDesc
Definition: TextureView.h:183
STENCIL_OP StencilFailOp
The stencil operation to perform when stencil testing fails. Default value: Diligent::STENCIL_OP_KEEP...
Definition: DepthStencilState.h:102
struct BlendStateDesc BlendStateDesc
Definition: BlendState.h:431
Float32 DepthBiasClamp
Maximum depth bias of a pixel.
Definition: RasterizerState.h:132
uint32_t Uint32
32-bit unsigned integer
Definition: BasicTypes.h:51
@ TEX_FORMAT_RGBA8_UNORM
Four-component 32-bit unsigned-normalized-integer format with 8-bit channels. D3D counterpart: DXGI...
Definition: GraphicsTypes.h:453
@ TEX_FORMAT_BC5_SNORM
Two-component signed-normalized-integer block-compression format with 8 bits for R and 8 bits for G c...
Definition: GraphicsTypes.h:760
float MinLOD
Specifies the minimum value that LOD is clamped to before accessing the texture MIP levels....
Definition: Sampler.h:105
std::size_t ComputeHash(const ArgsType &... Args)
Definition: HashUtils.hpp:57
Template class implementing state object registry.
Definition: StateObjectsRegistry.hpp:62
FixedBlockMemoryAllocator m_QueryAllocator
Allocator for query objects.
Definition: RenderDeviceBase.hpp:637
FixedBlockMemoryAllocator m_BuffViewObjAllocator
Allocator for buffer view objects.
Definition: RenderDeviceBase.hpp:630
@ TEX_FORMAT_RG32_FLOAT
Two-component 64-bit floating-point format with 32-bit channels. D3D counterpart: DXGI_FORMAT_R32G3...
Definition: GraphicsTypes.h:404
typename EngineGLImplTraits ::ShaderImplType ShaderImplType
Definition: RenderDeviceBase.hpp:198
virtual ReferenceCounterValueType Release() override
Definition: RefCountedObjectImpl.hpp:552
FixedBlockMemoryAllocator m_PipeResSignAllocator
Allocator for pipeline resource signature objects.
Definition: RenderDeviceBase.hpp:643
@ TEX_FORMAT_RG8_SNORM
Two-component 16-bit signed-normalized-integer format with 8-bit channels. D3D counterpart: DXGI_FO...
Definition: GraphicsTypes.h:550
void CreateBufferImpl(IBuffer **ppBuffer, const BufferDesc &BuffDesc, const ExtraArgsType &... ExtraArgs)
Definition: RenderDeviceBase.hpp:470
Basic texture format description.
Definition: GraphicsTypes.h:2548
void CreateBLASImpl(IBottomLevelAS **ppBLAS, const BottomLevelASDesc &Desc, const ExtraArgsType &... ExtraArgs)
Definition: RenderDeviceBase.hpp:563
typename EngineGLImplTraits ::BufferViewImplType BufferViewImplType
Definition: RenderDeviceBase.hpp:195
void SetImmediateContext(IDeviceContext *pImmediateContext)
Set weak reference to the immediate context.
Definition: RenderDeviceBase.hpp:374
RESOURCE_DIMENSION TextureDim
View interpretation of the original texture. For instance, one slice of a 2D texture array can be vie...
Definition: TextureView.h:90
Bool DepthWriteEnable
Enable or disable writes to a depth buffer. Default value: True.
Definition: DepthStencilState.h:165
FixedBlockMemoryAllocator m_PSOAllocator
Allocator for pipeline state objects.
Definition: RenderDeviceBase.hpp:633
struct DepthStencilStateDesc DepthStencilStateDesc
Definition: DepthStencilState.h:233
TEXTURE_ADDRESS_MODE AddressV
Texture address mode for V coordinate, see Diligent::TEXTURE_ADDRESS_MODE for details Default value: ...
Definition: Sampler.h:80
FixedBlockMemoryAllocator & GetBuffViewObjAllocator()
Definition: RenderDeviceBase.hpp:397
~RenderDeviceBase()
Definition: RenderDeviceBase.hpp:297
virtual const DeviceProperties & GetDeviceProperties() const override final
Implementation of IRenderDevice::GetDeviceProperties().
Definition: RenderDeviceBase.hpp:337
@ TEX_FORMAT_RGBA16_UNORM
Four-component 64-bit unsigned-normalized-integer format with 16-bit channels. D3D counterpart: DXG...
Definition: GraphicsTypes.h:381
TEXTURE_FORMAT
Texture formats.
Definition: GraphicsTypes.h:328
RefCntAutoPtr< IDeviceContext > GetDeferredContext(size_t Ctx)
Definition: RenderDeviceBase.hpp:394
StateObjectsRegistry< SamplerDesc > m_SamplersRegistry
Sampler state registry.
Definition: RenderDeviceBase.hpp:615
void CreateQueryImpl(IQuery **ppQuery, const QueryDesc &Desc)
Definition: RenderDeviceBase.hpp:530
Buffer description.
Definition: Buffer.h:74
RefCntAutoPtr< IEngineFactory > m_pEngineFactory
Definition: RenderDeviceBase.hpp:607
FILL_MODE FillMode
Determines traingle fill mode, see Diligent::FILL_MODE for details. Default value: Diligent::FILL_MOD...
Definition: RasterizerState.h:100
FixedBlockMemoryAllocator m_TLASAllocator
Allocator for top-level acceleration structure objects.
Definition: RenderDeviceBase.hpp:641
Base interface for a raw memory allocator.
Definition: MemoryAllocator.h:41
void CreateSamplerImpl(ISampler **ppSampler, const SamplerDesc &SamplerDesc, const ExtraArgsType &... ExtraArgs)
Definition: RenderDeviceBase.hpp:505
virtual void CreateResourceMapping(const ResourceMappingDesc &MappingDesc, IResourceMapping **ppMapping) override final
Implementation of IRenderDevice::CreateResourceMapping().
Definition: RenderDeviceBase.hpp:311
FILTER_TYPE MinFilter
Texture minification filter, see Diligent::FILTER_TYPE for details. Default value: Diligent::FILTER_T...
Definition: Sampler.h:62
Device capabilities.
Definition: GraphicsTypes.h:1833
Fence interface.
Definition: Fence.h:62
Definition: AdvancedMath.hpp:979
StencilOpDesc FrontFace
Identify stencil operations for the front-facing triangles, see Diligent::StencilOpDesc.
Definition: DepthStencilState.h:184
FixedBlockMemoryAllocator m_TexObjAllocator
Allocator for texture objects.
Definition: RenderDeviceBase.hpp:627
typename EngineGLImplTraits ::BottomLevelASImplType BottomLevelASImplType
Definition: RenderDeviceBase.hpp:204
CULL_MODE CullMode
Determines traingle cull mode, see Diligent::CULL_MODE for details. Default value: Diligent::CULL_MOD...
Definition: RasterizerState.h:104
Device context interface.
Definition: DeviceContext.h:1460
void CreateTLASImpl(ITopLevelAS **ppTLAS, const TopLevelASDesc &Desc, const ExtraArgsType &... ExtraArgs)
Definition: RenderDeviceBase.hpp:574
@ TEX_FORMAT_G8R8_G8B8_UNORM
Four-component unsigned-normalized integer format analogous to YUY2 encoding. D3D counterpart: DXGI...
Definition: GraphicsTypes.h:630
#define STD_ALLOCATOR_RAW_MEM(Type, Allocator, Description)
Definition: STDAllocator.hpp:179
Int32 DepthBias
Constant value added to the depth of a given pixel. Default value: 0.
Definition: RasterizerState.h:127
Query interface.
Definition: Query.h:177
@ TEX_FORMAT_R32_FLOAT_X8X24_TYPELESS
Two-component 64-bit format with 32-bit floating-point R channel and 8+24-bits of typeless data....
Definition: GraphicsTypes.h:424
struct SamplerDesc SamplerDesc
Definition: Sampler.h:172
typename EngineGLImplTraits ::SamplerImplType SamplerImplType
Definition: RenderDeviceBase.hpp:199
@ TEX_FORMAT_BC4_SNORM
One-component signed-normalized-integer block-compression format with 8 bits for R channel....
Definition: GraphicsTypes.h:734
@ TEX_FORMAT_RGBA8_UNORM_SRGB
Four-component 32-bit unsigned-normalized-integer sRGB format with 8-bit channels....
Definition: GraphicsTypes.h:457
Framebuffer description.
Definition: Framebuffer.h:46
@ TEX_FORMAT_R16_UNORM
Single-component 16-bit unsigned-normalized-integer format. D3D counterpart: DXGI_FORMAT_R16_UNORM....
Definition: GraphicsTypes.h:572
Bool FrontCounterClockwise
Determines if a triangle is front- or back-facing. If this parameter is True, a triangle will be cons...
Definition: RasterizerState.h:111
Bottom-level AS interface.
Definition: BottomLevelAS.h:207
#define VERIFY(...)
Definition: DebugUtilities.hpp:76
Memory allocator that allocates memory in a fixed-size chunks.
Definition: FixedBlockMemoryAllocator.hpp:56
virtual ReferenceCounterValueType Release() override final
Definition: RenderDeviceBase.hpp:305
size_t operator()(const Diligent::BlendStateDesc &BSDesc) const
Definition: RenderDeviceBase.hpp:127
size_t operator()(const Diligent::TextureViewDesc &TexViewDesc) const
Definition: RenderDeviceBase.hpp:155
@ TEX_FORMAT_RGB9E5_SHAREDEXP
Three partial-precision floating pointer numbers sharing single exponent encoded into a 32-bit value....
Definition: GraphicsTypes.h:620
virtual IEngineFactory * GetEngineFactory() const override final
Definition: RenderDeviceBase.hpp:366
void CreateShaderImpl(IShader **ppShader, const ShaderCreateInfo &ShaderCI, const ExtraArgsType &... ExtraArgs)
Definition: RenderDeviceBase.hpp:494
long ReferenceCounterValueType
Definition: ReferenceCounters.h:37
STENCIL_OP StencilPassOp
The stencil operation to perform when stencil testing and depth testing both pass....
Definition: DepthStencilState.h:110
typename EngineGLImplTraits ::TextureImplType TextureImplType
Definition: RenderDeviceBase.hpp:196
Implementation of the resource mapping.
Definition: ResourceMappingImpl.hpp:47
void CreateFramebufferImpl(IFramebuffer **ppFramebuffer, const FramebufferDesc &Desc, const ExtraArgsType &... ExtraArgs)
Definition: RenderDeviceBase.hpp:552
Bool DepthEnable
Enable depth-stencil operations. When it is set to False, depth test always passes,...
Definition: DepthStencilState.h:162
std::vector< bool, STDAllocatorRawMem< bool > > m_TexFmtInfoInitFlags
Definition: RenderDeviceBase.hpp:617
FILTER_TYPE MipFilter
Mip filter, see Diligent::FILTER_TYPE for details. Only FILTER_TYPE_POINT, FILTER_TYPE_LINEAR,...
Definition: Sampler.h:72
Texture view description.
Definition: TextureView.h:80
@ TEX_FORMAT_RG8_B8G8_UNORM
Four-component unsigned-normalized integer format analogous to UYVY encoding. D3D counterpart: DXGI...
Definition: GraphicsTypes.h:625
Bottom-level AS description.
Definition: BottomLevelAS.h:145
const TextureFormatAttribs & GetTextureFormatAttribs(TEXTURE_FORMAT Format)
Returns invariant texture format attributes, see TextureFormatAttribs for details.
Definition: GraphicsAccessories.cpp:250
TEXTURE_ADDRESS_MODE AddressU
Texture address mode for U coordinate, see Diligent::TEXTURE_ADDRESS_MODE for details Default value: ...
Definition: Sampler.h:76
Bool DepthClipEnable
Enable clipping against near and far clip planes. Default value: True.
Definition: RasterizerState.h:115
typename EngineGLImplTraits ::BufferImplType BufferImplType
Definition: RenderDeviceBase.hpp:194
Engine factory base interface.
Definition: EngineFactory.h:60
@ TEX_FORMAT_RG8_UNORM
Two-component 16-bit unsigned-normalized-integer format with 8-bit channels. D3D counterpart: DXGI_...
Definition: GraphicsTypes.h:542
Fence description.
Definition: Fence.h:43
void CreateDeviceObject(const Char *ObjectTypeName, const ObjectDescType &Desc, ObjectType **ppObject, ObjectConstructorType ConstructObject)
Helper template function to facilitate device object creation.
Definition: RenderDeviceBase.hpp:414
struct RasterizerStateDesc RasterizerStateDesc
Definition: RasterizerState.h:184
Texture inteface.
Definition: Texture.h:273
void HashCombine(std::size_t &Seed, const T &Val)
Definition: HashUtils.hpp:44
@ TEX_FORMAT_BC2_UNORM_SRGB
Four-component signed-normalized-integer block-compression sRGB format with 5 bits for R,...
Definition: GraphicsTypes.h:682
RefCntWeakPtr< IDeviceContext > m_wpImmediateContext
Weak reference to the immediate context. Immediate context holds strong reference to the device,...
Definition: RenderDeviceBase.hpp:621
FixedBlockMemoryAllocator m_SamplerObjAllocator
Allocator for sampler objects.
Definition: RenderDeviceBase.hpp:632
StateObjectsRegistry< SamplerDesc > & GetSamplerRegistry()
Definition: RenderDeviceBase.hpp:371
Depth stencil state description.
Definition: DepthStencilState.h:157
#define NEW_RC_OBJ(Allocator, Desc, Type,...)
Definition: RefCountedObjectImpl.hpp:698
Render pass interface.
Definition: RenderPass.h:369
ShaderDesc Desc
Shader description. See Diligent::ShaderDesc.
Definition: Shader.h:316
Base implementation of a render device.
Definition: RenderDeviceBase.hpp:185
Blend state description.
Definition: BlendState.h:374
The library uses Direct3D-style math:
Definition: AdvancedMath.hpp:37
@ TEX_FORMAT_BC5_UNORM
Two-component unsigned-normalized-integer block-compression format with 8 bits for R and 8 bits for G...
Definition: GraphicsTypes.h:751
virtual const DeviceCaps & GetDeviceCaps() const override final
Implementation of IRenderDevice::GetDeviceCaps().
Definition: RenderDeviceBase.hpp:331
Resouce mapping.
Definition: ResourceMapping.h:107
size_t operator()(const Diligent::SamplerDesc &SamDesc) const
Definition: RenderDeviceBase.hpp:53