[vtkusers] About reading ply

hbfyf hbfyf at qq.com
Fri Apr 8 21:15:13 EDT 2011


I have succeed in reading ply file.But when the ply file is very big such as 2M,it can't work and when I run the program,it says that can't allocate some elements of size.Can you help me?
  
 Here is the reading code:
  
  if(argc != 2)
    {
    std::cout << "Usage: " << argv[0] << "  Filename(.ply)" << std::endl;
    return EXIT_FAILURE;
    }
 
  std::string inputFilename = argv[1];
 
  vtkSmartPointer<vtkPLYReader> reader =
    vtkSmartPointer<vtkPLYReader>::New();
  reader->SetFileName ( inputFilename.c_str() );
  
  vtkSmartPointer<vtkPolyDataMapper> mapper =
    vtkSmartPointer<vtkPolyDataMapper>::New();
  mapper->SetInputConnection(reader->GetOutputPort());
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20110409/a64e143a/attachment.htm>


More information about the vtkusers mailing list