added rpicam-vid

This commit is contained in:
cpu
2024-02-02 23:25:39 +01:00
parent 1dec02e0f7
commit f6ab5c4f61

View File

@@ -179,6 +179,10 @@ Use the dockerized ffmpeg with precompiled vaapi support, adjust `/dev/video2`
Adjust `/dev/video2`, `-video_size 1920x1080 -framerate 60` and stream to peertube (if it can handle that much) Adjust `/dev/video2`, `-video_size 1920x1080 -framerate 60` and stream to peertube (if it can handle that much)
> `ffmpeg -hide_banner -y -f v4l2 -input_format mjpeg -video_size 1920x1080 -framerate 60 -hwaccel vaapi -hwaccel_device /dev/dri/renderD128 -hwaccel_output_format vaapi -i /dev/video2 -vf 'scale_vaapi=format=nv12' -c:v h264_vaapi -b:v 10M -f flv rtmp://peertube.virtonline.eu:1935/live/LIVE-STREAM-KEY` > `ffmpeg -hide_banner -y -f v4l2 -input_format mjpeg -video_size 1920x1080 -framerate 60 -hwaccel vaapi -hwaccel_device /dev/dri/renderD128 -hwaccel_output_format vaapi -i /dev/video2 -vf 'scale_vaapi=format=nv12' -c:v h264_vaapi -b:v 10M -f flv rtmp://peertube.virtonline.eu:1935/live/LIVE-STREAM-KEY`
For the 'bookworm' version of Raspberry OS usig rpicam-vid with the silent audio stream
> `rpicam-vid --inline --nopreview -t 0 --width 640 --height 480 --framerate 15 --bitrate 500000 --codec h264 -o - | ffmpeg -f lavfi -i anullsrc=channel_layout=stereo:sample_rate=44100 -thread_queue_size 1024 -use_wallclock_as_timestamps 1 -i pipe:0 -c:v copy -c:a aac -preset fast -strict experimental -f flv rtmp://peertube.virtonline.eu:1935/live/LIVE-STREAM-KEY`
### Setup a systemd service for a non-stop streaming ### Setup a systemd service for a non-stop streaming
Adapt VIDEO_BITRATE="3500000" to your max network upload speed Adapt VIDEO_BITRATE="3500000" to your max network upload speed
``` ```