struct mp2p_icp_filters::KeyframePlace

Overview

The place of one keyframe, as stored in its metadata under KEYFRAME_PLACE_KEY: {id: 3, flags: [unpartitioned, closed], params_hash: 123}, without flags if there are none.

#include <simplemap_partition.h>

struct KeyframePlace
{
    // fields

    uint32_t id = 0;
    uint32_t flags = 0;
    uint32_t params_hash = 0;

    // methods

    mrpt::containers::yaml to_yaml() const;
    static std::optional<KeyframePlace> FromMetadata(const mrpt::containers::yaml& metadata);
    static std::optional<KeyframePlace> FromKeyframe(const mrpt::obs::CSensoryFrame& sf);
};

Fields

uint32_t id = 0

Place id: unique within the map, not necessarily consecutive.

uint32_t flags = 0

SimplemapPartition::SubmapFlag bits.

uint32_t params_hash = 0

partition_params_hash() of the partition that made it (0: unknown)

Methods

static std::optional<KeyframePlace> FromMetadata(const mrpt::containers::yaml& metadata)

From keyframe metadata (its KEYFRAME_PLACE_KEY entry): std::nullopt if it has none or it is malformed. Unknown flags are ignored.

static std::optional<KeyframePlace> FromKeyframe(const mrpt::obs::CSensoryFrame& sf)

The place stored in the metadata of a keyframe, if any.