diff options
author | Stephane Desneux <stephane.desneux@open.eurogiciel.org> | 2015-02-27 18:31:20 +0100 |
---|---|---|
committer | Stephane Desneux <stephane.desneux@open.eurogiciel.org> | 2015-02-27 18:31:20 +0100 |
commit | e17967a3e09f89ec7621ec8f50b8cce41f1cff85 (patch) | |
tree | 8d9168921976ae754955b78a06459e5273ed3aba /Script | |
parent | 2f3deede9240f192b540266a923b98425d072f92 (diff) | |
download | desktop-skin-e17967a3e09f89ec7621ec8f50b8cce41f1cff85.tar.gz desktop-skin-e17967a3e09f89ec7621ec8f50b8cce41f1cff85.tar.bz2 desktop-skin-e17967a3e09f89ec7621ec8f50b8cce41f1cff85.zip |
video scripts: replace playbin by custom pipelinesubmit/tizen_common/20150227.173449submit/tizen_3.0.2014.q4_common/20150227.173534accepted/tizen/common/20150227.173611accepted/tizen/3.0.2014.q4/common/20150227.173718
playbin doesn't work well in some situations. Typically when
running on a full HD screen, the video is not scaled to full screen. Also, sometimes,
videos do not play at all, depending on hardware (fails to run on NUC E3815)
Change-Id: Ic8f3f2ad725041dd7559cfdb6098cdc0625313ed
Signed-off-by: Stephane Desneux <stephane.desneux@open.eurogiciel.org>
Diffstat (limited to 'Script')
-rwxr-xr-x | Script/launch_video.sh | 17 | ||||
-rwxr-xr-x | Script/launch_video2.sh | 17 |
2 files changed, 22 insertions, 12 deletions
diff --git a/Script/launch_video.sh b/Script/launch_video.sh index 5b1293b..8c64aaa 100755 --- a/Script/launch_video.sh +++ b/Script/launch_video.sh @@ -4,18 +4,23 @@ # Launch web cam # -touch $HOME/gstvid-pid -alreadyrunning=`cat $HOME/gstvid-pid` +pidfile=$HOME/.gstvid-pid -URL=file:///usr/share/media/videos/AmazingNature_480p.mp4 +touch $pidfile +alreadyrunning=`cat $pidfile` + +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 & - echo $! >> $HOME/gstvid-pid + #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 & + echo $! >> $pidfile else echo "already running" for x in $alreadyrunning; do kill -9 $x; done - rm -rf $HOME/gstvid-pid + rm -rf $pidfile fi diff --git a/Script/launch_video2.sh b/Script/launch_video2.sh index 017fb0a..6402784 100755 --- a/Script/launch_video2.sh +++ b/Script/launch_video2.sh @@ -4,18 +4,23 @@ # Launch web cam # -touch $HOME/gstvid-pid -alreadyrunning=`cat $HOME/gstvid-pid` +pidfile=$HOME/.gstvid2-pid -URL=file:///usr/share/media/videos/Caminandes_1080p.mp4 +touch $pidfile +alreadyrunning=`cat $pidfile` + +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 & - echo $! >> $HOME/gstvid-pid + #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 & + echo $! >> $pidfile else echo "already running" for x in $alreadyrunning; do kill -9 $x; done - rm -rf $HOME/gstvid-pid + rm -rf $pidfile fi |