How to run image_proc with roslaunch
How do you write a launch file to pipeline a color usb camera into image_proc, convert it to mono, and display it in a window?
To display a color usb webcam, this simple launch file works well:
webcam_color.launch:
<launch>
<node name="usb_cam" pkg="usb_cam" type="usb_cam_node" output="screen" >
<param name="video_device" value="/dev/video1" />
<param name="image_width" value="640" />
<param name="image_height" value="480" />
<param name="pixel_format" value="mjpeg" />
<param name="camera_frame_id" value="usb_cam" />
<param name="io_method" value="mmap" />
</node>
<node name="image_view" pkg="image_view" type="image_view" respawn="false" output="screen">
<remap from="image" to="/usb_cam/image_raw" />
<param name="autosize" value="true" />
</node>
</launch>
However, I can't find any examples of using image_proc in a launch file. I can pipe the color video stream into image_proc and display the mono using:
roslaunch mypkg webcam_test.launch
ROS_NAMESPACE=usb_cam rosrun image_proc image_proc
rosrun image_view image_view image:=/usb_cam/image_mono
What would be the equivalent of doing this all in a single launch file?