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 | Q&A answers.ros.org |
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.
Please start posting anonymously - your entry will be published after you log in or create a new account.
Asked: 2020-10-02 12:14:29 -0500
Seen: 1,242 times
Last updated: Oct 04 '20
How to make tf file for pcd/vector map
question on Converting between ROS images and OpenCV images (C++)
How to remap in launch file[error]
Error with robot localization and global costmap
How to input gazebo camera feed into opencv python?
pass ros param as argument to another param