]> Creatis software - gdcm.git/commitdiff
*ENH: Can be used like this '$vtkgdcmViewer *.dcm' with *.dcm being coherents dicom...
authormalaterre <malaterre>
Thu, 30 Oct 2003 11:12:22 +0000 (11:12 +0000)
committermalaterre <malaterre>
Thu, 30 Oct 2003 11:12:22 +0000 (11:12 +0000)
vtk/vtkgdcmViewer.cxx

index 66062c5844c931e1fca994cd7d16a6a2725c6113..97f305cec343c08b892460214ca0898efa9fd1a1 100644 (file)
@@ -39,9 +39,17 @@ class vtkgdcmObserver : public vtkCommand
 
 int main(int argc, char *argv[])
 {
-
+  if( argc < 2 )
+    return 0;
+  
   vtkGdcmReader *reader = vtkGdcmReader::New();
-  reader->SetFileName( argv[1] );
+
+  if( argc == 2 )
+    reader->SetFileName( argv[1] );
+  else
+    for(int i=1; i< argc; i++)
+      reader->AddFileName( argv[i] );
+
   reader->DebugOn();
   reader->Update();