svo
Semi-Direct Visual Odometry
|
Map object which saves all keyframes which are in a map. More...
#include <map.h>
Public Member Functions | |
Map () | |
~Map () | |
void | reset () |
Reset the map. Delete all keyframes and reset the frame and point counters. | |
void | safeDeletePoint (Point *pt) |
Delete a point in the map and remove all references in keyframes to it. | |
void | deletePoint (Point *pt) |
Moves the point to the trash queue which is cleaned now and then. | |
bool | safeDeleteFrame (FramePtr frame) |
Moves the frame to the trash queue which is cleaned now and then. | |
void | removePtFrameRef (Frame *frame, Feature *ftr) |
Remove the references between a point and a frame. | |
void | addKeyframe (FramePtr new_keyframe) |
Add a new keyframe to the map. | |
void | getCloseKeyframes (const FramePtr &frame, list< pair< FramePtr, double > > &close_kfs) const |
Given a frame, return all keyframes which have an overlapping field of view. | |
FramePtr | getClosestKeyframe (const FramePtr &frame) const |
Return the keyframe which is spatially closest and has overlapping field of view. | |
FramePtr | getFurthestKeyframe (const Vector3d &pos) const |
Return the keyframe which is furthest apart from pos. | |
bool | getKeyframeById (const int id, FramePtr &frame) const |
void | transform (const Matrix3d &R, const Vector3d &t, const double &s) |
Transform the whole map with rotation R, translation t and scale s. | |
void | emptyTrash () |
Empty trash bin of deleted keyframes and map points. | |
FramePtr | lastKeyframe () |
Return the keyframe which was last inserted in the map. | |
size_t | size () const |
Return the number of keyframes in the map. | |
Public Attributes | |
list< FramePtr > | keyframes_ |
List of keyframes in the map. | |
list< Point * > | trash_points_ |
A deleted point is moved to the trash bin. Now and then this is cleaned. One reason is that the visualizer must remove the points also. | |
MapPointCandidates | point_candidates_ |
Map object which saves all keyframes which are in a map.
svo::Map::Map | ( | ) |
svo::Map::~Map | ( | ) |
void svo::Map::addKeyframe | ( | FramePtr | new_keyframe | ) |
Add a new keyframe to the map.
void svo::Map::deletePoint | ( | Point * | pt | ) |
Moves the point to the trash queue which is cleaned now and then.
void svo::Map::emptyTrash | ( | ) |
Empty trash bin of deleted keyframes and map points.
We don't delete the points immediately to ensure proper cleanup and to provide the visualizer a list of objects which must be removed.
void svo::Map::getCloseKeyframes | ( | const FramePtr & | frame, |
list< pair< FramePtr, double > > & | close_kfs | ||
) | const |
Given a frame, return all keyframes which have an overlapping field of view.
FramePtr svo::Map::getClosestKeyframe | ( | const FramePtr & | frame | ) | const |
Return the keyframe which is spatially closest and has overlapping field of view.
FramePtr svo::Map::getFurthestKeyframe | ( | const Vector3d & | pos | ) | const |
Return the keyframe which is furthest apart from pos.
bool svo::Map::getKeyframeById | ( | const int | id, |
FramePtr & | frame | ||
) | const |
FramePtr svo::Map::lastKeyframe | ( | ) | [inline] |
Return the keyframe which was last inserted in the map.
void svo::Map::removePtFrameRef | ( | Frame * | frame, |
Feature * | ftr | ||
) |
Remove the references between a point and a frame.
void svo::Map::reset | ( | ) |
Reset the map. Delete all keyframes and reset the frame and point counters.
bool svo::Map::safeDeleteFrame | ( | FramePtr | frame | ) |
Moves the frame to the trash queue which is cleaned now and then.
void svo::Map::safeDeletePoint | ( | Point * | pt | ) |
Delete a point in the map and remove all references in keyframes to it.
size_t svo::Map::size | ( | ) | const [inline] |
Return the number of keyframes in the map.
void svo::Map::transform | ( | const Matrix3d & | R, |
const Vector3d & | t, | ||
const double & | s | ||
) |
Transform the whole map with rotation R, translation t and scale s.
list< FramePtr > svo::Map::keyframes_ |
List of keyframes in the map.
list< Point* > svo::Map::trash_points_ |
A deleted point is moved to the trash bin. Now and then this is cleaned. One reason is that the visualizer must remove the points also.