From ac58762e22fcb9954ca0f70618b530f76605268f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alejandro=20Hern=C3=A1ndez=20Cordero?= Date: Fri, 1 Oct 2021 00:32:25 +0200 Subject: [PATCH] Added winID to fix second windows in OGRE2.2 (#292) Signed-off-by: ahcorde --- src/plugins/minimal_scene/MinimalScene.cc | 3 +++ src/plugins/scene3d/Scene3D.cc | 4 ++++ 2 files changed, 7 insertions(+) diff --git a/src/plugins/minimal_scene/MinimalScene.cc b/src/plugins/minimal_scene/MinimalScene.cc index d62295d0e..c125d6733 100644 --- a/src/plugins/minimal_scene/MinimalScene.cc +++ b/src/plugins/minimal_scene/MinimalScene.cc @@ -466,6 +466,9 @@ void IgnRenderer::Initialize() std::map params; params["useCurrentGLContext"] = "1"; + params["winID"] = std::to_string( + ignition::gui::App()->findChild()-> + QuickWindow()->winId()); auto engine = rendering::engine(this->engineName, params); if (!engine) { diff --git a/src/plugins/scene3d/Scene3D.cc b/src/plugins/scene3d/Scene3D.cc index 61c4e962d..d601b8d72 100644 --- a/src/plugins/scene3d/Scene3D.cc +++ b/src/plugins/scene3d/Scene3D.cc @@ -1116,6 +1116,10 @@ void IgnRenderer::Initialize() std::map params; params["useCurrentGLContext"] = "1"; + params["winID"] = std::to_string( + ignition::gui::App()->findChild()-> + QuickWindow()->winId()); + auto engine = rendering::engine(this->engineName, params); if (!engine) {