SyB3R - Synthetic Benchmark for 3D Reconstruction
Dataset.h
1 #ifndef DATASET_H
2 #define DATASET_H
3 
4 #include <Eigen/Dense>
5 #include <vector>
6 #include <tinyxml2.h>
7 #include <iostream>
8 #include <fstream>
9 
10 #include <OpenEXR/ImfInputFile.h>
11 #include <OpenEXR/ImfArray.h>
12 #include <OpenEXR/ImathBox.h>
13 
14 
15 #include <boost/optional.hpp>
16 #include <boost/filesystem.hpp>
17 
18 
19 #include "Camera.h"
20 #include "Image.h"
21 
22 namespace syb3r {
23 namespace data {
24 
25 class Dataset
26 {
27  public:
28  void loadFromXML(const boost::filesystem::path &xmlFilename);
29 
30  void calcPointCloudFromDepth(std::vector<Eigen::Vector3f>& pc, std::vector<unsigned>& mask, unsigned subsamplingStride) const;
31 
32  inline const std::vector<Image> &getImages() const { return m_images; }
33  inline const boost::optional<float> &getUnitsToMeters() const { return m_unitsToMeters; }
34 
35  void addImage(Image image) { m_images.push_back(std::move(image)); }
36  protected:
37  boost::optional<float> m_unitsToMeters;
38 
39  std::vector<Image> m_images;
40 };
41 
42 }
43 }
44 
45 #endif // DATASET_H
Definition: CameraPathEvaluation.cpp:10
Definition: Image.h:21
Definition: Dataset.h:25