[Paraview] How can I tell that Allocate succeeded?

Burlen Loring burlen.loring at kitware.com
Mon Aug 25 10:08:55 EDT 2008


Hi John,

If the call to Allocate fails it will not return. If VTK/Paraview has 
been built in Release mode, then a "vtkstd::bad_alloc()" exception is 
thrown  when the Allocate call fails. Otherwise, if VTK/Paraview has 
been built in Debug mode, abort is called. This behavior comes from 
within VTK, and was implemented a couple months ago, so you may need to 
have the cvs version.

Burlen

John R. Cary wrote:
> For a paraview plugin:
>
> After
>
>  vtkUnstructuredGrid* ugridPtr = vtkUnstructuredGrid::New();
>  ...
>  ugridPtr->Allocate(ncells);
>
> is there a way to tell whether the allocation succeeded?
>
>
> Thx...John Cary
> _______________________________________________
> ParaView mailing list
> ParaView at paraview.org
> http://www.paraview.org/mailman/listinfo/paraview


-- 
Burlen Loring
Kitware, Inc.
R&D Engineer
28 Corporate Drive
Clifton Park, NY 12065-8662
Phone: 518-371-3971 x137



More information about the ParaView mailing list