From 324dc573a094f83d4447d0700aacc425eb99f9db Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Wed, 10 Dec 2014 11:30:02 +0000 Subject: [PATCH] From Farshid Lashkari, "The Collada loader would crash while processing textures on certain files. I've attached the fix." git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.2@14596 16af8721-9629-0410-8352-f15c8da7e697 --- src/osgPlugins/dae/daeRMaterials.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/osgPlugins/dae/daeRMaterials.cpp b/src/osgPlugins/dae/daeRMaterials.cpp index 02c920537..6c2887f3d 100644 --- a/src/osgPlugins/dae/daeRMaterials.cpp +++ b/src/osgPlugins/dae/daeRMaterials.cpp @@ -1047,7 +1047,7 @@ osg::Texture2D* daeReader::processTexture( return NULL; } - if (sampler->getSource() == NULL ) + if (sampler->getSource() == NULL || sampler->getSource()->getValue() == NULL) { OSG_WARN << "Could not locate source for sampler2D" << std::endl; return NULL;