[MPlayer-users] Re: video out on two screens

Ulrich Schweitzer us- at gmx.de
Fri Dec 3 18:50:06 CET 2004


On Wednesday 01 December 2004 23:07, Andrey Khavryuchenko wrote:

> #!/bin/sh
>
> pid=$$
>
> cd /tmp
> mkdir $pid
> cd $pid
>
> mkfifo stream.yuv
> mkfifo mp1
> mkfifo mp2
>
> (cat stream.yuv | tee mp1 > mp2 ) &
> mplayer -nocache -quiet -vo x11 mp1 &
> mplayer -nocache -quiet -vo x11 mp2 &
> mplayer -nocache -vo yuv4mpeg $*
>
> cd ..
> rm -rf $pid

Doesn't this fail if you specify no path or a relative path to the file 
you want to play?

I'd suggest something like that instead:

#!/bin/sh

path=/tmp/$$

mkdir $path

mkfifo $path/stream.yuv
mkfifo $path/mp1
mkfifo $path/mp2

(cat $path/stream.yuv | tee $path/mp1 > $path/mp2 ) &
mplayer -nocache -quiet -vo x11 $path/mp1 & 
mplayer -nocache -quiet -vo x11 $path/mp2 &
mplayer -nocache -vo yuv4mpeg $*

rm -rf $path

Ulrich
-- 
PGP key ID: 0xDF6FC4FA

"A mouse is a device used to select the xterm you want to type in."
Author unknown




More information about the MPlayer-users mailing list