]> Creatis software - creaImageIO.git/blobdiff - src/creaImageIOGimmickView.cpp
#3264 creaImageIO Feature New Normal - Add Dicom Tags to the DB sqlite
[creaImageIO.git] / src / creaImageIOGimmickView.cpp
index 9b4169f571d09d296304fee2f6833fa7e7b2ddff..2ff7855fdb30222137cfbde27148fe8bba39f624 100644 (file)
@@ -124,7 +124,6 @@ namespace creaImageIO
   /// Destructor
   GimmickView::~GimmickView()
   {
-         printf("EED GimmickView::~GimmickView  DESTROCTEUR \n");
     GimmickDebugMessage(1,"GimmickView::~GimmickView"
                        <<std::endl);
   }
@@ -465,8 +464,10 @@ void GimmickView::ReadImagesNotThreaded(std::vector<vtkImageData*>& s, std::vect
        //////////////////////////////////////////////////////////
        bool GimmickView::isSingle(const std::string i_file)
        {
+printf("EED GimmickView::isSingle Start %s\n" , i_file.c_str() );
                bool bres = true;
                vtkImageData* first = mReader.GetImage( i_file);
+printf("EED GimmickView::isSingle 1\n"  );
                int dim[3];
                first->GetDimensions(dim);
                if (dim[2] > 1)
@@ -476,6 +477,8 @@ void GimmickView::ReadImagesNotThreaded(std::vector<vtkImageData*>& s, std::vect
                else
                {
                }
+printf("EED GimmickView::isSingle end\n");
+
                return bres;
        }
 
@@ -529,7 +532,7 @@ void GimmickView::ReadImagesNotThreaded(std::vector<vtkImageData*>& s, std::vect
                         OutputAttr i_attr, double i_zspc)
        {
                OutStrGimmick out;
-               vtkImageData* first = mReader.GetImage( im.front());
+               vtkImageData* first = mReader.GetImage( im.front() );
                out.img  = vtkImageData::New();
                int ext[6];
 //EED 2017-01-01 Migration VTK7
@@ -564,7 +567,6 @@ void GimmickView::ReadImagesNotThreaded(std::vector<vtkImageData*>& s, std::vect
                out.img->AllocateScalars(first->GetScalarType(), first->GetNumberOfScalarComponents());
 #endif
 
-
                unsigned long imsize = dim[0] * dim[1];
                imsize = imsize * dim[2] ;  // deal with multiframes here
                // differents formats char , short, etc...
@@ -574,12 +576,13 @@ void GimmickView::ReadImagesNotThreaded(std::vector<vtkImageData*>& s, std::vect
                //!!!!out.img->SetSpacing(i_zspc);
                int slice = 0;
                std::vector<std::string>::iterator it;
+               
                for (it=im.begin(); it!=im.end(); ++it) 
                {
                        vtkImageData* cur = mReader.GetImage( (*it) );
                        memcpy(out.img->GetScalarPointer(0,0,slice), cur->GetScalarPointer(0,0,0), imsize);
                        slice++;
-               }       
+               } // for it     
                
                getAttributes(im.front(),out.infos, i_attr);
                o_output.push_back(out);
@@ -768,7 +771,6 @@ void GimmickView::ReadImagesNotThreaded(std::vector<vtkImageData*>& s, std::vect
 
 //EED UnMosaic step...  
 //How to verifie if is a mosaic file , with how many images inside??
-
        }