Terminal 1 Download gsttestsrc.tar.gz https://www.dropbox.com/s/vv2447xvikp5ftl/gsttestsrc.tar.gz?dl=0 wget
tar -xvf gsttestsrc.tar.gz
- cd gst
- ./gst-master
- chmod +x kt.sh
- ./kt.sh
- Wait for the compile/make for gst-switch and then gst-switch-srv and ui are started.
- Wait for the UI to appear.
When UI pops up, go to Terminal 1 and start up a pipeline When first time UI comes up, put in the first pipeline in terminal 1. When second time the UI comes up, put in the second pipeline in terminal 2
Terminal 1 Pipelines
-
gst-launch-1.0 videotestsrc pattern=2 ! timeoverlay font-desc="90px" ! video/x-raw, width=300, height=200 ! gdppay ! tee name=abc ! queue ! tcpclientsink port=3000 abc. ! queue ! tcpclientsink port=3000 abc. ! gdpdepay ! jpegenc ! avimux ! filesink location=2.avi
This pipeline is useful for finding dropped frames in switches and when a record file changes. -
gst-launch-1.0 videotestsrc pattern=blink ! video/x-raw, width=300, height=200 ! gdppay ! tee name=abc ! queue ! tcpclientsink port=3000 abc. ! queue ! tcpclientsink port=3000 abc. ! gdpdepay ! jpegenc ! avimux ! filesink location=2.avi
This pipeline is better to detect frame drops in between any UI events.
Producing frames -
- Press
tab
key in the UI around 5-6 in an interval of around 15 secs to switch the video. After this press ther
key 3-4 times.
Now each directory $HOME/frames/1/frames**
and $HOME/frames/2/frames**
will have lots of frames inside it. Going through these dumped frames, find positions of where exactly the switch event happens. Compare frames before and after the switch. Similarly, the frames produced by the recording can also be compared.
For finding frame dropped in between switches, the above pipeline can be difficult to use. Instead use the pipeline -
This should feed in a source which alternates frames of RED, GREEN, BLUE.
Python file to detect red/blue/green in equal pip mode is detect_frames.py