mirror of
https://github.com/introlab/rtabmap.git
synced 2026-09-02 01:20:25 +08:00
Added DBDriver::setTimestampUpdateEnabled()
Don't update timestamps if only links are modified
This commit is contained in:
@@ -72,6 +72,7 @@ public:
|
||||
void asyncSave(VisualWord * vw); //ownership transferred
|
||||
void emptyTrashes(bool async = false);
|
||||
double getEmptyTrashesTime() const {return _emptyTrashesTime;}
|
||||
void setTimestampUpdateEnabled(bool enabled) {_timestampUpdate = enabled;} // used on Update Signature and Word queries
|
||||
|
||||
public:
|
||||
void addStatisticsAfterRun(int stMemSize, int lastSignAdded, int processMemUsed, int databaseMemUsed, int dictionarySize) const;
|
||||
@@ -121,8 +122,8 @@ private:
|
||||
|
||||
virtual void saveQuery(const std::list<Signature *> & signatures) const = 0;
|
||||
virtual void saveQuery(const std::list<VisualWord *> & words) const = 0;
|
||||
virtual void updateQuery(const std::list<Signature *> & signatures) const = 0;
|
||||
virtual void updateQuery(const std::list<VisualWord *> & words) const = 0;
|
||||
virtual void updateQuery(const std::list<Signature *> & signatures, bool updateTimestamp) const = 0;
|
||||
virtual void updateQuery(const std::list<VisualWord *> & words, bool updateTimestamp) const = 0;
|
||||
|
||||
|
||||
// Load objects
|
||||
@@ -157,6 +158,7 @@ private:
|
||||
USemaphore _addSem;
|
||||
double _emptyTrashesTime;
|
||||
std::string _url;
|
||||
bool _timestampUpdate;
|
||||
};
|
||||
|
||||
}
|
||||
|
||||
@@ -80,8 +80,8 @@ public:
|
||||
std::list<int> cleanup(const std::list<int> & ignoredIds = std::list<int>());
|
||||
void emptyTrash();
|
||||
void joinTrashThread();
|
||||
bool addLoopClosureLink(int oldId, int newId, const Transform & transform, Link::Type type, float variance);
|
||||
void updateNeighborLink(int fromId, int toId, const Transform & transform, float variance);
|
||||
bool addLink(int to, int from, const Transform & transform, Link::Type type, float variance);
|
||||
void updateLink(int fromId, int toId, const Transform & transform, float variance);
|
||||
void removeAllVirtualLinks();
|
||||
std::map<int, int> getNeighborsId(int signatureId,
|
||||
int margin,
|
||||
@@ -90,7 +90,7 @@ public:
|
||||
bool ignoreLoopIds = false,
|
||||
double * dbAccessTime = 0) const;
|
||||
void deleteLocation(int locationId, std::list<int> * deletedWords = 0);
|
||||
void rejectLoopClosure(int oldId, int newId);
|
||||
void removeLink(int idA, int idB);
|
||||
|
||||
//getters
|
||||
const std::set<int> & getWorkingMem() const {return _workingMem;}
|
||||
@@ -214,7 +214,8 @@ private:
|
||||
Signature * _lastSignature;
|
||||
int _lastGlobalLoopClosureParentId;
|
||||
int _lastGlobalLoopClosureChildId;
|
||||
bool _memoryChanged; // False by default, become true when Memory::update() is called.
|
||||
bool _memoryChanged; // False by default, become true only when Memory::update() is called.
|
||||
bool _linksChanged; // False by default, become true when links are modified.
|
||||
int _signaturesAdded;
|
||||
bool _postInitClosingEvents;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user