3

Before I start re-encoding a bunch of video files into a single one... Is there a way to create a playlist, in any format supported by either Mplayer or VLC (or both), which instructs the player to pause for N seconds before moving on to the next video file?

Ideally:

  • no extra video artefacts, such as black video sequences, should be used;
  • player-specific tricks are OK, but no programming please;
  • OS-specific scripting should be avoided;
  • playing the whole list should be gap-less: during a pause the player should stream black frames.

For those needing a reason before doing anything: this is to spare the lazy operator the tedious task of watching a screening of many short films ;-)

sphakka
  • 457
  • 4
  • 11

2 Answers2

0

You could put all of your files into a common folder, fire up the terminal, cd to it, and execute:

for v in *; do mpv "$v"; clear; sleep 5; done

Notes:

  • Make sure the folder contains only videos. Otherwise it will try to play sounds, and other files.
  • You can replace mpv with mplayer, vlc or whichever player you prefer.
  • clear is optional: it just clears out the verbosity that could scare your audience.
octosquidopus
  • 3,517
  • 8
  • 35
  • 53
  • That'd be way too easy ;-) Actually, it's not OS independent, and doesn't play gap-less: the public would see a fastidious context switch between film streaming and window manager/shell background. As for gap-less playback, though still with no pause, I discovered that VLC does a good job, whereas Mplayer needs some workaround based on FIFOs as [proposed here for audio playing](http://www.debianuserforums.org/viewtopic.php?f=9&t=1347&sid=6bcc01779849cc25db475725b0f05350) – sphakka Dec 05 '14 at 11:03
  • Right. What if you added a black video between your videos in your playlist to simulate pauses? – octosquidopus Dec 05 '14 at 13:17
  • That was indeed my first idea of a workaround! It looks like there's no other (easy) way of sorting this out, so I'll post another Q/A about generating black video content, then will come back here. – sphakka Dec 12 '14 at 11:27
  • @sphakka Let me know where you posted it, and I'll try to help you out. – octosquidopus Dec 12 '14 at 12:33
0

did you manage to solve your issue solely within mplayer? I have a similar question, but not video, just audio, and I did not find the option for adding pause after playback, so resorted to:

  • create an empty 3s audio file,
  • insert it in the playback list between every real file,
  • mplayer the list.

in practice:

sox -n -r 44100 -c 2 silence.wav trim 0.0 3.0
mplayer $(for i in 02[1-9]*.mp3; do echo $i silence.wav; done)

I am aware this is os-dependent. I prefer this to the for loop because this way I only have a single mplayer invocation, so I can set volume, and move back and forth among chapters.

mariotomo
  • 9,438
  • 8
  • 47
  • 66