ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Hi,

For pin hole cameras that gazebo is simulating, the equation below holds,

focal_lengtth = image_width / (2*tan(hfov_radian / 2)

One way to avoid inconsistency is to NOT specify <focal_length> tag in your XML. That way, <focal_length> is calculated using the above formula.

In addition, I'll patch gazebo_ros_camera plugin to raise an inconsistency error message when a focal_length is provided that is inconsistent with image_width and hfov.

Will that fix the problem for you?

Thanks, John