<DIV>I want to display a point clouds and write the following codes:</DIV>
<DIV> vtkPoints * points = vtkPoints::New();<BR> float x,y,z;<BR> while( !feof(file) )<BR> {<BR> fscanf(file,"%f\t%f\t%f\n",&x, &y, &z);<BR> points->InsertNextPoint(x,y,z);<BR> }<BR> fclose(file);</DIV>
<DIV> vtkPolyData * polydata = vtkPolyData::New();<BR> polydata->SetPoints(points);<BR> <BR> vtkPolyDataMapper *mapper = vtkPolyDataMapper::New();<BR> mapper->SetInput(polydata);<BR> vtkActor *actor = vtkActor::New();<BR> actor->SetMapper(mapper);</DIV>
<DIV> this->Props->AddItem(actor);</DIV>
<DIV> </DIV>
<DIV>But there is nothing in the window. Who can tell I why I cannot get the result.</DIV>
<DIV> </DIV>
<DIV>Thanks</DIV><p>__________________________________________________<br>赶快注册雅虎超大容量免费邮箱?<br>http://cn.mail.yahoo.com