descriptions/ScanIO.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 #ifndef LVR2_IO_HDF5_SCANIO_HPP
4 #define LVR2_IO_HDF5_SCANIO_HPP
5 
6 #include "ArrayIO.hpp"
7 #include "MatrixIO.hpp"
9 
10 #include <sstream>
11 #include <yaml-cpp/yaml.h>
12 namespace lvr2
13 {
14 
15 
16 template <typename FeatureBase>
17 class ScanIO
18 {
19  public:
20  // void save(const std::string& group, const std::string& container, const std::string& metaFile, const ScanPtr& scan);
21  void saveScan(const size_t& scanPosNo, const size_t& scanNo, const ScanPtr& buffer);
22 
23  ScanPtr loadScan(const size_t& scanPosNo, const size_t& scanNo);
24  //ScanPtr load(const std::string& group, const std::string& container);
25 
26  protected:
27  bool isScan(const std::string& group);
28 
29  FeatureBase* m_featureBase = static_cast<FeatureBase*>(this);
30 
31  // dependencies
34 
35  static constexpr const char* ID = "ScanIO";
36  static constexpr const char* OBJID = "Scan";
37 };
38 
46 template <typename FeatureBase>
48 {
49 
50  // DEPS
53  using deps = typename dep1::template Merge<dep2>;
54 
55  // ADD THE FEATURE ITSELF
56  using type = typename deps::template add_features<ScanIO>::type;
57 };
58 
59 } // namespace lvr2
60 
61 #include "ScanIO.tcc"
62 
63 #endif // LVR2_IO_HDF5_SCANIO_HPP
Manager Class for all FeatureBase components located in hdf5 directory.
Definition: FeatureBase.hpp:31
Helper class how to construct a IO feature with its dependencies.
Definition: FeatureBase.hpp:20
static constexpr const char * ID
typename deps::template add_features< ScanIO >::type type
std::shared_ptr< Scan > ScanPtr
Shared pointer to scans.
Definition: ScanTypes.hpp:98
typename Derived::template add_features< Feature >::type type
ArrayIO< FeatureBase > * m_arrayIO
MatrixIO< FeatureBase > * m_matrixIO
static constexpr const char * OBJID
typename dep1::template Merge< dep2 > deps
FeatureBase * m_featureBase
void saveScan(const size_t &scanPosNo, const size_t &scanNo, const ScanPtr &buffer)
ScanPtr loadScan(const size_t &scanPosNo, const size_t &scanNo)
bool isScan(const std::string &group)
typename FeatureConstruct< ArrayIO, FeatureBase >::type dep1
typename FeatureConstruct< MatrixIO, FeatureBase >::type dep2


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:09