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/command-writer.h | |
| 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/command-writer.h')
| -rw-r--r-- | tools/gfx/command-writer.h | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/tools/gfx/command-writer.h b/tools/gfx/command-writer.h index 04be1be86..208cb185a 100644 --- a/tools/gfx/command-writer.h +++ b/tools/gfx/command-writer.h @@ -195,11 +195,11 @@ public: } void 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) { uint32_t bufferOffset = 0; for (UInt i = 0; i < slotCount; i++) @@ -208,12 +208,12 @@ public: if (i == 0) bufferOffset = offset; } - uint32_t stridesOffset = encodeData(strides, sizeof(UInt) * slotCount); - uint32_t offsetsOffset = encodeData(offsets, sizeof(UInt) * slotCount); + uint32_t stridesOffset = encodeData(strides, sizeof(uint32_t) * slotCount); + uint32_t offsetsOffset = encodeData(offsets, sizeof(uint32_t) * slotCount); m_commands.add(Command( CommandName::SetVertexBuffers, - (uint32_t)startSlot, - (uint32_t)slotCount, + startSlot, + slotCount, bufferOffset, stridesOffset, offsetsOffset)); |
