Files
XCEngine/docs/api/d3d12/d3d12-buffer-initialize.md
ssdfasd 7c3f304688 refactor(docs): D3D12模块文档重构 - 修复链接错误并新增Buffer/Texture/SwapChain方法文档
- 新增32个方法文档(D3D12Buffer 13个,D3D12Texture 12个,D3D12SwapChain 6个)
- 修复11处跨模块引用错误(rhi-device.md, rhi-texture.md等路径错误)
- 清理d3d12-overview.md移除不存在的类引用
- 修复D3D12Device/D3D12CommandList/D3D12CommandQueue方法列表
- D3D12模块现无broken links
2026-03-26 01:49:24 +08:00

20 lines
612 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# D3D12Buffer::Initialize
初始化 D3D12Buffer 缓冲区资源。
```cpp
bool Initialize(ID3D12Device* device, uint64_t size, D3D12_RESOURCE_STATES initialState = D3D12_RESOURCE_STATE_COMMON, D3D12_HEAP_TYPE heapType = D3D12_HEAP_TYPE_DEFAULT);
```
**参数:**
- `device` - DirectX 12 设备指针
- `size` - 缓冲区大小(字节)
- `initialState` - 初始资源状态,默认为 Common 状态
- `heapType` - 堆类型默认为默认堆D3D12_HEAP_TYPE_DEFAULT
**返回:** `bool` - 初始化成功返回 true失败返回 false
## 相关文档
- [D3D12Buffer 总览](d3d12-buffer.md)