gazebo :camera focal length in mm
i want to specify the focal length camera value in mm or pixel dimensions, in my urdf file gazebo ros
ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
i want to specify the focal length camera value in mm or pixel dimensions, in my urdf file gazebo ros
Hi @eogeo,
If you look at the SDF format in the sensor tag, inside camera
tag, there is a section for camera intrinsics
in which you can define, among other things:
fx
: X focal length (in pixels, overrides horizontal_fov).fy
: Y focal length (in pixels, overrides horizontal_fov).cx
: X principal point (in pixels).cy
: Y principal point (in pixels).s
: XY axis skew.Hope this helps you.
Regards.
@leogeo Well in your answer you stated literally "focal length camera value in mm or pixel dimensions". As I undestand with your post is that you wanted to know how to set up those parameters in the URDF; If that is what you want, you will need to convert those values from mm to pixel and use the parameters I mentioned in my answer. However, If you want to know how to compute the focal_length
from what you have in mm to what you need in px, that, indeed, is completely different question. Since It seems that is this last option I would say that you cand find plenty of information about this topic over the internet, like here, butI will say, this is something that not related to ROS.
Asked: 2020-10-02 12:14:29 -0600
Seen: 1,885 times
Last updated: Oct 04 '20