[MPlayer-users] Slave mode does not expand properties

Erik Steffl erik at zasran.com
Fri Dec 26 10:59:44 CET 2014


Trying to get mplayer to print out the currently playing file but the 
property is always empty.

Following instruction at http://www.mplayerhq.hu/DOCS/tech/slave.txt, 
created the fifo and sending command to fifo.

This is how the command is sent to mplayer (while a video is playing):

echo 'run "echo filename ${filename} stream_pos ${stream_pos}" >> 
/tmp/mplayer.output.txt' > /tmp/mplayer.slave.fifo

Which is basically the same as the example in the doc (only added extra 
strings so that I see that run was actually executed).

There are two problems there:

   - none of the properties are expanded to actual values, i.e. both 
${filename} and ${stream_pos} are replaced by empty string in the output

   - the output of run is not redirected to a file but it's instead 
printed to stdout and mixed with info other info mplayer is prineting 
out while playing the video, here's what it looks like (send the run 
command twice):

A: 200.3 V: 200.3 A-V: -0.001 ct:  0.001   0/  0 17%  6%  1.2% 207 0
filename stream_pos-V:  0.067 ct:  0.002   0/  0 17%  6%  1.2% 213 0
filename stream_pos-V: -0.001 ct:  0.002   0/  0 17%  6%  1.2% 218 0
A: 262.5 V: 262.5 A-V:  0.003 ct:  0.001   0/  0 17%  6%  1.2% 221 0

The 'filename' and 'stream_pos' strings are printed but there's nothing 
where the actual filename and stream posaition should be.

This is while using:

Ubuntu 14.10
mplayer2 2.0-728-g2c378c7-2ubuntu

Any ideas what's going on?

   thanks!

	erik


More information about the MPlayer-users mailing list