[vtkusers] vtkUnstructuredGrid problem in Linux
Mathieu Malaterre
Mathieu.Malaterre at creatis.insa-lyon.fr
Fri Nov 7 11:27:26 EST 2003
Todd Schneider wrote:
> Hi everyone, I recently switched from using VTK with .NET 2003 to using
> Linux with gcc 3.2.2. Now when I run this sample line of code that used
> to work fine in .NET, I get the error:
>
> no matching function for call to `vtkGeometryFilter::
> SetInput(vtkUnstructuredGrid*)'
> /vtkDataSetToPolyDataFilter.h:44: candidates are:
> virtual void vtkDataSetToPolyDataFilter::SetInput(vtkDataSet*)
>
> The code is
>
> vtkDelaunay3D *shell = vtkDelaunay3D::New();
> shell->SetInput(inputDataSet);
> shell->SetTolerance(2);
> shell->SetAlpha(alpha_input);
> shell->BoundingTriangulationOff();
>
> vtkGeometryFilter *extract_poly_data = vtkGeometryFilter::New();
> extract_poly_data->SetInput(shell->GetOutput());
>
> The output of shell is a vtkUnstructuredGrid, which IS a vtkDataSet, so
> I don't quite see how to fix this problem...any thoughts? Thanks for the
> help!
>
> Todd
Since VTK use forward includes you need to include explicitely
everythings you need. I guess all you need is:
#include <vtkUnstructuredGrid.h>
HTH
mathieu
More information about the vtkusers
mailing list