Commit 43264b22 by schurade

[CHANGE] roi spheres don't add themself to the graphics engine on creation anymore

parent 3964da04
......@@ -61,9 +61,6 @@ WROISphere::WROISphere( wmath::WPosition position, float radius ) :
m_isModified = true;
m_isNot = false;
assert( WGraphicsEngine::getGraphicsEngine() );
WGraphicsEngine::getGraphicsEngine()->getScene()->addChild( this );
setUserData( this );
setUpdateCallback( osg::ref_ptr<ROISphereNodeCallback>( new ROISphereNodeCallback ) );
}
......
......@@ -234,6 +234,10 @@ void WMArbitraryPlane::initPlane()
m_s2 = boost::shared_ptr<WROISphere>( new WROISphere( m_p2, 2.5 ) );
m_s2->setLockX();
WGraphicsEngine::getGraphicsEngine()->getScene()->addChild( &( *m_s0 ) );
WGraphicsEngine::getGraphicsEngine()->getScene()->addChild( &( *m_s1 ) );
WGraphicsEngine::getGraphicsEngine()->getScene()->addChild( &( *m_s2 ) );
m_s0->getSignalIsModified()->connect( boost::bind( &WMArbitraryPlane::setDirty, this ) );
m_s1->getSignalIsModified()->connect( boost::bind( &WMArbitraryPlane::setDirty, this ) );
m_s2->getSignalIsModified()->connect( boost::bind( &WMArbitraryPlane::setDirty, this ) );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment