[Paraview] Catalyst : crash using vtkSmartPointers

Andy Bauer andy.bauer at kitware.com
Sun Aug 4 15:59:08 EDT 2013


Hi,

I didn't have any problems using a vtkSmartPointer for vtkCPProcessor. I'd
have to see your full code to know for sure but my guess is that
_spProcessor is a pointer to a vtkCPProcessor and not a
vtkSmartPointer<vtkCPProcessor>. When I make that mistake I get a crash.

Regards,
Andy

On Sat, Aug 3, 2013 at 4:41 AM, HOUSSEN Franck <Franck.Houssen at cea.fr>wrote:

>  Hello,
>
> I try to understand if (and how) I can use Catalyst for my need (in-situ
> visualisation). I started with :
> http://paraview.org/Wiki/ParaView/Catalyst/Overview
>
> To code the adaptor, you need to handle VTK objects. When using VTK, I
> generally prefer to use smart pointers (avoid looking for leaks).
> Here is my code (this is the only call / use of VTK object in the all code)
> paraviewAdaptor::paraviewAdaptor ()
> {
>   _spProcessor = vtkSmartPointer<vtkCPProcessor>::New ();
> //  _spProcessor -> Initialize (); // Crash if uncommented ?!
> }
> Compilation is OK, but at run time I get a crash with this error message :
> *** The MPI_Comm_free() function was called after MPI_FINALIZE was invoked.
> *** This is disallowed by the MPI standard.
>
> So I tried to use pointers instead of smartpointers :
> paraviewAdaptor::paraviewAdaptor ()
> {
>   _pProcessor = vtkCPProcessor::New ();
>   _pProcessor -> Initialize (); // Don't crash ?!
> }
> And I don't get any crash anymore ?!....
>
> Why is that ? How can I use vtkSmartPointers ?
>
> Note : I use ParaView-v4.0.1-source.tgz and I run on Ubuntu 12.04
>
> Thanks,
>
> FH
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the ParaView Wiki at:
> http://paraview.org/Wiki/ParaView
>
> Follow this link to subscribe/unsubscribe:
> http://www.paraview.org/mailman/listinfo/paraview
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20130804/75d2dd72/attachment.htm>


More information about the ParaView mailing list