src/tools/lvr2_hdf5_builder_2/Options.hpp
Go to the documentation of this file.
1 
28 /*
29  * Options.h
30  *
31  * Created on: Aug 23 2012
32  * Author: Thomas Wiemann
33  */
34 
35 #ifndef OPTIONS_H_
36 #define OPTIONS_H_
37 
38 #include <boost/program_options.hpp>
39 #include <iostream>
40 #include <string>
41 #include <vector>
42 
43 using std::cout;
44 using std::endl;
45 using std::ostream;
46 using std::string;
47 using std::vector;
48 
49 namespace hdf5tool2
50 {
51 
52 using namespace boost::program_options;
53 
58 class Options
59 {
60  public:
65  Options(int argc, char** argv);
66  virtual ~Options();
67 
68  string getInputDir() const { return m_variables["inputDir"].as<string>(); }
69  string getOutputDir() const { return m_variables["outputDir"].as<string>(); }
70  string getOutputFile() const { return m_variables["outputFile"].as<string>(); }
71  bool getPreview() const { return m_variables["createPreview"].as<bool>(); }
72  int getPreviewReductionRatio() const { return m_variables["previewReduction"].as<int>(); }
73  // int numPanoramaImages() const { return m_variables["nch"].as<int>();}
74  //
75  // size_t getHSPChunk0() const { return m_variables["hsp_chunk_0"].as<size_t>(); }
76  // size_t getHSPChunk1() const { return m_variables["hsp_chunk_1"].as<size_t>(); }
77  // size_t getHSPChunk2() const { return m_variables["hsp_chunk_2"].as<size_t>(); }
78  //
79  // bool addAnnotations() const { return (m_variables["addAnnotations"].as<int>() != 0);}
80 
81  private:
83  variables_map m_variables;
84 
86  options_description m_descr;
87 
89  positional_options_description m_pdescr;
90 };
91 
93 inline ostream& operator<<(ostream& os, const Options& o)
94 {
95  cout << "##### Program options: " << endl;
96  // cout << "##### Data directory \t\t: " << o.getDataDir() << endl;
97 
98  return os;
99 }
100 
101 } // namespace hdf5tool2
102 
103 #endif /* OPTIONS_H_ */
ostream & operator<<(ostream &os, const Options &o)
Overlaoeded outpur operator.
options_description m_descr
The internally used option description.
A class to parse the program options for the reconstruction executable.
positional_options_description m_pdescr
The internally used positional option desription.
variables_map m_variables
The internally used variable map.
char ** argv


lvr2
Author(s): Thomas Wiemann , Sebastian Pütz , Alexander Mock , Lars Kiesow , Lukas Kalbertodt , Tristan Igelbrink , Johan M. von Behren , Dominik Feldschnieders , Alexander Löhr
autogenerated on Mon Feb 28 2022 22:46:08