-
Notifications
You must be signed in to change notification settings - Fork 262
Description
I tried combining the shadow map demo and the ImGui demo, but only either one of them works. For example, If I remove the shadow-related code, ImGui works correctly.
The way I combined them was fairly simple: I created a game state that holds two GameState instances simultaneously and simply forwards the relevant member calls to both. The ImguiGameState directly inherits GameState instead of TutorialGameState.
For setupCompositor, I tried a few approaches:
-
Creating the shadow map workspace first, then adding the ImGui workspace afterward, as well as testing the reverse order.
-
Creating a combined workspace, although I couldn’t figure out how that is supposed to work.
CombinedWorkspace
{
connect_output StaticShadowMapsRenderingNode ImguiRenderingNode
connect_output ImguiRenderingNode 0
}
In some cases, the application runs without errors, but either the demo UI or the shadows are not rendered. I also tried removing the debug overlay from the ShadowMapFromCode game state, but this only removed the debug text and still did not display the ImGui demo window.