*/
#include "creaVtkUnMosaicVectorVtkImageData.h"
+
+#define _USE_MATH_DEFINES // for C
#include <math.h>
+
creaVtkUnMosaicVectorVtkImageData::creaVtkUnMosaicVectorVtkImageData()
{
}
{
std::vector<int> nbImagesPerRow;
std::vector<int> nbImagesInMosaic;
+ double imagesInMosaic;
- for(int i = 0; i < NbImagesInMosaicVector.size(); i++){
- nbImagesPerRow.push_back( ceil(sqrt(NbImagesInMosaicVector[i])) );
+ for(int i = 0; i < NbImagesInMosaicVector.size(); i++)
+ {
+ imagesInMosaic = NbImagesInMosaicVector[i];
+ nbImagesPerRow.push_back( ceil(sqrt(imagesInMosaic)) );
nbImagesInMosaic.push_back(NbImagesInMosaicVector[i]);
}
- if(imageInput.size() != NbImagesInMosaicVector.size()){
- for(int j = NbImagesInMosaicVector.size(); j < imageInput.size(); j++) {
- nbImagesPerRow.push_back( ceil(sqrt(NbImagesInMosaicVector[NbImagesInMosaicVector.size()-1])) );
+ if(imageInput.size() != NbImagesInMosaicVector.size())
+ {
+ for(int j = NbImagesInMosaicVector.size(); j < imageInput.size(); j++)
+ {
+ imagesInMosaic = NbImagesInMosaicVector[NbImagesInMosaicVector.size()-1];
+ nbImagesPerRow.push_back( ceil(sqrt(imagesInMosaic)) );
nbImagesInMosaic.push_back( NbImagesInMosaicVector[NbImagesInMosaicVector.size()-1] );
}
}