spc[2]=1;
}
//EED 2017-12-7
- if (imageoutput==NULL)
+ if (imageoutput!=NULL)
{
- imageoutput = vtkImageData::New();
- }
+ imageoutput->Delete();
+ }
+ imageoutput = vtkImageData::New();
imageoutput->Initialize();
imageoutput->SetScalarType( outputformat );
imageoutput->SetSpacing( spc );