The ROS image pipeline

The ROS image pipeline is run with the image_proc package. It provides all the conversion utilities for obtaining monochrome and color images from the RAW images acquired from the camera. In the case of FireWire cameras, which may use a Bayer pattern to code the images (actually in the sensor itself), it debayers them to obtain the color images. Once you have calibrated the camera, the image pipeline takes the CameraInfo messages, which contain that information, and rectifies the images. Here, rectification means to un-distort the images, so it takes the coefficients of the distortion model to correct the radial and tangential distortion.

As a result, you will see more topics for your camera in its namespace. In the following screenshots, you can see the image_raw, image_mono, and image_colour topics, which display the RAW, monochrome, and color images, respectively:

The mono color, in this case, is equivalent to the following raw image. Note that for good cameras the raw image usually employs a Bayer pattern for the cells on the camera sensor, so it will not be equivalent to the mono color one.

Finally, the following color image is shown, which is only different from the mono color one if the camera actually supports colors; otherwise, it will be mono color too:

The rectified images are provided in monochrome and color in the image_rect and image_rect_color topics. In the following image, we compare the uncalibrated, distorted RAW images with the rectified ones. You can see the correction because the pattern shown in the screenshots has straight lines only in the rectified images, particularly in areas far from the center (principle point) of the image (sensor):

You can see all the topics available with rostopic list or rqt_graph, which include the image_transport topics as well.

You can view the image_raw topic of a monocular camera directly with the
following command:

    $ roslaunch chapter5_tutorials camera.launch view:=true  

It can be changed to see other topics, but for these cameras, the RAW images are already in color. However, in order to see the rectified images, use image_rect_color with image_view or rqt_image_view or change the launch file. The image_proc node is used to make all these topics available. The following code shows this:

<node ns="$(arg camera)" pkg="image_proc" type="image_proc" 
name="image_proc"/>
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.222.69.152