docs: rebuild Debug API content
This commit is contained in:
@@ -1,30 +1,42 @@
|
||||
# Profiler::EndFrame
|
||||
|
||||
公开方法,详见头文件声明。
|
||||
结束当前帧的 profiling 周期。
|
||||
|
||||
```cpp
|
||||
void EndFrame();
|
||||
```
|
||||
|
||||
该方法声明于 `XCEngine/Debug/Profiler.h`,当前页面用于固定 `Profiler` 类目录下的方法级 canonical 路径。
|
||||
## 行为说明
|
||||
|
||||
**参数:** 无。
|
||||
当前实现会直接清空内部 `m_samples` 数组,而不会导出、返回或持久化这些样本。
|
||||
|
||||
**返回:** `void` - 无返回值。
|
||||
这意味着当前版本里:
|
||||
|
||||
**示例:**
|
||||
- `BeginProfile` / `EndProfile` 采集到的数据是短暂的。
|
||||
- 如果你在同一帧内没有其它方式读取样本,调用 `EndFrame` 后这些数据就会被丢弃。
|
||||
|
||||
## 参数
|
||||
|
||||
- 无。
|
||||
|
||||
## 返回值
|
||||
|
||||
- 无。
|
||||
|
||||
## 线程语义
|
||||
|
||||
- 无同步保护;建议与 [BeginFrame](BeginFrame.md) 在同一线程调用。
|
||||
|
||||
## 示例
|
||||
|
||||
```cpp
|
||||
#include <XCEngine/Debug/Profiler.h>
|
||||
|
||||
void Example() {
|
||||
XCEngine::Debug::Profiler object;
|
||||
// 根据上下文补齐参数后调用 Profiler::EndFrame(...)。
|
||||
(void)object;
|
||||
}
|
||||
auto& profiler = XCEngine::Debug::Profiler::Get();
|
||||
profiler.BeginFrame();
|
||||
// ...
|
||||
profiler.EndFrame();
|
||||
```
|
||||
|
||||
## 相关文档
|
||||
|
||||
- [返回类总览](Profiler.md)
|
||||
- [返回模块目录](../Debug.md)
|
||||
- [返回类型总览](Profiler.md)
|
||||
- [BeginFrame](BeginFrame.md)
|
||||
|
||||
Reference in New Issue
Block a user