Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I change my VLC playback speed fine grain in real time?

I am doing research where participants run on a treadmill and I project a video of a trail in front of them. What I am attempting to do is change the speed of the video in relation to the participant changing their speed on the treadmill. I've seen the GUI has options for fine grain control of the video as it is playing, but I can't seem to replicate it using the command-line options. I can either play the video at a fixed fine grain speed (i.e. 1.23x) or I can change it real time in large increments via the rc interface (faster 1.5x, 2.0x). The solution can be any version of VLC compatible with windows XP or Cygwin. Ultimately I would like to script the process so I won't be changing the speeds manually. Thank you so much!

like image 593
James Kent Avatar asked Nov 03 '22 18:11

James Kent


1 Answers

You can experiment with the MPlayer slave mode.

To try slave mode run:

mplayer -slave -quiet <movie>

and type slave commands into the console.

You can also use a named pipe:

mkfifo /tmp/fifofile
mplayer -slave -input file=/tmp/fifofile movie.avi

You can try these slave mode commands:

speed_incr <value>
    Add <value> to the current playback speed.

speed_mult <value>
    Multiply the current speed by <value>.

speed_set <value>
    Set the speed to <value>.

You can visit the MPlayer documentation for more information.

like image 146
Antonio Bardazzi Avatar answered Nov 14 '22 01:11

Antonio Bardazzi