Added if (image ..) check to prevent seg fault on imcomplete models
This commit is contained in:
@@ -231,7 +231,7 @@ public:
|
||||
for (unsigned int im=0;im<texture->getNumImages();++im)
|
||||
{
|
||||
osg::Image* image = texture->getImage(im);
|
||||
if (image->isImageTranslucent()) hasTranslucentTexture = true;
|
||||
if (image && image->isImageTranslucent()) hasTranslucentTexture = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user