Selected USE_NEW_DELETE allocation mode to fix memory leak

This commit is contained in:
Robert Osfield 2020-07-09 10:14:02 +01:00
parent 46505f66d3
commit 47207248d4

View File

@ -267,8 +267,7 @@ class ReaderWriterJP2 : public osgDB::ReaderWriter
pixelFormat,
dataType,
data,
// osg::Image::USE_NEW_DELETE);
osg::Image::NO_DELETE);
osg::Image::USE_NEW_DELETE);
OSG_INFO << "image read ok "<<s<<" "<<t<< std::endl;
return image;
@ -334,8 +333,7 @@ class ReaderWriterJP2 : public osgDB::ReaderWriter
pixelFormat,
dataType,
data,
// osg::Image::USE_NEW_DELETE);
osg::Image::NO_DELETE);
osg::Image::USE_NEW_DELETE);
OSG_INFO << "image read ok "<<s<<" "<<t<< std::endl;
return image;