IDS peak ICV v1.2.0
Loading...
Searching...
No Matches
peak_icv_point_cloud_writer.hpp
Go to the documentation of this file.
1
11#pragma once
12
15
16#include <string>
17
18namespace peak
19{
20namespace icv
21{
22
23
32{
33public:
53 template <typename PointCloud>
54 void Write(const std::string& filePath, const PointCloud& cloud) const;
55};
56
57template <typename PointCloudType>
58void PointCloudWriter::Write(const std::string& filePath, const PointCloudType& cloud) const
59{
60 static_assert(detail::is_pointcloud_v<PointCloudType>, "Write must be called on PointCloud types!");
61
62 auto pointCloudHandle = peak::common::detail::BackendAccessor<PointCloudType>::BackendHandle(cloud);
64 return PEAK_ICV_C_ABI_PREFIX peak_icv_PointCloud_SaveToFile(pointCloudHandle, filePath.c_str(), {});
65 });
66}
67
68
69} /* namespace icv */
70} /* namespace peak */
Provides functionality to write point clouds to file.
void Write(const std::string &filePath, const PointCloud &cloud) const
Saves the specified point cloud to a PLY file.
void ExecuteAndMapReturnCodes(const CallableType &callableObject)