Added guard to texture image to avoid seg fault when dealing with incomplete databases.
This commit is contained in:
parent
6904696573
commit
451a27ac65
@ -231,7 +231,7 @@ public:
|
|||||||
for (unsigned int im=0;im<texture->getNumImages();++im)
|
for (unsigned int im=0;im<texture->getNumImages();++im)
|
||||||
{
|
{
|
||||||
osg::Image* image = texture->getImage(im);
|
osg::Image* image = texture->getImage(im);
|
||||||
if (image->isImageTranslucent()) hasTranslucentTexture = true;
|
if (image && image->isImageTranslucent()) hasTranslucentTexture = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user