[vtkusers] usage of vtkCompositePolyDataMapper
Jean M. Favre
jfavre at cscs.ch
Wed Aug 26 05:37:53 EDT 2009
Alex Malyushytskyy wrote:
> // geometry filter
> vtkSmartPointer<vtkCompositeDataGeometryFilter> geom =
> vtkSmartPointer<vtkCompositeDataGeometryFilter>::New();
> geom->SetInput( compositeDataSet );
>
> // mapper
> compositePolyDatamapperMapper =
> vtkSmartPointer<vtkCompositePolyDataMapper>::New();
> compositePolyDatamapperMapper->SetInputConnection(0,
> geom->GetOutputPort( 0 ) ); // This works
> // compositePolyDatamapperMapper->SetInputConnection(0,
> compositeDataSet->GetProducerPort() ); // this does not work
I have working code which uses a vtkCompositeDataGeometryFilter, but
simply a vtkPolyDataMapper, like this:
VTK_CREATE(vtkCompositeDataGeometryFilter, geom1);
geom1->SetInputConnection(0, eb1->GetOutputPort(0));
geom1->Update();
VTK_CREATE(vtkPolyDataMapper, mapper1);
mapper1->SetInputConnection(geom1->GetOutputPort(0));
VTK_CREATE(vtkActor, actor1);
actor1->SetMapper(mapper1);
More information about the vtkusers
mailing list