[vtkusers] two question, please advice
Ali Habib
ali.mahmoud.habib at gmail.com
Mon Oct 19 07:51:54 EDT 2009
Dear All ,
1. How to convert vtkvolume and vtkimagedata to vtkpolydata
2.while running the following code , a warning appear :
Generic Warning: In m:\dev\cur\vtkdotnet\branch\50\Common\vtkMath.cxx, line
394
Unable to factor linear system:
vtkSphereSource ^sphere = gcnew vtkSphereSource();
sphere->SetRadius(1.0);
sphere->SetThetaResolution(18);
sphere->SetPhiResolution(18);
vtkStripper ^v = gcnew vtkStripper();
v->SetInputConnection(sphere->GetOutputPort());
v->Update();
vtkDelaunay3D ^v3 = gcnew vtkDelaunay3D();
v3->SetInputConnection(v->GetOutputPort());
v3->Update()
vtkDataSetMapper ^mapper = gcnew vtkDataSetMapper();
mapper->SetInputConnection(v3->GetOutputPort());
vtkActor ^triangulation = gcnew vtkActor();
triangulation->SetMapper(mapper);
triangulation->GetProperty()->SetRepresentationToWireframe();
// Create the standard rendering stuff.
vtkRenderer ^ren1 = gcnew vtkRenderer();
vtkRenderWindow ^renWin = gcnew vtkRenderWindow();
renWin->AddRenderer(ren1);
vtkRenderWindowInteractor ^iren = gcnew vtkRenderWindowInteractor();
iren->SetRenderWindow(renWin);
// Add the actors to the renderer, set the background and size
//
ren1->AddActor(triangulation);
ren1->SetBackground(1, 1, 1);
renWin->SetSize(300, 300);
renWin->Render();
renWin->Render();
iren->Initialize();
iren->Start();
any advice please
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20091019/bd76fccf/attachment.htm>
More information about the vtkusers
mailing list