[vtk-developers] Strange memory leaks with vtkImageReslice
Mathieu Coursolle
mcoursolle at rogue-research.com
Fri Apr 13 12:49:54 EDT 2007
Hi,
I am currently using vtkImageReslice class and am experiencing
some strange memory leaks.
If I execute this code, I have leaks only is I call SetInformationInput,
otherwise everything is fine. I looked in vtkImageReslice from what I
understood that image data is only use to read some parameters.
Does anyone understand what is happening here?
Thanks!
Here is my code:
int main(int argc, char *argv[])
{
vtkImageData* image = vtkImageData::New();
vtkImageReslice* slicer = vtkImageReslice::New();
slicer->SetInput(image);
slicer->SetInformationInput(image); <<< This line causes the leak!!!
image->Delete();
slicer->Delete();
return 0;
}
This is the console output if the SetInformationInput call is done:
vtkDebugLeaks has detected LEAKS!
Class "vtkCellData" has 1 instance still around.
Class "vtkInformationVector" has 3 instances still around.
Class "vtkPointData" has 1 instance still around.
Class "vtkTrivialProducer" has 1 instance still around.
Class "vtkPoints" has 8 instances still around.
Class "vtkInformation" has 4 instances still around.
Class "vtkLine" has 4 instances still around.
Class "vtkInformationIntegerPointerValue" has 1 instance still around.
Class "vtkPixel" has 2 instances still around.
Class "vtkIdList" has 8 instances still around.
Class "vtkDoubleArray" has 8 instances still around.
Class "vtkAlgorithmOutput" has 1 instance still around.
Class "vtkInformationIntegerValue" has 1 instance still around.
Class "vtkVertex" has 1 instance still around.
Class "vtkImageData" has 1 instance still around.
Class "vtkInformationExecutivePortVectorValue" has 1 instance still around.
Class "vtkVoxel" has 1 instance still around.
Class "vtkFieldData" has 1 instance still around.
Class "vtkStreamingDemandDrivenPipeline" has 1 instance still around.
Class "vtkInformationExecutivePortValue" has 1 instance still around.
Thanks a lot!
Mathieu
--
____________________________________________________________
Mathieu Coursolle mcoursolle at rogue-research.com
Rogue Research www.rogue-research.com
Montréal, Québec, Canada
More information about the vtk-developers
mailing list