OpenSceneGraph/src/osg/Object.cpp

20 lines
505 B
C++
Raw Normal View History

#include <osg/Object>
#include <osg/Notify>
#include <typeinfo>
2001-01-11 00:32:10 +08:00
using namespace osg;
Referenced::~Referenced()
{
if (_refCount>0)
{
notify(WARN)<<"Warning: deleting still referenced object "<<this<<" of type '"<<typeid(this).name()<<"'"<<std::endl;
notify(WARN)<<" the final reference count was "<<_refCount<<", memory corruption possible."<<std::endl;
}
}
Object::Object(const Object& obj,const CopyOp&):
Referenced(),
_dataVariance(obj._dataVariance) {}