else
{
std::vector<std::string>::iterator it = i_attr.inside.begin();
- for(; it != i_attr.inside.end(); it++)
+ for(; it != i_attr.inside.end(); it++)
i_res[(*it)] = map_attr[(*it)];
}
}
-
-
}
// If we want only one output information structure, we set it outside the loop
if(!i_attr.mult)
{
- getAttributes(im.front(), o_output.front().infos,i_attr);
+ getAttributes(im.front(), o_output.front().infos, i_attr);
}
}
}
- //////////////////////////////////////////////////////////
+ //////////////////////////////////////////////////////////
// create an output structure with n entries (T size) = T + n output
//////////////////////////////////////////////////////////
void GimmickView::readImages4(std::vector<OutStrGimmick>& o_output, std::vector<std::string> im,
-
void GimmickView::ReadImagesNotThreadedInVector(std::vector<vtkImageData*>& s, std::vector<std::string> im, int dimension)
{
// Create the output data
// }
//}
//
-} // EO namespace creaImageIO
\ No newline at end of file
+} // EO namespace creaImageIO
{
bool bresult = true;
ImageReader *mReader = new ImageReader();
-
+ std::vector<std::string> names;
bresult = boost::filesystem::exists( i_pathname );
if (bresult)
{
{
if( mReader->CanRead(itr->string()) )
{
- std::cout << itr->filename().c_str() << std::endl;
- i_imgs.push_back( mReader->ReadImage(itr->string()) );
+ names.push_back(itr->string());
}
}
}
+ std::sort (names.begin(), names.end()); // make sure names are in lexicographical order
+ int lgr = names.size();
+
+ for(int i=0; i<lgr; i++)
+ {
+ i_imgs.push_back( mReader->ReadImage(names[i]) );
+ }
}
return bresult;
}