Function clara::holoviz::ImGuiSetCurrentContext

void clara::holoviz::ImGuiSetCurrentContext(ImGuiContext *context)

If using ImGui, create a context and pass it to Holoviz, do this before calling viz::Init().

Background: The ImGui context is a global variable and global variables are not shared across so/DLL boundaries. Therefore the app needs to create the ImGui context first and then provides the pointer to Holoviz like this:


ImGui::CreateContext(); clara::holoviz::ImGuiSetCurrentContext(ImGui::GetCurrentContext());


context – ImGui context

© Copyright 2022, NVIDIA. Last updated on Jun 28, 2023.