diff --git a/src/components/GuiDetectDevice.cpp b/src/components/GuiDetectDevice.cpp index 39ab9161f..f31beca8d 100644 --- a/src/components/GuiDetectDevice.cpp +++ b/src/components/GuiDetectDevice.cpp @@ -81,8 +81,11 @@ void GuiDetectDevice::update(int deltaTime) } } -void GuiDetectDevice::render() +void GuiDetectDevice::render(const Eigen::Affine3f& parentTrans) { + Eigen::Affine3f trans = parentTrans * getTransform(); + Renderer::setMatrix(trans); + std::shared_ptr font = Font::get(*mWindow->getResourceManager(), Font::getDefaultPath(), FONT_SIZE_MEDIUM); std::string playerString; diff --git a/src/components/GuiDetectDevice.h b/src/components/GuiDetectDevice.h index 9dee87b52..c8041ff4d 100644 --- a/src/components/GuiDetectDevice.h +++ b/src/components/GuiDetectDevice.h @@ -10,7 +10,7 @@ public: bool input(InputConfig* config, Input input); void update(int deltaTime); - void render(); + void render(const Eigen::Affine3f& parentTrans) override; private: void done(); diff --git a/src/components/GuiInputConfig.cpp b/src/components/GuiInputConfig.cpp index 88640f0b1..202238fbc 100644 --- a/src/components/GuiInputConfig.cpp +++ b/src/components/GuiInputConfig.cpp @@ -75,8 +75,11 @@ bool GuiInputConfig::input(InputConfig* config, Input input) return false; } -void GuiInputConfig::render() +void GuiInputConfig::render(const Eigen::Affine3f& parentTrans) { + Eigen::Affine3f trans = parentTrans * getTransform(); + Renderer::setMatrix(trans); + std::shared_ptr font = Font::get(*mWindow->getResourceManager(), Font::getDefaultPath(), FONT_SIZE_MEDIUM); std::stringstream stream; diff --git a/src/components/GuiInputConfig.h b/src/components/GuiInputConfig.h index 972b50c83..05c23c157 100644 --- a/src/components/GuiInputConfig.h +++ b/src/components/GuiInputConfig.h @@ -11,7 +11,7 @@ public: bool input(InputConfig* config, Input input); void update(int deltaTime); - void render(); + void render(const Eigen::Affine3f& parentTrans) override; private: std::string mErrorMsg;