generateMeta.cpp
Go to the documentation of this file.
00001 
00033 #include <iostream>
00034 #include <opencv/cv.h>
00035 #include <opencv/highgui.h>
00036 #include <string>
00037 #include <sstream>
00038 #include <vector>
00039 #include <iomanip>
00040 
00041 #include "DUtils.h"
00042 #include "DUtilsCV.h"
00043 #include "DVision.h"
00044 
00045 #include "../MetaFile.h"
00046 
00047 using namespace std;
00048 
00049 // ---------------------------------------------------------------------------
00050 
00051 int main(int argc, char *argv[])
00052 {
00053   if(argc < 5)
00054   {
00055     cout << "Usage: " << argv[0] << " <meta.xml file> <object name> "
00056       "<number of faces> <scale factor>" << endl;
00057     return 1;
00058   }
00059   
00060   string out_file = argv[1];
00061   string object_name = argv[2];
00062   int nfaces = atoi(argv[3]);
00063   float scale_factor = atof(argv[4]);
00064 
00065   MetaFile::MetaData data;
00066   
00067   data.Name = object_name;
00068   data.NFaces = nfaces;
00069   data.Type = "3D";
00070   data.Dimensions.Volume.Scale = scale_factor;
00071   
00072   MetaFile::saveFile(out_file, data);
00073 
00074   return 0;
00075 }
00076 
00077 // ---------------------------------------------------------------------------
00078 


re_vision
Author(s): Dorian Galvez-Lopez
autogenerated on Sun Jan 5 2014 11:31:15