[vtkusers] Freeing up memory
Dominik Szczerba
domi at vision.ee.ethz.ch
Sat Aug 4 17:04:35 EDT 2007
I don't know why but why don't you use vtkSmartPointer's.
- Dominik
rashed karim wrote:
> Hi VTK users,
>
> Inside a function I do this:
> vtkRendererCollection* rendererCollection = renderWin->GetRenderers();
>
> Where I am basically getting the renderers associated with a rendering
> window. Further down in the code I extract the renderer from the collection
> and delete any existing actors in the renderer and replace it with a new
> actor.
>
> When exiting the function, I start freeing up the memory by invoking on
> Delete( ) on the renderer, actor, etc. But here is where it gets all wierd -
> when I delete the rendererCollection object, I can no longer interact with
> my actor. Does anyone know why?
>
> Thanks
> Rashed Karim.
>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> This is the private VTK discussion list.
> Please keep messages on-topic. Check the FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
--
Dominik Szczerba, Ph.D.
Computer Vision Lab CH-8092 Zurich
http://www.vision.ee.ethz.ch/~domi
More information about the vtkusers
mailing list