summaryrefslogtreecommitdiff
path: root/tools/gfx/debug-layer.h
diff options
context:
space:
mode:
authorYong He <yonghe@outlook.com>2021-05-25 10:24:38 -0700
committerGitHub <noreply@github.com>2021-05-25 10:24:38 -0700
commitba24264275c640e0ac3732f0f5720e1f5816cded (patch)
tree9413b919498c700afe89d498ff3434eea9cf3c89 /tools/gfx/debug-layer.h
parentfbf00dd54d787c6e22b0f1785a64dfb2fb1e300a (diff)
Allow overriding specialization args via `IShaderObject`. (#1854)
* Allow overriding specialization args via `IShaderObject`. * Fixes. Co-authored-by: T. Foley <tfoleyNV@users.noreply.github.com>
Diffstat (limited to 'tools/gfx/debug-layer.h')
-rw-r--r--tools/gfx/debug-layer.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/tools/gfx/debug-layer.h b/tools/gfx/debug-layer.h
index a4e201e4f..f9ecc7dfe 100644
--- a/tools/gfx/debug-layer.h
+++ b/tools/gfx/debug-layer.h
@@ -167,6 +167,9 @@ public:
ShaderOffset const& offset,
IResourceView* textureView,
ISamplerState* sampler) override;
+ virtual SLANG_NO_THROW Result SLANG_MCALL setSpecializationArgs(
+ const slang::SpecializationArg* args,
+ uint32_t count) override;
public:
struct ShaderOffsetKey
@@ -188,6 +191,8 @@ public:
}
};
Slang::String m_typeName;
+ slang::TypeReflection* m_slangType = nullptr;
+ DebugDevice* m_device;
Slang::List<Slang::RefPtr<DebugShaderObject>> m_entryPoints;
Slang::Dictionary<ShaderOffsetKey, Slang::RefPtr<DebugShaderObject>> m_objects;
Slang::Dictionary<ShaderOffsetKey, Slang::RefPtr<DebugResourceView>> m_resources;
@@ -199,6 +204,8 @@ class DebugRootShaderObject : public DebugShaderObject
public:
virtual SLANG_NO_THROW uint32_t SLANG_MCALL addRef() override { return 1; }
virtual SLANG_NO_THROW uint32_t SLANG_MCALL release() override { return 1; }
+ virtual SLANG_NO_THROW Result SLANG_MCALL
+ setSpecializationArgs(const slang::SpecializationArg* args, uint32_t count) override;
};
class DebugCommandBuffer;