Fawkes API
Fawkes Development Version
|
Compute a pixel position in the camera image from a cartesian world coordinate. More...
Public Member Functions | |
PositionToPixel (fawkes::tf::Transformer *tf, std::string cam_frame, float cam_aperture_x, float cam_aperture_y, unsigned int cam_width_x, unsigned int cam_height_y, float cam_angle_y=0) | |
Construct a PositionToPixel model with the required camera geometry. More... | |
fawkes::upoint_t | get_pixel_position (fawkes::cart_coord_3d_t &position, std::string &frame, const fawkes::Time &time) |
fawkes::point_t | get_pixel_position_unchecked (fawkes::cart_coord_3d_t &position, std::string &frame, const fawkes::Time &time) |
Compute a pixel position in the camera image from a cartesian world coordinate.
Definition at line 33 of file position_to_pixel.h.
firevision::PositionToPixel::PositionToPixel | ( | fawkes::tf::Transformer * | tf, |
std::string | cam_frame, | ||
float | cam_aperture_x, | ||
float | cam_aperture_y, | ||
unsigned int | cam_width_x, | ||
unsigned int | cam_height_y, | ||
float | cam_angle_y = 0 |
||
) |
Construct a PositionToPixel model with the required camera geometry.
tf | The transform listener used by the calling code |
cam_frame | Reference frame of the camera coordinate system |
cam_aperture_x | Horizontal opening angle (rad) |
cam_aperture_y | Vertical opening angle (rad) |
cam_width_x | Horizontal pixel resolution |
cam_height_y | Vertical pixel resolution |
cam_angle_y | Vertical camera mounting angle |
Definition at line 44 of file position_to_pixel.cpp.
fawkes::upoint_t firevision::PositionToPixel::get_pixel_position | ( | fawkes::cart_coord_3d_t & | position, |
std::string & | frame, | ||
const fawkes::Time & | time | ||
) |
position | the 3dimential position (x, y, z) in the given frame |
frame | the frame where the data are in |
time | the timestamp of position |
OutOfBoundsException | ConnectivityException ExtrapolationException LookupException |
Definition at line 124 of file position_to_pixel.cpp.
References get_pixel_position_unchecked(), fawkes::upoint_t::x, fawkes::point_struct::x, fawkes::upoint_t::y, and fawkes::point_struct::y.
fawkes::point_t firevision::PositionToPixel::get_pixel_position_unchecked | ( | fawkes::cart_coord_3d_t & | position, |
std::string & | frame, | ||
const fawkes::Time & | time | ||
) |
position | the 3dimential position (x, y, z) in the given frame |
frame | the frame where the data are in |
time | the timestamp of position |
OutOfBoundsException | ConnectivityException ExtrapolationException LookupException |
Definition at line 80 of file position_to_pixel.cpp.
References fawkes::cart2polar3d(), fawkes::tf::Stamped< T >::frame_id, fawkes::polar_coord_3d_t::phi, fawkes::polar_coord_3d_t::r, fawkes::tf::Stamped< T >::stamp, fawkes::polar_coord_3d_t::theta, fawkes::tf::Transformer::transform_point(), fawkes::point_struct::x, fawkes::cart_coord_3d_t::x, fawkes::point_struct::y, fawkes::cart_coord_3d_t::y, and fawkes::cart_coord_3d_t::z.
Referenced by get_pixel_position().