Closed ArghyaChatterjee closed 1 year ago
Could you provide a complete log and an accompanying launch file that we can use to investigate this issue? Thanks!
Here is my launch file: https://github.com/ros-drivers/usb_cam/blob/ros2/launch/demo_launch.py camera_info.yaml file: https://github.com/ros-drivers/usb_cam/blob/ros2/config/camera_info.yaml
image_width: 1920
image_height: 1080
camera_name: test_camera
camera_matrix:
rows: 3
cols: 3
data: [438.783367, 0.000000, 305.593336, 0.000000, 437.302876, 243.738352, 0.000000, 0.000000, 1.000000]
distortion_model: plumb_bob
distortion_coefficients:
rows: 1
cols: 5
data: [-0.361976, 0.110510, 0.001014, 0.000505, 0.000000]
rectification_matrix:
rows: 3
cols: 3
data: [0.999978, 0.002789, -0.006046, -0.002816, 0.999986, -0.004401, 0.006034, 0.004417, 0.999972]
projection_matrix:
rows: 3
cols: 4
data: [393.653800, 0.000000, 322.797939, 0.000000, 0.000000, 393.653800, 241.090902, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000]
params.yaml https://github.com/ros-drivers/usb_cam/blob/ros2/config/params.yaml
/**:
ros__parameters:
video_device: "/dev/video0"
framerate: 30.0
io_method: "mmap"
frame_id: "camera"
pixel_format: "yuyv"
color_format: "yuv422p"
image_width: 1920
image_height: 1080
camera_name: "test_camera"
camera_info_url: "package://usb_cam/config/camera_info.yaml"
By looking at the camera_info.yaml
file it feels like the camera_matrix and projection_matrix data are incorrect. Also, in params.yaml
it is not specified that it is an RGB image. Could you verify that you are able to visualize the images from your camera in Rviz or Rqt? Also, if it is possible to get the ROS bag recording to diagnose?
Hello,
I was trying to use this repo inside docker. It runs well as you gave the demo ros bag but with my USB camera with the ros2 usb_cam node running, it gives the following result:
Here is the node: https://github.com/ros-drivers/usb_cam
git checkout ros2
Note:
image_raw
topic toimage
to feed this rosnode and