From fc1f2446278516e7936663c470addf5c5abd076c Mon Sep 17 00:00:00 2001 From: Andrei Kortunov Date: Fri, 23 Feb 2024 17:01:59 +0400 Subject: [PATCH] Add missing initialization --- components/debug/debugdraw.cpp | 2 -- components/debug/debugdraw.hpp | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/components/debug/debugdraw.cpp b/components/debug/debugdraw.cpp index e7aa7d8cce..2bc7358259 100644 --- a/components/debug/debugdraw.cpp +++ b/components/debug/debugdraw.cpp @@ -316,8 +316,6 @@ Debug::DebugDrawer::DebugDrawer(const DebugDrawer& copy, const osg::CopyOp& copy Debug::DebugDrawer::DebugDrawer(Shader::ShaderManager& shaderManager) { - mCurrentFrame = 0; - auto program = shaderManager.getProgram("debug"); setCullingActive(false); diff --git a/components/debug/debugdraw.hpp b/components/debug/debugdraw.hpp index 2518813cad..eb4219e06b 100644 --- a/components/debug/debugdraw.hpp +++ b/components/debug/debugdraw.hpp @@ -101,7 +101,7 @@ namespace Debug void addLine(const osg::Vec3& start, const osg::Vec3& end, const osg::Vec3 color = colorWhite); private: - unsigned int mCurrentFrame; + unsigned int mCurrentFrame = 0; std::array, 2> mCustomDebugDrawer; };