summaryrefslogtreecommitdiff
path: root/Script
diff options
context:
space:
mode:
authorStephane Desneux <stephane.desneux@open.eurogiciel.org>2015-03-02 14:07:07 +0100
committerStephane Desneux <stephane.desneux@open.eurogiciel.org>2015-03-02 14:07:07 +0100
commit7c59e1de7c9ea52e468875bba1e7d612b1e4376d (patch)
tree1c0c2879db8f24cbb21d511293253e4d846285f7 /Script
parente17967a3e09f89ec7621ec8f50b8cce41f1cff85 (diff)
downloaddesktop-skin-7c59e1de7c9ea52e468875bba1e7d612b1e4376d.tar.gz
desktop-skin-7c59e1de7c9ea52e468875bba1e7d612b1e4376d.tar.bz2
desktop-skin-7c59e1de7c9ea52e468875bba1e7d612b1e4376d.zip
Change-Id: Ic0b318da3d14041a64209a4f176b174973a13e6c Signed-off-by: Stephane Desneux <stephane.desneux@open.eurogiciel.org>
Diffstat (limited to 'Script')
-rwxr-xr-xScript/launch_video.sh12
-rwxr-xr-xScript/launch_video2.sh12
2 files changed, 16 insertions, 8 deletions
diff --git a/Script/launch_video.sh b/Script/launch_video.sh
index 8c64aaa..8f15014 100755
--- a/Script/launch_video.sh
+++ b/Script/launch_video.sh
@@ -13,10 +13,14 @@ video=/usr/share/media/videos/AmazingNature_480p.mp4
if [ $(echo $alreadyrunning | wc -w) -lt 3 ] ; then
echo "create new"
- #gst-launch-1.0 playbin uri=$URL &
- gst-launch-1.0 filesrc location=$video ! qtdemux name=demux \
- demux.audio_0 ! queue ! decodebin ! audioconvert ! audioresample ! autoaudiosink \
- demux.video_0 ! queue ! vaapidecode ! vaapisink &
+ if gst-inspect-1.0 | grep ^vaapi &>/dev/null; then
+ gst-launch-1.0 filesrc location=$video ! qtdemux name=demux \
+ demux.audio_0 ! queue ! decodebin ! audioconvert ! audioresample ! autoaudiosink \
+ demux.video_0 ! queue ! vaapidecode ! vaapisink &
+ else
+ echo "Playing without VA-API"
+ gst-launch-1.0 playbin uri=file://$video video-sink=waylandsink &
+ fi
echo $! >> $pidfile
else echo "already running"
for x in $alreadyrunning; do kill -9 $x; done
diff --git a/Script/launch_video2.sh b/Script/launch_video2.sh
index 6402784..24d4107 100755
--- a/Script/launch_video2.sh
+++ b/Script/launch_video2.sh
@@ -13,10 +13,14 @@ video=/usr/share/media/videos/Caminandes_1080p.mp4
if [ $(echo $alreadyrunning | wc -w) -lt 1 ] ; then
echo "create new"
- #gst-launch-1.0 playbin uri=$URL &
- gst-launch-1.0 filesrc location=$video ! qtdemux name=demux \
- demux.audio_0 ! queue ! decodebin ! audioconvert ! audioresample ! autoaudiosink \
- demux.video_0 ! queue ! vaapidecode ! vaapisink fullscreen=1 &
+ if gst-inspect-1.0 | grep ^vaapi &>/dev/null; then
+ gst-launch-1.0 filesrc location=$video ! qtdemux name=demux \
+ demux.audio_0 ! queue ! decodebin ! audioconvert ! audioresample ! autoaudiosink \
+ demux.video_0 ! queue ! vaapidecode ! vaapisink fullscreen=1 &
+ else
+ echo "Playing without VA-API"
+ gst-launch-1.0 playbin uri=file://$video video-sink=waylandsink &
+ fi
echo $! >> $pidfile
else echo "already running"
for x in $alreadyrunning; do kill -9 $x; done