[vtkusers] Problem to read the DICOM series using VTK

chenjianyyzz chenjianyyzz at 163.com
Sun Jan 22 01:53:43 EST 2017


Hello David, 

thank you very much for your reply, yes, the image result you attached is
right.
but in my code, I fail to  GetNumberOfSeries,  it return 0, below is my
code:
===================================
	vtkSmartPointer<vtkStringArray> filenames =
vtkSmartPointer<vtkStringArray>::New();        
	filenames->InsertNextValue("C:\temp\Data_Fail_to_Read_A\\1-286.dcm");
	filenames->InsertNextValue("C:\temp\Data_Fail_to_Read_A\\1-287.dcm");
	filenames->InsertNextValue("C:\temp\Data_Fail_to_Read_A\\1-288.dcm");
	filenames->InsertNextValue("C:\temp\Data_Fail_to_Read_A\\1-289.dcm");
	filenames->InsertNextValue("C:\temp\Data_Fail_to_Read_A\\1-290.dcm");
	filenames->InsertNextValue("C:\temp\Data_Fail_to_Read_A\\1-291.dcm");
	filenames->InsertNextValue("C:\temp\Data_Fail_to_Read_A\\1-292.dcm");
	vtkSmartPointer <vtkDICOMFileSorter> sorter = vtkSmartPointer
<vtkDICOMFileSorter>::New();
	sorter->SetInputFileNames(filenames);
	sorter->Update();
	*int ns = sorter->GetNumberOfSeries();*    // here ns returns 0, which
should not be.
===================================

and I don't know why sorter->GetNumberOfSeries() returns 0?

Best Regards
James



--
View this message in context: http://vtk.1045678.n5.nabble.com/Problem-to-read-the-DICOM-series-using-VTK-tp5741842p5741911.html
Sent from the VTK - Users mailing list archive at Nabble.com.


More information about the vtkusers mailing list