Page 1 of 1

Remote access to playlist

Posted: 11 Jan 2014 13:30
by Mirality
Not sure if this is the right place to ask, but none of the other subforums seemed quite right either.

I'm currently using VLC on Windows (just the standard download, not building it myself).

I want to write an application external to VLC itself that can access its playlist (previous, current, next, and entire ordered list of items) -- just in a read-only fashion, and obtaining the filename alone is sufficient information.

Is there an existing method to do this using built-in functionality, or am I going to have to write some kind of plugin to export this information to my application? (The external app will most likely be written in either C++ or C#, but I haven't started on it yet so it's still flexible.)

For context, the basic idea is that I want to use a database outside of VLC and the media files themselves to track some additional metadata about each video in the playlist (and it has to be able to cope properly with the playlist being rearranged). Viewing/editing the metadata could potentially either be done directly in the external app or via some sort of playlist plugin in VLC, whichever seems easier. But either way I'll also probably want to be able to fetch the metadata for current/previous items from a third application via Python. (This is an optional extension though.)

If you can point to some kind of similar example code as well, that would be appreciated. :)

Re: Remote access to playlist

Posted: 11 Jan 2014 17:57
by Jean-Baptiste Kempf

Re: Remote access to playlist

Posted: 12 Jan 2014 13:47
by Mirality
Well, that looks like it might be able to do what I want, but I'm not sure how to access it. (I'm using 2.1.2 x64.)

I went to Settings -> All -> Interface -> Main interfaces and ticked Web. I then tried to use the URLs shown in the examples but it didn't work.

I then discovered that apparently it defaults to port 8080, not 9090 as the examples show. I couldn't find anywhere in the settings GUI that can change this. I can probably live with 8080 but I'm curious where this option is if I ever do want to change it. (The wiki page shows a command line option, but this is not sufficient as I need it to work with a default launch.)

The next problem was that trying to access any of the pages at port 8080 just displayed an error page demanding that a password be set. I don't really see why this should be mandatory (this is a home network and I trust my firewall to prevent Random Internet People from controlling the player), but I set a password on Settings -> All -> Interface -> Main interfaces -> Lua.

Now it's prompting for a username and password but none of the usernames that I have tried appear to be acceptable. This does not appear to be documented on that page either.

Edit: ok, never mind -- apparently the correct response is to enter no username, just the password. Might be useful to add this to the wiki. (Also I'm still curious about the port number thing, and if it's possible to tell it to not bother about the password.) Thanks for the pointer, I'll give this a try.