8 #include <mrpt/io/CFileGZInputStream.h> 9 #include <mrpt/io/CFileGZOutputStream.h> 10 #include <mrpt/serialization/CArchive.h> 11 #include <mrpt/serialization/optional_serialization.h> 12 #include <mrpt/serialization/stl_serialization.h> 19 uint8_t LogRecord::serializeGetVersion()
const {
return 0; }
20 void LogRecord::serializeTo(mrpt::serialization::CArchive&
out)
const 24 out.WriteAs<
bool>(
true);
29 out.WriteAs<
bool>(
false);
33 out.WriteAs<
bool>(
true);
38 out.WriteAs<
bool>(
false);
45 void LogRecord::serializeFrom(
46 mrpt::serialization::CArchive& in, uint8_t version)
54 if (in.ReadAs<
bool>())
59 if (in.ReadAs<
bool>())
61 pcLocal = metric_map_t::Create();
70 MRPT_THROW_UNKNOWN_SERIALIZATION_VERSION(version);
76 auto f = mrpt::io::CFileGZOutputStream(fileName);
77 if (!
f.is_open())
return false;
79 auto arch = mrpt::serialization::archiveFrom(
f);
87 auto f = mrpt::io::CFileGZInputStream(fileName);
88 if (!
f.is_open())
return false;
90 auto arch = mrpt::serialization::archiveFrom(
f);
99 mrpt::serialization::CArchive& out)
const 103 out << optimalPose << pairings;
106 mrpt::serialization::CArchive& in)
108 const auto readVersion = in.ReadAs<uint8_t>();
109 ASSERT_EQUAL_(readVersion, DIPI_SERIALIZATION_VERSION);
113 mrpt::serialization::CArchive& out,
metric_map_t::ConstPtr pcGlobal
void serializeFrom(mrpt::serialization::CArchive &in)
Generic container of pointcloud(s), extracted features and other maps.
bool load_from_file(const std::string &fileName)
metric_map_t::ConstPtr pcLocal
void serializeTo(mrpt::serialization::CArchive &out) const
mp2p_icp::Results icpResult
bool save_to_file(const std::string &fileName) const
std::optional< IterationsDetails > iterationsDetails
static const uint8_t DIPI_SERIALIZATION_VERSION
mrpt::serialization::CArchive & operator>>(mrpt::serialization::CArchive &in, mp2p_icp::LogRecord::DebugInfoPerIteration &obj)
mrpt::serialization::CArchive & operator<<(mrpt::serialization::CArchive &out, const mp2p_icp::LogRecord::DebugInfoPerIteration &obj)
mp2p_icp::Parameters icpParameters
A record of the inputs and outputs of an ICP run.
IMPLEMENTS_MRPT_OBJECT(metric_map_t, mrpt::serialization::CSerializable, mp2p_icp) using namespace mp2p_icp
mrpt::math::TPose3D initialGuessLocalWrtGlobal