]> Creatis software - creaImageIO.git/commitdiff
boxes to read vector of itkImage
authorFrederic Cervenansky <Frederic.Cervenansky@creatis.insa-lyon.fr>
Wed, 25 May 2011 12:52:49 +0000 (12:52 +0000)
committerFrederic Cervenansky <Frederic.Cervenansky@creatis.insa-lyon.fr>
Wed, 25 May 2011 12:52:49 +0000 (12:52 +0000)
bbtk/src/bbcreaImageIOItkImagesChooserDialogBox.cxx

index c035509b94a39bde08d4761e8a8035a2d602d9fc..2d466515a29406b57e089245a5ca17b0a44b414e 100644 (file)
@@ -18,8 +18,7 @@ void ItkImagesChooserDialogBox::Process()
  
        dlg = new creaImageIO::WxAnySimpleDlg(0,crea::std2wx(bbGetInputTitle()),"localdatabase_Descriptor.dscp","Local Database"); 
     dlg->ShowModal(); 
-       
-       // FCY to test
+
        bbtk::TypeInfo typ = bbitk::GetITKImagePtrTypeInfoFromPixelTypeInfoAndDimension(*dlg->getTypes().front(), dlg->getDims().front());
        BBTK_TEMPLATE_ITK_IMAGE_SWITCH(typ, Export);
        bbSetOutputOutVImages(dlg->getVtkImagesSelected());
@@ -34,7 +33,14 @@ void ItkImagesChooserDialogBox::Export()
         } 
          else if (dlg->getImagesSelected().size() > 1)
          { 
-//             bbSetOutputOutImages( bbSetOutputOutIImages( dlg->getTemplatedImagesSelected<TImage>() )); 
+                 OutputImagesITKType temp;
+                 //std::vector<TImage*> temp;
+                 std::vector<TImage::Pointer>::iterator it = dlg->getTemplatedImagesSelected<TImage>().begin();
+                 for(;it != dlg->getTemplatedImagesSelected<TImage>().end(); ++it)
+                 {
+                         temp.push_back( (*it).GetPointer() );
+                 }
+               bbSetOutputOutIImages( temp); 
       } 
          else
          {