Added CalibrationDialog in Preferences->source for convenience. The database is also changed to handle new FX, FY, CX and CY intrinsic parameters instead of only depthConstant parameter. Added version of the database in a new table Admin. Updated to version 0.7.0.

git-svn-id: http://rtabmap.googlecode.com/svn/trunk/rtabmap@1613 f169173b-cf89-36c8-b27e-44dbe73f0c83
This commit is contained in:
matlabbe
2014-07-26 04:36:00 +00:00
parent 1557b3d44d
commit f090c81aaf
44 changed files with 1389 additions and 715 deletions

View File

@@ -42,7 +42,10 @@ Signature::Signature(
const std::vector<unsigned char> & depth2D, // in base_link frame
const std::vector<unsigned char> & image, // in camera_link frame
const std::vector<unsigned char> & depth, // in camera_link frame
float depthConstant,
float fx,
float fy,
float cx,
float cy,
const Transform & localTransform) :
_id(id),
_mapId(mapId),
@@ -55,7 +58,10 @@ Signature::Signature(
_image(image),
_depth(depth),
_depth2D(depth2D),
_depthConstant(depthConstant),
_fx(fx),
_fy(fy),
_cx(cx),
_cy(cy),
_pose(pose),
_localTransform(localTransform),
_words3(words3)
@@ -188,11 +194,14 @@ void Signature::removeWord(int wordId)
_words3.erase(wordId);
}
void Signature::setDepth(const std::vector<unsigned char> & depth, float depthConstant)
void Signature::setDepth(const std::vector<unsigned char> & depth, float fx, float fy, float cx, float cy)
{
UASSERT_MSG(depth.empty() || (!depth.empty() && depthConstant > 0.0f), uFormat("depthConstant=%f",depthConstant).c_str());
UASSERT_MSG(depth.empty() || (!depth.empty() && fx > 0.0f && fy > 0.0f && cx >= 0.0f && cy >= 0.0f), uFormat("fx=%f fy=%f cx=%f cy=%f",fx,fy,cx,cy).c_str());
_depth = depth;
_depthConstant=depthConstant;
_fx=fx;
_fy=fy;
_cx=cx;
_cy=cy;
}
} //namespace rtabmap