I have two videos and need to play them (by mplayer) exactly at the same time. How to do that ?
Start up multiple background tasks. This means that the second one does not need to wait for the first one to finish loading. The
& tell the command to run in the background.
From the command-line: In the first one, the number of
. (dots) equals the number of instances.
set "/my/vid/path.mp4" for i in . . ;do (mplayer "$1" &) ;done
set "/my/vid/path.mp4"; ( mplayer "$1" & mplayer "$1" & )
( mplayer "/my/vid/path.mp4" & mplayer "/my/vid/path.mp4" & )
Or in a script called by
#!/bin/bash mplayer "$1" & mplayer "$1" &
In your particular case:
parallel mplayer ::: file1.avi file2.avi