Files
XCEngine/docs/api/rhi/texture/get-depth.md

26 lines
372 B
Markdown
Raw Normal View History

# RHITexture::GetDepth
```cpp
virtual uint32_t GetDepth() const = 0;
```
获取纹理深度3D 纹理)。
2026-03-20 02:35:45 +08:00
**参数:** 无
**返回:** 纹理深度。对于 1D/2D 纹理返回 1
**线程安全:** ✅
**复杂度:** O(1)
2026-03-20 02:35:45 +08:00
**示例:**
```cpp
uint32_t depth = texture->GetDepth();
```
## 相关文档
- [RHITexture 总览](texture.md) - 返回类总览