Function holoscan::viz::ImGuiSetCurrentContext
Defined in File holoviz.hpp
-
void holoscan::viz::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/DLLboundaries. Therefore the app needs to create the ImGui context first and then provides the pointer to Holoviz like this:
ImGui::CreateContext(); holoscan::viz::ImGuiSetCurrentContext(ImGui::GetCurrentContext());
- Parameters
context – ImGui context