32 lines
587 B
Markdown
32 lines
587 B
Markdown
|
|
# D3D12CommandList::SetIndexBufferInternal
|
||
|
|
|
||
|
|
设置索引缓冲区内部实现。
|
||
|
|
|
||
|
|
```cpp
|
||
|
|
void SetIndexBufferInternal(ID3D12Resource* buffer, uint64_t offset, Format indexFormat);
|
||
|
|
```
|
||
|
|
|
||
|
|
## 参数
|
||
|
|
|
||
|
|
- `buffer` - D3D12 资源指针
|
||
|
|
- `offset` - 缓冲区偏移
|
||
|
|
- `indexFormat` - 索引格式
|
||
|
|
|
||
|
|
## 返回值
|
||
|
|
|
||
|
|
无
|
||
|
|
|
||
|
|
**线程安全:** ❌
|
||
|
|
|
||
|
|
**复杂度:** O(1)
|
||
|
|
|
||
|
|
## 示例
|
||
|
|
|
||
|
|
```cpp
|
||
|
|
commandList.SetIndexBufferInternal(indexBuffer.GetResource(), 0, Format::R16_UINT);
|
||
|
|
```
|
||
|
|
|
||
|
|
## 相关文档
|
||
|
|
|
||
|
|
- [D3D12CommandList 总览](command-list.md)
|
||
|
|
- [SetIndexBuffer](set-index-buffer.md) - 设置索引缓冲区
|