1 #ifndef FILE_KERNEL_HPP 2 #define FILE_KERNEL_HPP 7 #include <boost/optional.hpp> 8 #include <yaml-cpp/yaml.h> 10 #include <opencv2/opencv.hpp> 11 #include <opencv2/core.hpp> 28 const std::string& group,
29 const std::string& container,
33 const std::string& group,
34 const std::string& container,
38 const std::string& group,
39 const std::string& container,
40 const cv::Mat& image)
const = 0;
43 const std::string& group,
44 const std::string& metaName,
45 const YAML::Node& node)
const = 0;
48 const std::string& group,
49 const std::string container)
const = 0;
52 const std::string& group,
53 const std::string& container)
const = 0;
55 virtual boost::optional<cv::Mat>
loadImage(
56 const std::string& group,
57 const std::string& container)
const = 0;
63 const std::string& group,
64 const std::string& container,
65 YAML::Node& node)
const = 0;
68 const std::string& group,
69 const std::string& constainer,
70 std::vector<size_t>& dims)
const = 0;
73 const std::string& group,
74 const std::string& constainer,
75 std::vector<size_t>& dims)
const = 0;
78 const std::string& group,
79 const std::string& constainer,
80 std::vector<size_t>& dims)
const = 0;
83 const std::string& groupName,
84 const std::string& datasetName,
85 const std::vector<size_t>& dimensions,
86 const boost::shared_array<float>& data)
const = 0;
89 const std::string& groupName,
90 const std::string& datasetName,
91 const std::vector<size_t>& dimensions,
92 const boost::shared_array<double>& data)
const = 0;
95 const std::string& groupName,
96 const std::string& datasetName,
97 const std::vector<size_t>& dimensions,
98 const boost::shared_array<unsigned char>& data)
const = 0;
100 virtual bool exists(
const std::string& group)
const = 0;
101 virtual bool exists(
const std::string& group,
const std::string& container)
const = 0;
104 virtual void subGroupNames(
const std::string& group,
const std::regex&
filter, std::vector<string>& subGroupNames)
const = 0;
virtual bool exists(const std::string &group) const =0
virtual void saveMetaYAML(const std::string &group, const std::string &metaName, const YAML::Node &node) const =0
virtual void saveDoubleArray(const std::string &groupName, const std::string &datasetName, const std::vector< size_t > &dimensions, const boost::shared_array< double > &data) const =0
std::shared_ptr< MeshBuffer > MeshBufferPtr
virtual boost::optional< cv::Mat > loadImage(const std::string &group, const std::string &container) const =0
boost::shared_array< double > doubleArr
boost::shared_array< unsigned char > ucharArr
virtual void saveUCharArray(const std::string &groupName, const std::string &datasetName, const std::vector< size_t > &dimensions, const boost::shared_array< unsigned char > &data) const =0
virtual floatArr loadFloatArray(const std::string &group, const std::string &constainer, std::vector< size_t > &dims) const =0
virtual MeshBufferPtr loadMeshBuffer(const std::string &group, const std::string container) const =0
virtual void savePointBuffer(const std::string &group, const std::string &container, const PointBufferPtr &buffer) const =0
std::shared_ptr< PointBuffer > PointBufferPtr
virtual doubleArr loadDoubleArray(const std::string &group, const std::string &constainer, std::vector< size_t > &dims) const =0
virtual void saveImage(const std::string &group, const std::string &container, const cv::Mat &image) const =0
virtual ucharArr loadUCharArray(const std::string &group, const std::string &constainer, std::vector< size_t > &dims) const =0
boost::shared_array< float > floatArr
void filter(lvr2::PointBufferPtr &cloud, lvr2::indexArray &inlier, size_t j)
virtual void saveFloatArray(const std::string &groupName, const std::string &datasetName, const std::vector< size_t > &dimensions, const boost::shared_array< float > &data) const =0
virtual void subGroupNames(const std::string &group, std::vector< string > &subGroupNames) const =0
virtual void loadMetaYAML(const std::string &group, const std::string &container, YAML::Node &node) const =0
std::shared_ptr< FileKernel > FileKernelPtr
virtual PointBufferPtr loadPointBuffer(const std::string &group, const std::string &container) const =0
std::string m_fileResourceName
virtual void saveMeshBuffer(const std::string &group, const std::string &container, const MeshBufferPtr &buffer) const =0
FileKernel(const std::string &res)