From f3698c9127d6e384eabe779b8fb3519c94e0babb Mon Sep 17 00:00:00 2001 From: Egor Yusov Date: Wed, 24 Apr 2019 22:17:09 -0700 Subject: Added IShaderResourceVariable::IsBound method (updated API version to 240024) --- Graphics/GraphicsEngine/interface/APIInfo.h | 2 +- Graphics/GraphicsEngine/interface/ShaderResourceVariable.h | 12 +++++++++--- 2 files changed, 10 insertions(+), 4 deletions(-) (limited to 'Graphics/GraphicsEngine') diff --git a/Graphics/GraphicsEngine/interface/APIInfo.h b/Graphics/GraphicsEngine/interface/APIInfo.h index f1c89e58..fd6ef747 100644 --- a/Graphics/GraphicsEngine/interface/APIInfo.h +++ b/Graphics/GraphicsEngine/interface/APIInfo.h @@ -26,7 +26,7 @@ /// \file /// Diligent API information -#define DILIGENT_API_VERSION 240023 +#define DILIGENT_API_VERSION 240024 #include "../../../Primitives/interface/BasicTypes.h" diff --git a/Graphics/GraphicsEngine/interface/ShaderResourceVariable.h b/Graphics/GraphicsEngine/interface/ShaderResourceVariable.h index 1bf9fdfd..477c7380 100644 --- a/Graphics/GraphicsEngine/interface/ShaderResourceVariable.h +++ b/Graphics/GraphicsEngine/interface/ShaderResourceVariable.h @@ -120,13 +120,19 @@ public: virtual void SetArray(IDeviceObject* const* ppObjects, Uint32 FirstElement, Uint32 NumElements) = 0; /// Returns the shader resource variable type - virtual SHADER_RESOURCE_VARIABLE_TYPE GetType()const = 0; + virtual SHADER_RESOURCE_VARIABLE_TYPE GetType() const = 0; /// Returns shader resource description. See Diligent::ShaderResourceDesc. - virtual ShaderResourceDesc GetResourceDesc()const = 0; + virtual ShaderResourceDesc GetResourceDesc() const = 0; /// Returns the variable index that can be used to access the variable. - virtual Uint32 GetIndex()const = 0; + virtual Uint32 GetIndex() const = 0; + + /// Returns true if non-null resource is bound to this variable. + + /// \param [in] ArrayIndex - Resource array index. Must be 0 for + /// non-array variables. + virtual bool IsBound(Uint32 ArrayIndex) const = 0; }; } -- cgit v1.2.3