New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Passing --config to VLC #218

Closed
akanimh opened this Issue Nov 14, 2013 · 4 comments

Comments

Projects
None yet
2 participants
@akanimh

akanimh commented Nov 14, 2013

I am trying to pass an argument to VLC to allow it to pull a specific vlcrc file for each instance of VLC that is opened by LiveStreamer. Here's as far as I've currently gotten:

livestreamer "rtmp://xx.xxx.xx.xx/live/livestream live=1" best -a "--config C:\Users\Me\Desktop\vlcrc"

The --config parameter is supposed to allow VLC to run using the designated vlcrc file. But when this is entered in, it opens the stream in VLC, doesnt use the config, and the stream does not play. Am I perhaps doing this wrong?

Technically the only reason we're trying to do this, is so we can pass a custom window title for each instance of VLC we open with livestreamer.

In vlcrc:

# Change title according to current media (string)
#input-title-format=$z (Change this to whatever title you need)

Since there doesnt seem to be a way to pass a filename through livestreamer to VLC, You only ever get fd://0 in the title. We need each VLC window to have its own title.

@chrippa

This comment has been minimized.

Show comment
Hide comment
@chrippa

chrippa Nov 14, 2013

Owner

You need to have a {filename} in your -a argument for playback to work, try -a "--config C:\Users\Me\Desktop\vlcrc {filename}".

Also, you need to remove the pound sign (#) from your vlcrc or it will be counted as a comment.

Owner

chrippa commented Nov 14, 2013

You need to have a {filename} in your -a argument for playback to work, try -a "--config C:\Users\Me\Desktop\vlcrc {filename}".

Also, you need to remove the pound sign (#) from your vlcrc or it will be counted as a comment.

@akanimh

This comment has been minimized.

Show comment
Hide comment
@akanimh

akanimh Nov 14, 2013

Got it working with this:

livestreamer "rtmp://xx.xxx.xx.xxx/live/livestream live=1" best -a "--config 1 {filename}"

Not sure if this is intended, but I ditched the directory info, because it just created a renamed vlcrc file in the livestreamer directory called UsersMeDesktopvlcrc and VLC used that. Changed it to just name it '1', which allowed me to edit '1'. Then removing the hash and it pulled in my custom title. We can now create multiple vlcrc config files and call them through livestreamer.

Thanks a bunch, this is exactly what we needed.

akanimh commented Nov 14, 2013

Got it working with this:

livestreamer "rtmp://xx.xxx.xx.xxx/live/livestream live=1" best -a "--config 1 {filename}"

Not sure if this is intended, but I ditched the directory info, because it just created a renamed vlcrc file in the livestreamer directory called UsersMeDesktopvlcrc and VLC used that. Changed it to just name it '1', which allowed me to edit '1'. Then removing the hash and it pulled in my custom title. We can now create multiple vlcrc config files and call them through livestreamer.

Thanks a bunch, this is exactly what we needed.

@chrippa

This comment has been minimized.

Show comment
Hide comment
@chrippa

chrippa Nov 14, 2013

Owner

Not sure if this is intended, but I ditched the directory info, because it just created a renamed vlcrc file in the livestreamer directory called UsersMeDesktopvlcrc and VLC used that.

This is a bug. It's caused by shlex removing bash-slashes that are not escaped. I fixed it for the --player option but forgot to also do it on --player-args it seems.

Owner

chrippa commented Nov 14, 2013

Not sure if this is intended, but I ditched the directory info, because it just created a renamed vlcrc file in the livestreamer directory called UsersMeDesktopvlcrc and VLC used that.

This is a bug. It's caused by shlex removing bash-slashes that are not escaped. I fixed it for the --player option but forgot to also do it on --player-args it seems.

@akanimh

This comment has been minimized.

Show comment
Hide comment
@akanimh

akanimh Nov 15, 2013

Okay no problem, glad I could help a little. Thankfully it doesnt matter to us where the customized vlcrc files are stored, so this works just fine as is.

akanimh commented Nov 15, 2013

Okay no problem, glad I could help a little. Thankfully it doesnt matter to us where the customized vlcrc files are stored, so this works just fine as is.

@chrippa chrippa closed this in ed40325 Nov 15, 2013

javiercantero pushed a commit to javiercantero/livestreamer that referenced this issue Jan 7, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment