4 #include <sensor_msgs/Image.h> 7 #include <depth_nav_msgs/Point32List.h> 8 #include <geometry_msgs/Point32.h> 38 void detectCliff(
const sensor_msgs::ImageConstPtr& depth_msg,
39 const sensor_msgs::CameraInfoConstPtr& info_msg);
152 double angleBetweenRays(
const cv::Point3d& ray1,
const cv::Point3d& ray2)
const;
170 void fieldOfView(
double &
min,
double & max,
double x1,
double y1,
171 double xc,
double yc,
double x2,
double y2);
void setDepthImgStepCol(const int step)
setDepthImgStepCol
void detectCliff(const sensor_msgs::ImageConstPtr &depth_msg, const sensor_msgs::CameraInfoConstPtr &info_msg)
detectCliff detects descending stairs based on the information in a depth image
bool cam_model_update_
Determines if continuously cam model update required.
float range_min_
Stores the current minimum range to use.
depth_nav_msgs::Point32List stairs_points_msg_
float getSensorTiltAngle()
getSensorTiltAngle gets sensor tilt angle in degrees
sensor_msgs::Image new_depth_msg_
bool getPublishDepthEnable() const
getPublishDepthEnable
void setParametersConfigurated(const bool u)
setParametersConfigurated
void setDepthImgStepRow(const int step)
setDepthImgStepRow
float range_max_
Stores the current maximum range to use.
bool depth_sensor_params_update
float ground_margin_
Margin for ground points feature detector (m)
void setUsedDepthHeight(const unsigned int height)
setUsedDepthHeight
image_geometry::PinholeCameraModel camera_model_
Class for managing sensor_msgs/CameraInfo messages.
unsigned int used_depth_height_
Used depth height from img bottom (px)
unsigned int block_points_thresh_
Threshold value of points in block to admit stairs.
void setCamModelUpdate(const bool u)
Sets the number of image rows to use in data processing.
void findCliffInDepthImage(const sensor_msgs::ImageConstPtr &depth_msg)
unsigned int block_size_
Square block (subimage) size (px).
void setSensorMountHeight(const float height)
setSensorMountHeight sets the height of sensor mount (in meters) from ground
void setBlockSize(const int size)
setBlockSize sets size of square block (subimage) used in cliff detector
std::vector< unsigned int > dist_to_ground_
Calculated distances to ground for every row of depth image in mm.
void setPublishDepthEnable(const bool enable)
setPublishDepthEnable
float sensor_mount_height_
Height of sensor mount from ground.
bool publish_depth_enable_
Determines if depth should be republished.
void calcGroundDistancesForImgRows(double vertical_fov)
Calculates distances to ground for every row of depth image.
unsigned int depth_image_step_col_
Columns step in depth processing (px).
sensor_msgs::ImageConstPtr depth_msg_to_pub_
Store points which contain stairs.
float getSensorMountHeight()
getSensorMountHeight gets sensor mount height
float sensor_tilt_angle_
Sensor tilt angle (degrees)
void fieldOfView(double &min, double &max, double x1, double y1, double xc, double yc, double x2, double y2)
unsigned int depth_image_step_row_
Rows step in depth processing (px).
void calcDeltaAngleForImgRows(double vertical_fov)
calcDeltaAngleForImgRows
std::string outputFrameId_
Output frame_id for laserscan.
void calcTiltCompensationFactorsForImgRows()
calcTiltCompensationFactorsForImgRows calculate factors used in tilt compensation ...
double angleBetweenRays(const cv::Point3d &ray1, const cv::Point3d &ray2) const
void setGroundMargin(const float margin)
setGroundMargin sets the floor margin (in meters)
void setBlockPointsThresh(const int thresh)
setBlockPointsThresh sets threshold value of pixels in block to set block as stairs ...
double lengthOfVector(const cv::Point3d &vec) const
lengthOfVector calculates length of 3D vector.
std::vector< double > tilt_compensation_factor_
Calculated sensor tilt compensation factors.
The CliffDetector class detect cliff based on depth image.
void setSensorTiltAngle(const float angle)
setSensorTiltAngle sets the sensor tilt angle (in degrees)
std::vector< double > delta_row_
void setRangeLimits(const float rmin, const float rmax)
setRangeLimits sets the minimum and maximum range of depth value from RGBD sensor.