Added handling of null dynamic_cast
This commit is contained in:
@@ -889,6 +889,12 @@ FltExportVisitor::writeUVList( int numVerts, const osg::Geometry& geom, unsigned
|
|||||||
void
|
void
|
||||||
FltExportVisitor::handleDrawArrays( const osg::DrawArrays* da, const osg::Geometry& geom, const osg::Geode& geode )
|
FltExportVisitor::handleDrawArrays( const osg::DrawArrays* da, const osg::Geometry& geom, const osg::Geode& geode )
|
||||||
{
|
{
|
||||||
|
if (!da)
|
||||||
|
{
|
||||||
|
OSG_WARN<<"fltexp: Invalid DrawArray pointer"<<std::endl;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
GLint first = da->getFirst();
|
GLint first = da->getFirst();
|
||||||
GLsizei count = da->getCount();
|
GLsizei count = da->getCount();
|
||||||
GLenum mode = da->getMode();
|
GLenum mode = da->getMode();
|
||||||
@@ -956,6 +962,12 @@ FltExportVisitor::handleDrawArrays( const osg::DrawArrays* da, const osg::Geomet
|
|||||||
void
|
void
|
||||||
FltExportVisitor::handleDrawArrayLengths( const osg::DrawArrayLengths* dal, const osg::Geometry& geom, const osg::Geode& geode )
|
FltExportVisitor::handleDrawArrayLengths( const osg::DrawArrayLengths* dal, const osg::Geometry& geom, const osg::Geode& geode )
|
||||||
{
|
{
|
||||||
|
if (!da;)
|
||||||
|
{
|
||||||
|
OSG_WARN<<"fltexp: Invalid DrawArrayLengths pointer"<<std::endl;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
GLint first = dal->getFirst();
|
GLint first = dal->getFirst();
|
||||||
GLenum mode = dal->getMode();
|
GLenum mode = dal->getMode();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user