[vtkusers] File Type Verification in Batch (Weird Problem)
    matheus_viana 
    vianamp at gmail.com
       
    Mon Oct 29 21:22:16 EDT 2012
    
    
  
Hi Guys!
I wanna check the file format of a set of .vtk files. They can be either
StructuredPoints or PolyData files.
So, I wrote this simple code:
for (i = 0; i < 200; i++) {
	vtkSmartPointer<vtkDataReader> Reader =
vtkSmartPointer<vtkDataReader>::New();
	Reader -> SetFileName(filename[i].c_str());
	Reader -> OpenVTKFile();
	if (Reader->IsFileStructuredPoints()) {
		TYPE[i] = 0;
	} else {
		TYPE[i] = 1;
	}
	Reader -> CloseVTKFile();
}
The program always crashes when i = 46. No problems with the file names.
Do you guys have any idea?
Thanks in advance,
Matheus
--
View this message in context: http://vtk.1045678.n5.nabble.com/File-Type-Verification-in-Batch-Weird-Problem-tp5716901.html
Sent from the VTK - Users mailing list archive at Nabble.com.
    
    
More information about the vtkusers
mailing list