summaryrefslogtreecommitdiffstats
path: root/tools/gfx/renderer-shared.h
diff options
context:
space:
mode:
authorlucy96chen <47800040+lucy96chen@users.noreply.github.com>2022-03-08 12:47:32 -0800
committerGitHub <noreply@github.com>2022-03-08 15:47:32 -0500
commit771f29435d664f7344bc5596056146af5d64d352 (patch)
tree035fba1641088d75381e9a7140dab2d6f21223f9 /tools/gfx/renderer-shared.h
parent2a80bcfa96089967b299eea0454d9debe52fa0f6 (diff)
Expose API-specific row alignment values (#2151)
* Added function to IDevice that retrieves the row alignment for the particular API; Added rowDstStride argument to copyTextureToBuffer and changed D3D12 footprint row pitch to check that the user-supplied stride is correctly aligned before assigning to the footprint's row pitch * Changed alignment from Uint to size_t Co-authored-by: jsmall-nvidia <jsmall@nvidia.com>
Diffstat (limited to 'tools/gfx/renderer-shared.h')
-rw-r--r--tools/gfx/renderer-shared.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/tools/gfx/renderer-shared.h b/tools/gfx/renderer-shared.h
index 0462b802b..1814f97d9 100644
--- a/tools/gfx/renderer-shared.h
+++ b/tools/gfx/renderer-shared.h
@@ -1284,6 +1284,9 @@ public:
virtual SLANG_NO_THROW Result SLANG_MCALL getTextureAllocationInfo(
const ITextureResource::Desc& desc, size_t* outSize, size_t* outAlignment) override;
+ // Provides a default implementation that returns SLANG_E_NOT_AVAILABLE.
+ virtual SLANG_NO_THROW Result SLANG_MCALL getTextureRowAlignment(size_t* outAlignment) override;
+
Result getShaderObjectLayout(
slang::TypeReflection* type,
ShaderObjectContainerType container,