Commit 113b0f46 authored by Andreas Schmidt's avatar Andreas Schmidt

Update gst_plugin.

parent a2f2a385
#include:
# - video.deploy
demo_script:
file.managed:
- name: /home/rna/video_demo.py
- source: salt://video/files/video_demo.py
- user: rna
- group: rna
- file_mode: keep
Subproject commit bdf4ec4ed6ec30659baa825d4f0e1154333e56d9
Subproject commit 892c4ad4d5abf99f44d59f2e4037dc597b1b33eb
import subprocess
import argparse
import time
import os
import signal
def parse_args():
parser = argparse.ArgumentParser(description='')
parser.add_argument("side", metavar="side", choices=["sender", "receiver"])
return parser.parse_args()
def main():
args = parse_args()
sleep_time = 60
env = os.environ.copy()
env["PATH"] = ("/home/rna/gst/1.10/gst-devtools/validate/tools:"
"/home/rna/gst/1.10/totem/src:"
"/home/rna/gst/1.10/gst-editing-services/tools:"
"/home/rna/gst/1.10/gstreamer/tools:"
"/home/rna/gst/1.10/gst-plugins-base/tools:"
"/home/rna/gst/1.10/gst-player/src:"
"/home/rna/gst/1.10/gst-editor/src:"
"/home/rna/gst/1.10/gstreamer-sharp/tools:"
"/home/rna/gst/1.10/orc/tools:"
"/home/rna/gst/1.10/prefix/bin:") + env["PATH"]
env["GST_PLUGIN_PATH"] = ("/home/rna/gst/1.10/gstreamer/plugins:/home/rna/gst/1.10/gst-plugins-base/ext:"
"/home/rna/gst/1.10/gst-plugins-base/gst:/home/rna/gst/1.10/gst-plugins-base/sys:"
"/home/rna/gst/1.10/gst-plugins-good/ext:/home/rna/gst/1.10/gst-plugins-good/gst:"
"/home/rna/gst/1.10/gst-plugins-good/sys:/home/rna/gst/1.10/gst-plugins-ugly/ext:"
"/home/rna/gst/1.10/gst-plugins-ugly/gst:/home/rna/gst/1.10/gst-plugins-ugly/sys:"
"/home/rna/gst/1.10/gst-plugins-bad/ext:/home/rna/gst/1.10/gst-plugins-bad/gst:"
"/home/rna/gst/1.10/gst-plugins-bad/sys:/home/rna/gst/1.10/gst-libav/ext/:"
"/home/rna/gst/1.10/gst-ffmpeg/ext/:/home/rna/gst/1.10/gst-omx/omx/.libs:"
"/home/rna/gst/1.10/clutter-gst/clutter-gst/.libs:/home/rna/gst/1.10/gstreamer-vaapi/gst/vaapi/.libs:"
"/home/rna/gst/1.10/plugins:/home/rna/gst/1.10/farsight2/gst:/home/rna/gst/1.10/farsight2/transmitters:"
"/home/rna/gst/1.10/libnice/gst:/home/rna/gst/1.10/gst-rpicamsrc/src/.libs:/home/rna/gst/1.10/gst-rtsp-server/gst/rtsp-sink/.libs:"
"/home/rna/gst/1.10/gst-editing-services/plugins/nle/.libs")
env["LD_LIBRARY_PATH"] = ("/home/rna/gst/1.10/gstreamer-sharp/gstreamer-sharp/glue/.libs:"
"/home/rna/gst/1.10/totem-pl-parser/plparse/.libs:/home/rna/gst/1.10/clutter-gst/clutter-gst/.libs:"
"/home/rna/gst/1.10/gstreamer/gst/.libs:/home/rna/gst/1.10/gstreamer/libs/gst/net/.libs:"
"/home/rna/gst/1.10/gstreamer/libs/gst/controller/.libs:/home/rna/gst/1.10/gstreamer/libs/gst/check/.libs:"
"/home/rna/gst/1.10/gstreamer/libs/gst/base/.libs:/home/rna/gst/1.10/gst-plugins-bad/gst-libs/gst/wayland/.libs:"
"/home/rna/gst/1.10/gst-plugins-bad/gst-libs/gst/video/.libs:/home/rna/gst/1.10/gst-plugins-bad/gst-libs/gst/uridownloader/.libs:"
"/home/rna/gst/1.10/gst-plugins-bad/gst-libs/gst/player/.libs:/home/rna/gst/1.10/gst-plugins-bad/gst-libs/gst/mpegts/.libs:"
"/home/rna/gst/1.10/gst-plugins-bad/gst-libs/gst/interfaces/.libs:/home/rna/gst/1.10/gst-plugins-bad/gst-libs/gst/insertbin/.libs:"
"/home/rna/gst/1.10/gst-plugins-bad/gst-libs/gst/gl/.libs:/home/rna/gst/1.10/gst-plugins-bad/gst-libs/gst/codecparsers/.libs:"
"/home/rna/gst/1.10/gst-plugins-bad/gst-libs/gst/basecamerabinsrc/.libs:/home/rna/gst/1.10/gst-plugins-bad/gst-libs/gst/base/.libs:"
"/home/rna/gst/1.10/gst-plugins-bad/gst-libs/gst/audio/.libs:/home/rna/gst/1.10/gst-plugins-bad/gst-libs/gst/adaptivedemux/.libs:"
"/home/rna/gst/1.10/gst-plugins-base/gst-libs/gst/video/.libs:/home/rna/gst/1.10/gst-plugins-base/gst-libs/gst/utils/.libs:"
"/home/rna/gst/1.10/gst-plugins-base/gst-libs/gst/tag/.libs:/home/rna/gst/1.10/gst-plugins-base/gst-libs/gst/sdp/.libs:"
"/home/rna/gst/1.10/gst-plugins-base/gst-libs/gst/rtsp/.libs:/home/rna/gst/1.10/gst-plugins-base/gst-libs/gst/rtp/.libs:"
"/home/rna/gst/1.10/gst-plugins-base/gst-libs/gst/riff/.libs:/home/rna/gst/1.10/gst-plugins-base/gst-libs/gst/pbutils/.libs:"
"/home/rna/gst/1.10/gst-plugins-base/gst-libs/gst/fft/.libs:/home/rna/gst/1.10/gst-plugins-base/gst-libs/gst/audio/.libs:"
"/home/rna/gst/1.10/gst-plugins-base/gst-libs/gst/app/.libs:/home/rna/gst/1.10/gst-plugins-base/gst-libs/gst/allocators/.libs:"
"/home/rna/gst/1.10/gstreamer-vaapi/gst-libs/gst/vaapi/.libs:/home/rna/gst/1.10/gst-editing-services/ges/.libs:"
"/home/rna/gst/1.10/gst-rtsp-server/gst/rtsp-server/.libs:/home/rna/gst/1.10/orc/orc/.libs:/home/rna/gst/1.10/orc/orc-test/.libs:"
"/home/rna/gst/1.10/prefix/lib")
#gst = "./bin/gst-1.10"
script = "./gst_compare_{}.sh".format(args.side)
arguments = "5000 6000"
f = "/opt/rna/video/Sintel576.h264"
iface = "eth0"
host = "10.8.0.102"
if args.side == "sender":
arguments = "{} {} {} {}".format(host, arguments, f, iface)
sleep_time += 5
cmd = "{} {}".format(script, arguments)
try:
while True:
p = subprocess.Popen(cmd.split(" "), env=env)
time.sleep(sleep_time)
os.kill(p.pid, signal.SIGKILL)
except KeyboardInterrupt:
pass
if __name__ == "__main__":
main()
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment