added dvr for gstreamer

pull/254/head
GitNiKO 2023-11-11 21:20:42 +03:00 committed by GitHub
parent d9840a650f
commit b926f25740
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 10 additions and 0 deletions

View File

@ -105,6 +105,16 @@ gst-launch-1.0 udpsrc port=5600 caps='application/x-rtp, media=(string)video, cl
###GS IS READY FOR USE###
### DVR(Digital Video Recorder) and playback
Create a file **gst_start.sh** with the following content and assign the rights to execute **chmod +x gst_start.sh**
```
#!/bin/sh
current_date=$(date +'%Y%d%m_%H%M')
cd ~/Videos
gst-launch-1.0 -e udpsrc port=5600 caps='application/x-rtp, media=(string)video, clock-rate=(int)90000, encoding-name=(string)H265' ! rtph265depay ! h265parse ! tee name=t ! queue ! mppvideodec ! xvimagesink sync=false t. ! queue ! matroskamux ! filesink location=record_${current_date}.mkv
```
Each time you start, a new video file will be created in the **/home/Video/** folder.
### Start, stop, restart service
```