Reduced debug message level, and added a notify message for when an image isn't loaded

This commit is contained in:
Robert Osfield
2013-08-22 10:05:29 +00:00
parent fcde15e136
commit 464628b5c4
2 changed files with 12 additions and 4 deletions

View File

@@ -482,12 +482,12 @@ public:
{
if ((_objectsHandled[la]++)==0)
{
OSG_NOTICE<<"LayerAttributeOperator for "<<la<<" required, assigning one."<<std::endl;
OSG_INFO<<"LayerAttributeOperator for "<<la<<" required, assigning one."<<std::endl;
_operatorList.insert(new LayerAttributesOperator(&node, la));
}
else
{
OSG_NOTICE<<"LayerAttributeOperator for "<<la<<" not required, as one already assigned."<<std::endl;
OSG_INFO<<"LayerAttributeOperator for "<<la<<" not required, as one already assigned."<<std::endl;
}
}

View File

@@ -538,7 +538,7 @@ void SlideShowConstructor::addToCurrentLayer(osg::Node* subgraph)
{
if (_layerToApplyEventCallbackTo==0 || _currentLayer==_layerToApplyEventCallbackTo)
{
OSG_NOTICE<<"Assigning event callbacks."<<std::endl;
OSG_INFO<<"Assigning event callbacks."<<std::endl;
for(EventHandlerList::iterator itr = _currentEventCallbacksToApply.begin();
itr != _currentEventCallbacksToApply.end();
@@ -1004,7 +1004,11 @@ osg::Image* SlideShowConstructor::readImage(const std::string& filename, const I
filenames.push_back(foundFile);
}
if (filenames.empty()) return 0;
if (filenames.empty())
{
OSG_NOTICE<<"Could not fine image file: "<<filename<<std::endl;
return 0;
}
if (filenames.size()==1)
{
@@ -1106,6 +1110,10 @@ osg::Image* SlideShowConstructor::readImage(const std::string& filename, const I
if (imageData.startTime>0.0) image->setUserValue("start",imageData.startTime);
if (imageData.stopTime>0.0) image->setUserValue("stop",imageData.stopTime);
}
else
{
OSG_NOTICE<<"Could not load image file: "<<filename<<std::endl;
}
return image.release();
}