tldr: A ROS2 python node for streaming video files or images to a topic.
There is a ros2_video_streamer_node
launch file. Minimally, you need to provide
a type
(e.g. video or image) and path
, which is the full path to the content
to stream.
ros2 launch ros2_video_streamer ros2_video_streamer_node type:=<type> path:=<path>
The content is published on the ~/image/compressed
topic.
There are also the following optional settings that you can pass to the launch file
-
node_name - Override the default name of the node.
-
image_topic_name - Override default name of the topic to publish images to
-
info_topic_name - Override default name of the topic to publish camera info to
-
config_file_name - Name of YAML file in the
config
folder.CameraInfo
messages are published on the~/camera_info
topic based on the content of the config file. By default, nothing is published. -
loop (true or false) - Continously publish the source on loop
-
frame_id - Frame id string in the
CameraInfo
messages. -
start (int) - Location to start publishing the source.