[Paraview] Glyph Trouble
Brian C. Panneton (CONTR)
brian.c.panneton.ctr at us.army.mil
Fri May 20 12:13:38 EDT 2011
I'm trying to put a glyph on every point for a filter. Currently it
apply only one glyph containing all of the points. Am I doing something
wrong here?
[code]
vtkSmartPointer<vtkPolyData> pd =
vtkSmartPointer<vtkPolyData>::New();
vtkSmartPointer<vtkPoints> points2 =
vtkSmartPointer<vtkPoints>::New();
points2->InsertNextPoint(0,0,1);
points2->InsertNextPoint(1,1,1);
points2->InsertNextPoint(2,2,1);
points2->InsertNextPoint(100,2,1);
pd->SetPoints(points2);
vtkSmartPointer<vtkCubeSource> cubeSource =
vtkSmartPointer<vtkCubeSource>::New();
vtkSmartPointer<vtkGlyph3D> glyph3D =
vtkSmartPointer<vtkGlyph3D>::New();
glyph3D->SetSource(cubeSource->GetOutput());
glyph3D->SetInput(pd);
glyph3D->Update();
this->data->SetBlock(1, glyph3D->GetOutput());
output->DeepCopy(this->data);
[/code]
Thanks,
Brian Panneton
More information about the ParaView
mailing list