Image Pipeline Foxy 20210322

From wikidb
Jump to: navigation, search

Image Pipeline References

Other Cameras

Location

image_ws

Installing the Image Publisher

See Webcam Foxy Notes below for more details.

I may have found this by going here: https://index.ros.org/r/image_pipeline/github-ros-perception-image_pipeline/#foxy

 $ mkdir -p image_ws/src

 $ cd image_ws/src/

 $ git clone -b 2.1.1 https://github.com/ros-perception/image_pipeline
     ...

$ ls
     image_pipeline

 $ ls image_pipeline/
     camera_calibration  image_proc       LICENSE            wiki_files
     CONTRIBUTING.md     image_publisher  README.md
     depth_image_proc    image_rotate     stereo_image_proc
     image_pipeline      image_view       tools

 $ cd ..

 $ colcon build --symlink-install --parallel-workers 1
     ...
  • Lots of warnings about deprecated headers

Execute the Image Publisher

The image_publisher came from the Image Pipeline Foxy 20210322

TERMINAL 1

 $ source ~/image_ws/install/setup.bash

 $ ros2 run image_publisher image_publisher_node /dev/video0
     [INFO] [1618505195.586979521] [ImagePublisher]: param_change_callback
     [INFO] [1618862018.060864187] [ImagePublisher]: Reset filename as '/dev/video0'
     [INFO] [1618862018.060899412] [ImagePublisher]: File name for publishing image is : /dev/video0
     [ WARN:0] global ../modules/videoio/src/cap_gstreamer.cpp (1758) handleMessage OpenCV | GStreamer warning: Embedded video playback halted; module source reported: Could not read from resource.
     [ WARN:0] global ../modules/videoio/src/cap_gstreamer.cpp (888) open OpenCV | GStreamer warning: unable to start pipeline
     [ WARN:0] global ../modules/videoio/src/cap_gstreamer.cpp (480) isPipelinePlaying OpenCV | GStreamer warning: GStreamer: pipeline have not been created
     [INFO] [1618862020.729152588] [ImagePublisher]: Flip horizontal image is : false
     [INFO] [1618862020.729282428] [ImagePublisher]: Flip flip_vertical image is : false

TERMINAL 2

 $ ros2 topic list
     /camera_info
     /image_raw
     /parameter_events
     /rosout

 $ ros2 topic echo image_raw
     ---
     header:
       stamp:
         sec: 1617818511
         nanosec: 782709125
       frame_id: camera
     height: 480
     width: 640
     encoding: bgr8
     is_bigendian: 0
     step: 1920
     data:
     - 82
     - 85
     - 82
     -
     ...
     ...

Execute Image View

The image_publisher came from the Image Pipeline Foxy 20210322

 $ ros2 run image_view image_view image:=image_raw
       [WARN] [1622086172.613337840] [rcl]: Found remap rule 'image:=image_raw'. This syntax is deprecated. Use '--ros-args --remap image:=image_raw' instead.
       [INFO] [1622086172.634011782] [image_view_node]: Using transport "raw"

ImageView20210526.png

You will also find an image viewer in

Notes and Logs