10 : pnh_(pnh), it_(pnh), dyn_rec_srv_(pnh)
51 const sensor_msgs::CameraInfoConstPtr& info_msg) {
56 std_msgs::Float64 height, tilt_angle;
62 ROS_DEBUG(
"Publish sensor height (%.2f) and tilt angle (%.2f)", height.data, tilt_angle.data);
67 if (dbg_image !=
nullptr) {
72 catch (std::runtime_error& e) {
91 ROS_DEBUG(
"Unsubscribing from depth topic.");
97 [[maybe_unused]] uint32_t level) {
DepthSensorPoseNode(ros::NodeHandle &pnh)
void depthCallback(const sensor_msgs::ImageConstPtr &depth_msg, const sensor_msgs::CameraInfoConstPtr &info_msg)
depthCb is callback which is called when new depth image appear
void publish(const boost::shared_ptr< M > &message) const
void setUsedDepthHeight(const unsigned height)
setUsedDepthHeight
CameraSubscriber subscribeCamera(const std::string &base_topic, uint32_t queue_size, const CameraSubscriber::Callback &callback, const ros::VoidPtr &tracked_object=ros::VoidPtr(), const TransportHints &transport_hints=TransportHints())
Publisher advertise(const std::string &base_topic, uint32_t queue_size, bool latch=false)
void disconnectCallback()
disconnectCb is called when a subscriber stop subscribing
void setRansacMaxIter(const unsigned u)
image_transport::ImageTransport it_
Subscribes to synchronized Image CameraInfo pairs.
std::mutex connection_mutex_
Prevents the connectCb and disconnectCb from being called until everything is initialized.
void setRangeLimits(const float rmin, const float rmax)
void setReconfParamsUpdated(bool updated)
setReconfParamsUpdated
void reconfigureCallback(depth_sensor_pose::DepthSensorPoseConfig &config, uint32_t level)
reconfigureCb is dynamic reconfigure callback
image_transport::CameraSubscriber sub_
Subscriber for image_transport.
uint32_t getNumSubscribers() const
image_transport::Publisher pub_
Publisher for image_transport.
#define ROS_ERROR_THROTTLE(rate,...)
void publish(const sensor_msgs::Image &message) const
constexpr int MAX_NODE_RATE
float getSensorTiltAngle() const
sensor_msgs::ImageConstPtr getDbgImage() const
void estimateParams(const sensor_msgs::ImageConstPtr &depth_msg, const sensor_msgs::CameraInfoConstPtr &info_msg)
float getSensorMountHeight() const
void setSensorMountHeightMin(const float height)
setSensorMountHeight sets the height of sensor mount (in meters) from ground
Publisher advertise(const std::string &topic, uint32_t queue_size, bool latch=false)
float getNodeRate()
getNodeRate gets rate of data processing loop in node.
void setDepthImgStepCol(const int step)
setDepthImgStepCol
depth_sensor_pose::DepthSensorPose estimator_
Object which contain estimation methods.
void connectCallback()
connectCb is callback which is called when new subscriber connected.
void setDepthImgStepRow(const int step)
setDepthImgStepRow
void setNodeRate(const float rate)
setNodeRate sets rate of processing data loop in node.
void setCamModelUpdate(const bool u)
setCamModelUpdate
ros::NodeHandle pnh_
Private node handler.
uint32_t getNumSubscribers() const
ros::Publisher pub_height_
Publisher for estimated sensor height.
void setGroundMaxPoints(const unsigned u)
ros::Publisher pub_angle_
Publisher for estimated sensor tilt angle.
void setRansacDistanceThresh(const float u)
void setSensorTiltAngleMax(const float angle)
setSensorTiltAngle sets the sensor tilt angle (in degrees)
void setSensorMountHeightMax(const float height)
setSensorMountHeight sets the height of sensor mount (in meters) from ground
dynamic_reconfigure::Server< depth_sensor_pose::DepthSensorPoseConfig > dyn_rec_srv_
Dynamic reconfigure server.
bool getPublishDepthEnable() const
getPublishDepthEnable
float node_rate_hz_
Node loop frequency in Hz.
void setSensorTiltAngleMin(const float angle)
setSensorTiltAngle sets the sensor tilt angle (in degrees)
void setPublishDepthEnable(const bool enable)
setPublishDepthEnable