fix: improve doc link navigation and tree display

- Fix link resolution with proper relative/absolute path handling
- Improve link styling with underline decoration
- Hide leaf nodes from tree, only show directories
- Fix log file path for packaged app
This commit is contained in:
2026-03-19 12:44:08 +08:00
parent e003fe6513
commit 58a83f445a
1012 changed files with 56880 additions and 22 deletions

View File

@@ -0,0 +1,45 @@
# Profiler::ExportChromeTracing
```cpp
void ExportChromeTracing(const Containers::String& filePath)
```
**状态:** 此方法目前为空实现,暂未功能。
将收集的性能数据导出为 Chrome Tracing JSON 格式。导出的文件可通过 Chrome 浏览器打开(地址栏输入 `chrome://tracing` 并加载文件)进行可视化分析。
**参数:**
- `filePath` - 输出文件路径
**复杂度:** O(n)n 为记录的样本数量
**示例:**
```cpp
#include <XCEngine/Debug/Profiler.h>
XCEngine::Debug::Profiler::Get().Initialize();
void RenderFrame() {
XCEngine::Debug::Profiler::Get().BeginFrame();
XE_PROFILE_FUNCTION();
XE_PROFILE_BEGIN("UpdateScene");
UpdateScene();
XE_PROFILE_END();
XE_PROFILE_BEGIN("DrawScene");
DrawScene();
XE_PROFILE_END();
XCEngine::Debug::Profiler::Get().EndFrame();
}
// 运行一段时间后导出
XCEngine::Debug::Profiler::Get().ExportChromeTracing("trace.json");
XCEngine::Debug::Profiler::Get().Shutdown();
```
## 相关文档
- [Profiler 总览](profiler.md) - 返回类总览