33 lines
698 B
Markdown
33 lines
698 B
Markdown
|
|
# Profiler::SetMarker
|
||
|
|
|
||
|
|
设置相关状态或配置。
|
||
|
|
|
||
|
|
```cpp
|
||
|
|
void SetMarker(const char* name, uint32_t color);
|
||
|
|
```
|
||
|
|
|
||
|
|
该方法声明于 `XCEngine/Debug/Profiler.h`,当前页面用于固定 `Profiler` 类目录下的方法级 canonical 路径。
|
||
|
|
|
||
|
|
**参数:**
|
||
|
|
- `name` - 参数语义详见头文件声明。
|
||
|
|
- `color` - 参数语义详见头文件声明。
|
||
|
|
|
||
|
|
**返回:** `void` - 无返回值。
|
||
|
|
|
||
|
|
**示例:**
|
||
|
|
|
||
|
|
```cpp
|
||
|
|
#include <XCEngine/Debug/Profiler.h>
|
||
|
|
|
||
|
|
void Example() {
|
||
|
|
XCEngine::Debug::Profiler object;
|
||
|
|
// 根据上下文补齐参数后调用 Profiler::SetMarker(...)。
|
||
|
|
(void)object;
|
||
|
|
}
|
||
|
|
```
|
||
|
|
|
||
|
|
## 相关文档
|
||
|
|
|
||
|
|
- [返回类总览](Profiler.md)
|
||
|
|
- [返回模块目录](../Debug.md)
|