Okay, let me try to be brief.VLC has a remote interface (well multiple ones). However they do not behave with *any* consistency. This is sort of a short version of what I've been through the past few weeks...
For standard rc, we'll connect to our local machine via port 1234. Now we'll issue some commands from the VLC documentation:
Code: Select all
$ echo "pause" | localhost 1234
-- Works, pause/play toggles
$ echo "seek +2" | localhost 1234
-- Works, no problems
$ echo "slower" | localhost 1234
-- FAILS
$ echo "faster" | localhost 1234
-- FAILS
$ echo "rate 0.5" | localhost 1234
-- Works, but completely UNDOCUMENTED
Well, okay maybe DBus is the way to go. Yeah, VLC support MPRIS, so that should be easy. I'm new to DBus but lemme give it a shot.
Code: Select all
$ dbus-send --print-reply --session --dest=org.mpris.MediaPlayer2.vlc /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.PlayPause
-- Works, yaay. Cool
$ dbus-send --print-reply --session --dest=org.mpris.MediaPlayer2.vlc /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Seek int64:"-10000000"
-- Works, yay. Cool
$ dbus-send --print-reply --session --dest=org.mpris.MediaPlayer2.vlc /org/mpris/MediaPlayer2 org.mpris.MediaPlayer2.Player.Rate double:"0.5"
-- FAIL. Method "Rate" with signature "d" on interface "org.mpris.MediaPlayer2.Player" doesn't exist
Now we'll try using UNIX sockets. It is cleaner than the telnet method and make more sense for a local remote in any case (although DBus seemed the *best* solution). In this case /tmp/vlc.sock will be the socket to create.
Code: Select all
$ echo "pause" | nc.openbsd -U /tmp/vlc.sock
-- Works, no errors. Yay, good.
$ echo "rate 0.5" | nc.openbsd -U /tmp/vlc.sock
-- FAIL, Unknown command. Lol, GTFO user.
$ echo "slower" | nc.openbsd -U /tmp/vlc.sock
-- Works, no errors, WTH dude?
In conclusion...
Commands, Documentation
Rate:
Dbus(y), Telnet(n), UNIX Socket(n)
Faster/Slower:
Dbus(n), Telnet(y), UNIX Socket(y)
Commands, Reality
Rate:
Dbus(n), Telnet(n), UNIX Socket(n)
Faster/Slower:
Dbus(n), Telnet(n), UNIX Socket(y)
"Reality is string than Documentation" -- nonzyro.
So, that's my report. Don't know what to suggest. Changing the documentation would be easier, but changing the code would probably be for the best. The code need only have functionality added, nothing removed so that compatibility would be maintained.