[vtkusers] Deleting ImageData Inside Loop
David Doria
daviddoria at gmail.com
Mon Jun 18 17:48:13 EDT 2012
On Mon, Jun 18, 2012 at 5:44 PM, Jochen K. <jochen.kling at email.de> wrote:
> Hi Matheus,
>
> I don't know a reason for the crash but I can show you how to use
> vtkSmartPointer:
>
> #include "vtkSmartPointer.h"
>
> ...
> instead of calling
>
> vtkStructuredPointsReader *Reader = vtkStructuredPointsReader::New();
>
> you should call
>
> vtkSmartPointer<vtkStructuredPointsReader> Reader = vtkSmartPointer<vtkStructuredPointsReader>::New();
>
> ...
> You don't have to take care for freeing up memory anymore.
>
> best regards
> Jochen
Wow guys, this is a pretty impressive immediate response system we've got
going here! 3 replies within 15 minutes - must be some kind of record!
David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20120618/d0095c07/attachment.htm>
More information about the vtkusers
mailing list