The RTP Video Sender is a ROS1 Noetic package designed for video streaming with ffmpeg.
It captures local video devices (V4L2) and utilizes FFmpeg inside a managed ROS launch environment to encode the stream into H.264 via RTP/UDP. The package supports multiple cameras simultaneously.
Works perfectly with our rtp receiver package.
Ensure FFmpeg with libx264 encoding support is installed on your Debian/Ubuntu system:
sudo apt update
sudo apt install ffmpeg libavcodec-extraThe launch file relies on the standard ROS nodelet package to manage the standalone execution of external processes:
sudo apt install ros-noetic-nodeletClone the repository into your Catkin workspace on the robot:
cd ~/catkin_ws/src
git clone git@github.com:CJT-Robotics/rtp_sender.gitBuild the workspace:
cd ~/catkin_ws
catkin_makeSource your workspace:
source devel/setup.bashStart the ROS Master.
Launch the streaming pipeline using the default configuration:
roslaunch rtp_sender test.launchYou can stream from multiple hardware devices simultaneously by configuring the camera blocks inside the test.launch file, assigning unique UDP ports and video devices.
| Parameter | Default | Description |
|---|---|---|
receiver_ip |
127.0.0.1 |
IP address of the device receiving the stream |
cam1_dev |
/dev/video0 |
V4L2 video device path for Camera 1 |
cam1_port |
5000 |
Target UDP port for the Camera 1 RTP stream |
cam1_fps |
20 |
Framerate |
cam1_preset |
good |
Network quality preset (good or poor) |
The launch file includes predefined bitrate limits:
- Target bitrate:
750k - Maximum bitrate:
1M - Buffer size:
500k
- Target bitrate:
350k - Maximum bitrate:
500k - Buffer size:
250k