diff options
| author | Yong He <yonghe@outlook.com> | 2021-12-13 09:57:56 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-12-13 09:57:56 -0800 |
| commit | 3359313620cd57b8404f95cfe7b07cce514eff71 (patch) | |
| tree | 8f7edee5b23ca0345ce7ac62b54a9726c84752bf /tools/gfx/debug-layer.cpp | |
| parent | c1064a263350ee6042625bf368a97f7fe94dcd39 (diff) | |
gfx: use uint32_t in draw calls and implement current size query. (#2055)
* gfx: Implement remaining resource commands on D3D12.
Includes: `textureBarrier`, `copyTexture`, `uploadTextureData`, `copyTextureToBuffer`, and `textureSubresourceBarrier`.
* gfx: Implement `CurrentSize` query.
Co-authored-by: Yong He <yhe@nvidia.com>
Diffstat (limited to 'tools/gfx/debug-layer.cpp')
| -rw-r--r-- | tools/gfx/debug-layer.cpp | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/tools/gfx/debug-layer.cpp b/tools/gfx/debug-layer.cpp index d96af7069..fa7064b89 100644 --- a/tools/gfx/debug-layer.cpp +++ b/tools/gfx/debug-layer.cpp @@ -1084,11 +1084,11 @@ void DebugRenderCommandEncoder::setPrimitiveTopology(PrimitiveTopology topology) } void DebugRenderCommandEncoder::setVertexBuffers( - UInt startSlot, - UInt slotCount, + uint32_t startSlot, + uint32_t slotCount, IBufferResource* const* buffers, - const UInt* strides, - const UInt* offsets) + const uint32_t* strides, + const uint32_t* offsets) { SLANG_GFX_API_FUNC; @@ -1101,22 +1101,21 @@ void DebugRenderCommandEncoder::setVertexBuffers( } void DebugRenderCommandEncoder::setIndexBuffer( - IBufferResource* buffer, - Format indexFormat, - UInt offset) + IBufferResource* buffer, Format indexFormat, uint32_t offset) { SLANG_GFX_API_FUNC; auto innerBuffer = static_cast<DebugBufferResource*>(buffer)->baseObject.get(); baseObject->setIndexBuffer(innerBuffer, indexFormat, offset); } -void DebugRenderCommandEncoder::draw(UInt vertexCount, UInt startVertex) +void DebugRenderCommandEncoder::draw(uint32_t vertexCount, uint32_t startVertex) { SLANG_GFX_API_FUNC; baseObject->draw(vertexCount, startVertex); } -void DebugRenderCommandEncoder::drawIndexed(UInt indexCount, UInt startIndex, UInt baseVertex) +void DebugRenderCommandEncoder::drawIndexed( + uint32_t indexCount, uint32_t startIndex, uint32_t baseVertex) { SLANG_GFX_API_FUNC; baseObject->drawIndexed(indexCount, startIndex, baseVertex); @@ -1166,7 +1165,10 @@ Result DebugRenderCommandEncoder::setSamplePositions( } void DebugRenderCommandEncoder::drawInstanced( - UInt vertexCount, UInt instanceCount, UInt startVertex, UInt startInstanceLocation) + uint32_t vertexCount, + uint32_t instanceCount, + uint32_t startVertex, + uint32_t startInstanceLocation) { SLANG_GFX_API_FUNC; return baseObject->drawInstanced( |
