Commit 4ac1e161 authored by David E. DeMarle's avatar David E. DeMarle

protect against no input to prevent crash

comes up in paraview server side rendering in which the client
side has no input
parent 0414e8b3
Pipeline #24650 passed with stage
......@@ -68,7 +68,7 @@ void vtkOSPRayVolumeMapperNode::Render(bool prepass)
vtkAbstractVolumeMapper* mapper = vtkAbstractVolumeMapper::SafeDownCast(this->GetRenderable());
if (!vol->GetProperty())
{
vtkErrorMacro("VolumeMapper had no vtkProperty");
// this is OK, happens in paraview client side for instance
return;
}
......
......@@ -69,7 +69,11 @@ unsigned long vtkOSPRayVolumeNode::GetMTime()
if (mapper)
{
mtime = std::max(mtime, mapper->GetDataSetInput()->GetMTime());
vtkDataObject *dobj = mapper->GetDataSetInput();
if (dobj)
{
mtime = std::max(mtime, dobj->GetMTime());
}
if (mapper->GetMTime() > mtime)
{
mtime = mapper->GetMTime();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment