36 #ifndef JSK_RECOGNITION_UTILS_CAMERA_DEPTH_SENSOR_H_ 37 #define JSK_RECOGNITION_UTILS_CAMERA_DEPTH_SENSOR_H_ 40 #include <sensor_msgs/CameraInfo.h> 70 virtual bool isInside(
const cv::Point& p)
const 85 return f*f / (distance*distance) * area;
92 virtual cv::Mat
image(
const int type)
const 121 return cv::Point(std::min(std::max(p.x, 0),
width()),
122 std::min(std::max(p.y, 0),
height()));
virtual int width() const
width of camera in pixels.
virtual cv::Point limit2DPoint(const cv::Point &p) const
force point to be inside of field of view.
virtual bool isInside(const cv::Point &p) const
return true if point p is inside of field-of-view.
virtual cv::Mat image(const int type) const
return an image from internal camera parameter.
sensor_msgs::CameraInfo camera_info_
virtual image_geometry::PinholeCameraModel getPinholeCameraModel() const
get instance of image_geometry::PinholeCameraModel.
virtual double expectedPointCloudNum(double distance, double area) const
Return the expected number of points according to distance and area. it is calculated according to: f...
virtual int height() const
height of camera in pixels.
boost::shared_ptr< CameraDepthSensor > Ptr
bool fromCameraInfo(const sensor_msgs::CameraInfo &msg)
image_geometry::PinholeCameraModel model_
Super class for sensor model. It provides pure virtual method for common interfaces.
virtual void setCameraInfo(const sensor_msgs::CameraInfo &info)