diff --git a/configs/test1.ini b/configs/test1.ini index 4031454..6a41eb2 100644 --- a/configs/test1.ini +++ b/configs/test1.ini @@ -13,8 +13,6 @@ port=10001 [grabber] port=10002 - - [mainvideo] playaudio=true @@ -27,5 +25,3 @@ videocaps=video/x-raw,width=320,height=200,framerate=30000/1001 system=xv # system=x -[extra] -foo=bar diff --git a/ingest.py b/ingest.py index f4bd472..be4426d 100755 --- a/ingest.py +++ b/ingest.py @@ -151,7 +151,7 @@ def mk_video_src(args, videocaps): video_src = """ videotestsrc name=videosrc {attribs} ! clockoverlay - text="Source:{hostname}\nCaps:{videocaps}\nAttribs:{attribs}\n" + text="Source: {hostname}\nCaps: {videocaps}\nAttribs: {attribs}\n" halignment=left line-alignment=left ! {monitor} """ diff --git a/record-mixed-av.sh b/record-mixed-av.sh index 15253e9..540be59 100755 --- a/record-mixed-av.sh +++ b/record-mixed-av.sh @@ -7,14 +7,20 @@ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: -# +# # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. -# $1 - destination dir. default: ~/Videos +# $1 - destination dir. default: ~/Videos # files will be $dest_dir/$date/$time.gs.ts # (.gs to keep these apart from the files created by record-timestamp.sh) +# NB: does not chunk files. keeps saving untill the process is killed. + +# TODO: https://gstreamer.freedesktop.org/data/doc/gstreamer/head/gst-plugins-good/html/gst-plugins-good-plugins-splitmuxsink.html + +# splitmuxsink — Muxer wrapper for splitting output stream by size or time + dest_dir=${1:-~/Videos}/$(date +%Y-%m-%d) mkdir -p $dest_dir diff --git a/tests/mock-stack.sh b/tests/mock-stack.sh index 7fe2b64..cd5d2f1 100755 --- a/tests/mock-stack.sh +++ b/tests/mock-stack.sh @@ -3,10 +3,14 @@ # core server gst-launch-1.0 \ tcpserversrc host=127.0.0.1 port=4953 ! \ - queue ! \ + queue ! matroskaparse ! \ tcpserversink host=127.0.0.1 port=4954 \ & srv=$! sleep 1 +function finish { + kill $srv 2> /dev/null +} +trap finish EXIT # test source client gst-launch-1.0 \ @@ -35,7 +39,4 @@ gst-launch-1.0 \ queue !\ mux. \ mpegtsmux name=mux !\ - filesink location="/tmp/test.ts" \ - -kill $srv - + filesink location="/tmp/test.ts" diff --git a/tests/show_hdmi2usb.sh b/tests/show_hdmi2usb.sh index 0d53067..6182efc 100755 --- a/tests/show_hdmi2usb.sh +++ b/tests/show_hdmi2usb.sh @@ -1,8 +1,15 @@ -#!/bin/bash -ex +#!/bin/bash -x gst-launch-1.0 \ - v4l2src device=/dev/video1 !\ - jpegdec !\ + -v \ + v4l2src device=/dev/$1 !\ + decodebin !\ queue ! videoconvert !\ fpsdisplaysink sync=false + # video/raw,width=1280,height=720 !\ + # video/raw,width=1280,height=960 !\ + # jpegdec !\ + # decodebin !\ + # video/x-raw, format=(string)YUY2, width=(int)1920, height=(int)1080, pixel-aspect-ratio=(fraction)1/1, interlace-mode=(string)progressive, colorimetry=(string)2:4:7:1, framerate=(fraction)5/1' + # video/x-raw, format=YUY2, width=1920, height=1080, pixel-aspect-ratio=1/1, interlace-mode=progressive, colorimetry=2:4:7:1, framerate=5/1 !\