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; };