Files
XCEngine/docs/api/rhi/opengl/depth-stencil-view/clear-stencil.md
2026-03-20 02:35:45 +08:00

23 lines
399 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.
# OpenGLDepthStencilView::ClearStencil
```cpp
void ClearStencil(uint8_t stencil)
```
清除模板缓冲区的模板值为指定值。此操作会先绑定帧缓冲,然后执行清除。
**参数:**
- `stencil` - 模板值0-255
**返回值:** `void`
**示例:**
```cpp
dsv.ClearStencil(0);
```
## 相关文档
- [OpenGLDepthStencilView](depth-stencil-view.md) - 返回类总览