MCPcopy Create free account
hub / github.com/NVIDIAGameWorks/Falcor / renderOptions

Method renderOptions

Source/Falcor/Utils/Timing/ProfilerUI.cpp:254–291  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

252}
253
254void ProfilerUI::renderOptions()
255{
256 bool paused = mpProfiler->isPaused();
257 if (ImGui::Checkbox("Pause", &paused))
258 mpProfiler->setPaused(paused);
259
260 ImGui::SameLine();
261 ImGui::Checkbox("Average", &mEnableAverage);
262
263 ImGui::SameLine();
264 ImGui::SetNextItemWidth(100.f);
265 if (ImGui::Combo("Graph", reinterpret_cast<int*>(&mGraphMode), kGraphModes, (int)GraphMode::Count))
266 clearGraphData();
267
268 if (mpProfiler->isCapturing())
269 {
270 ImGui::SameLine();
271 if (ImGui::Button("End Capture"))
272 {
273 auto pCapture = mpProfiler->endCapture();
274 FALCOR_ASSERT(pCapture);
275 FileDialogFilterVec filters{{"json", "JSON"}};
276 std::filesystem::path path;
277 if (saveFileDialog(filters, path))
278 {
279 pCapture->writeToFile(path);
280 }
281 }
282 }
283 else
284 {
285 ImGui::SameLine();
286 if (ImGui::Button("Start Capture"))
287 mpProfiler->startCapture();
288 }
289
290 ImGui::Separator();
291}
292
293void ProfilerUI::renderGraph(const ImVec2& size, size_t highlightIndex, size_t& newHighlightIndex)
294{

Callers

nothing calls this directly

Calls 7

CheckboxClass · 0.85
ButtonClass · 0.85
isCapturingMethod · 0.80
endCaptureMethod · 0.80
writeToFileMethod · 0.80
startCaptureMethod · 0.80
saveFileDialogFunction · 0.50

Tested by

no test coverage detected