RealSense: added depthScaledToRGBSize option to be able to feed ORB_SLAM2 with depth and RGB images with same size #287.

This commit is contained in:
matlabbe
2018-06-19 13:53:03 -04:00
parent c91431410e
commit 973bf93c77
5 changed files with 41 additions and 8 deletions

View File

@@ -386,6 +386,7 @@ public:
const Transform & localTransform = Transform::getIdentity());
virtual ~CameraRealSense();
void setDepthScaledToRGBSize(bool enabled) {depthScaledToRGBSize_ = enabled;}
virtual bool init(const std::string & calibrationFolder = ".", const std::string & cameraName = "");
virtual bool isCalibrated() const;
virtual std::string getSerial() const;
@@ -402,6 +403,7 @@ private:
int presetRGB_;
int presetDepth_;
bool computeOdometry_;
bool depthScaledToRGBSize_;
int motionSeq_[2];
rs::slam::slam * slam_;
@@ -414,7 +416,7 @@ private:
#endif
};
/////////////////////////
// CameraRealSense
// CameraRealSense2
/////////////////////////
class slam_event_handler;
class RTABMAP_EXP CameraRealSense2 :