ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

what is the first step of doing image processing with ROS?

asked 2015-12-18 08:26:04 -0600

fatima gravatar image

hi i am beginner with image processing and want to start that with ROS but i dont know what is the first step ? for example should i first install OpenCV? or its not important ? and may be i should install some package in my workspace ? i have a webcam on my laptop i want to use it. please guide me if any one could.

edit retag flag offensive close merge delete

3 Answers

Sort by ยป oldest newest most voted
3

answered 2015-12-18 09:13:47 -0600

The first thing you'll need to do is get your webcam output captured by a ros node and broadcast as an image topic so that other ros nodes can use the images. Take a look at

http://wiki.ros.org/usb_cam

or

http://wiki.ros.org/libuvc_camera

Both should work with a USB web cam. Then when the camera capture node is running you can use Rviz as a quick way to check the images are being published properly. Rviz is a GUI that allows you to visualize ros topics. If you click 'add' in the bottom left of the window and click on the add by topic tab you should see you camera node listed. Selecting this topic will add a new window to Rviz that should show the images from your webcam!

When this is all working you can have a look at the image subscriber tutorial tutorial here: http://wiki.ros.org/image_transport/T... to get started manipulating the image data, this is where you might starting playing with OpenCV

edit flag offensive delete link more

Comments

fatima gravatar image fatima  ( 2015-12-18 10:17:16 -0600 )edit

hi thank you so much, i run usb_cam node before and could run Rviz i clicked add the result is :

fatima gravatar image fatima  ( 2015-12-18 10:17:18 -0600 )edit
[ INFO] [1450467742.148411685]: compiled against OGRE version 1.8.1 (Byatis)
[ INFO] [1450467742.676989007]: Stereo is NOT SUPPORTED
[ INFO] [1450467742.677113146]: OpenGl version: 3 (GLSL 1.3).
fatima gravatar image fatima  ( 2015-12-18 10:17:51 -0600 )edit

i saw Rviz window with a grid i added camera but again i only have a grid i dont know how should i use the camera in rviz ?

fatima gravatar image fatima  ( 2015-12-18 10:29:13 -0600 )edit

You have to add the image topic to Rviz.

  • After you run Rviz, click on Add button on lower left corner.
  • Then click 'By topic' and select the correct topic based on your camera topic name. It should look something like:

    <camera_name>/Image

hvpandya gravatar image hvpandya  ( 2016-01-21 15:49:16 -0600 )edit
0

answered 2016-01-21 15:53:12 -0600

hvpandya gravatar image

updated 2016-01-21 15:54:22 -0600

While the other answer gets you into getting an image stream from the camera and playing with it, I believe you should start with OpenCV bare minimum i.e.

Open an image and Display it

Then go on to

modify that image and save/write it

Once you have done that start following the other answer, get image stream from your webcam and play with advanced stuff.

Hope this helps!

edit flag offensive delete link more
0

answered 2016-01-22 12:39:48 -0600

tn0432 gravatar image

For my case when starting to learn image processing with ROS, I use gscam package to get image from camera. CV Bridge package to transfer from ROS standard image to OpenCV standard image. When you image is presented at OpenCV standard, you are able to use available functions in OpenCV for image processing.

Good luck!

edit flag offensive delete link more

Question Tools

2 followers

Stats

Asked: 2015-12-18 08:26:04 -0600

Seen: 7,512 times

Last updated: Jan 22 '16