Skip to content
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

VODs support #81

Open
Mangos02 opened this issue May 1, 2015 · 23 comments
Open

VODs support #81

Mangos02 opened this issue May 1, 2015 · 23 comments

Comments

@Mangos02
Copy link

Mangos02 commented May 1, 2015

or is its already being worked on?

@Mangos02 Mangos02 changed the title Anyway to impement VODS support? Anyway to implement VODS support? May 1, 2015
@bastimeyer
Copy link
Member

Livestreamer's support for twitch VODs is pretty poor, that's why I've been dodging the VODs for a while now.

When watching twitch VODs with livestreamer, you're unable to jump to different positions in the video, unless you choose HLS as stream type. This means that you always have to watch the video from the beginning. But choosing HLS as stream type isn't ideal, since it doesn't work well with the GUI (the livestreamer child process basically just passes through the twitch HLS playlist to the player which leads to some unintended behavior).

I'm planning on implementing the stream download feature first, so VODs can then be downloaded as well. This should be better than streaming the whole video anyway, I guess.

@deetari
Copy link

deetari commented May 9, 2015

It's not ideal, but if I really want to watch VODs from Livestreamer, I usually jump around by passing Livestreamer the timestamp (ie: [vod link]?t=1h2m3s) I want to go to. Didn't expect it to work the first time, but I suppose that shows how little I know of how streaming works. :P

@skulblakka
Copy link

jump around by passing Livestreamer the timestamp

If I remember correctly this only works on certain VODs as Twitch has different implementations of their VOD feature (I think there are flv and hls based implementations and passing the time only works on the flv ones)

@bastimeyer
Copy link
Member

I usually jump around by passing Livestreamer the timestamp (ie: [vod link]?t=1h2m3s)

Sure, you could do that, but this would also mean that you have to launch the VOD multiple times if you want to jump back to an earlier position in the video.

@Mangos02
Copy link
Author

if i let my VLC handle the caching with --player-passthrough hls then i can click on the time bar where i want the stream to jump too and it works. though the time bar doesnt show the actual time or even move after you selected the time

@bastimeyer bastimeyer changed the title Anyway to implement VODS support? VODs support May 19, 2015
@stefanw1337
Copy link

I'd also like a VOD-feature in this, else I will have to open browser and flash again. Now that Twitch has announced they will switch to HTML5 that problem might not be around anymore, anyway..

@petden
Copy link

petden commented Jan 16, 2016

For VODs use MPC-HC and HLS. It completely fixes the time bar; it shows the length of the VOD and the time if you hover over the time bar. http://i.imgur.com/YbnEmjR.png . It works great, I use it all the time to watch VODs. Would be nice to see VODs in the GUI, I don't watch livestreams, I only watch VODs.

@michaelowens
Copy link

Would love to see this implemented too. HLS works well enough in VLC too, I can skip or go back without issues, it just doesn't show the time like MPC-HC.

@mikeparadinas
Copy link

ditto, livestreamer does support twitch VODs, but its outside the provided twitch API to easily load you a list of all the VODs.

@matt81093
Copy link

I know that a download feature was planned on being done before vod support, but I was wondering if it's become more phesable with changes with twitch and livestreamer since you said that @bastimeyer

Just a penny for your thoughts.

@yash1610
Copy link

yash1610 commented Jul 5, 2016

I'd like to voice my interest in this. Also just to put it out there Baka-mplayer(front-end for mpv) using youtube-dl allows jumping to different time-positions in the twitch VODs

@njibhu
Copy link

njibhu commented Aug 25, 2016

Livestreamer cli also have "support" for pasts broadcasts (and using the --player-passthrough hls you can jump in time too.. ) Would love to see it implemented in livestreamer-twitch-gui... I think having a new view accessible using a button on the channel preview with a simple list of pasts broadcasts is enough and that would be so great !

@i-cant-git
Copy link

I support this, I'd like to watch streamers' past videos when they are not streaming / online.

@bastimeyer
Copy link
Member

bastimeyer commented Dec 8, 2016

I'm getting a lot of questions recently regarding this feature and it's been a while since my last answer, so let me give you an up to date (basically the same) answer, why this hasn't been added yet.

The Twitch VODs/clips feature still can't be added without major flaws because of the current implementation of Streamlink (and Livestreamer).
Videoplayers are unable to jump to different positions in the video stream, which makes the whole idea of viewing past broadcasts or highlights pointless. To be able to seek in the video, the --player-passthrough hls parameter can be used, but by doing this, Streamlink's internal "streaming proxy-server" is being bypassed and the URL of the "video file" is just being handed over to the player. This means that all stream fetching/buffering configurations of Streamlink will be ignored and the player itself has to do all this instead. There are also some players that simply don't support the HLS protocol. It would be a pretty terrible idea to add Twitch VODs in this current state.

There are good news, though:
Now that this project has moved to Streamlink, upstream development is happening again. There are already plans for improving/changing the "VOD support". See streamlink/streamlink#134 and related threads on the main repo. A Twitch VOD/clip feature will be implemented once we have better support for it.

@Ethan-BB
Copy link

Ethan-BB commented Dec 17, 2016

For people interested in playing VODs, I made myself little script for playing them in AutoHotkey.
It does what bastimeyer said, it uses StreamLink to obtain playlist and simply passes it to MPC-HC, as it's the only player capable of scrubbing. Don't forget to change the location to where your MPC-HC is.

Code:

InputBox, vodUrl, VOD Launcher, Please enter the URL of Twitch VOD you want to play:`n(Can't be currently live), , 360, 140, , , , , https://www.twitch.tv/...
if ErrorLevel
    Exit

InputBox, vodQuality, VOD Launcher, Please enter quality setting:`nAudio`, Mobile (worst)`, Low`, Medium`, High`, Source (best), , 360, 140, , , , , Source
if ErrorLevel
    Exit

Run bin\streamlink.exe --player-passthrough hls --player "D:\Programs\MPC-HC\mpc-hc64.exe" %vodUrl% %vodQuality%

@ProfPh
Copy link

ProfPh commented Apr 15, 2017

Batch file version for watching VODs with streamlink in the best available quality:

set /p vodURL=Enter a twitch.tv VOD URL:
"C:\Program Files (x86)\Streamlink\bin\streamlink.exe" --player-passthrough hls --player "C:\Program Files\VideoLAN\VLC\vlc.exe" %vodURL% best

@bastimeyer
Copy link
Member

Please stop posting your Streamlink wrapper scripts. This is unrelated to Streamlink Twitch GUI.
If you want to watch Twitch VODs, please see the Streamlink CLI documentation on the Streamlink website. I have already commented on why there is no VOD support integrated into the Twitch GUI yet. If you have questions regarding the CLI usage, please go to the Streamlink repo. Thanks.

@stefanw1337
Copy link

stefanw1337 commented Apr 18, 2017

Now that Twitch and Curse is making their own Twitch app(currently missing a VoD feature or any proper "following" streaming, but it's also just in beta), I see that this service(streamlink) won't be as good or that it will further survive this.

@bastimeyer
Copy link
Member

The goal isn't and has never been being feature-equal with any products of Twitch. I don't care if there is competition from the official side now with another "desktop app".

Streamlink and Streamlink Twitch GUI work completely different than the official Twitch/Curse app. Both still serve their purpose and will also do so in the future.

If you're desperately missing a VOD feature in the Twitch GUI, you're welcome to integrate it yourself. This is an open source project. Even if you don't want to do this, you can still use the Streamlink CLI and watch VODs this way by bypassing streamlink and using the passthrough option.

I have talked about this multiple times now why I haven't integrated this into the Twitch GUI yet.

@stefanw1337
Copy link

Well, I think you're partially wrong. Because as mentioned the Twitch app is in beta, and there's several features missing, that they will implement. Which will be a better "following" for viewing streams as well as VOD support in the future. Which makes this project obsolete, I think? So I don't get why you think there won't be a competition on the features those programs will have?

And I'm not interested in working on the project, since Twitch seems to be making exactly this.

@bastimeyer
Copy link
Member

Why are you commenting here in this thread? If you think that this projects is becoming obsolete, just use the offical app if it suits your needs better. It's as simple as that.

What you don't seem to understand is that Streamlink Twitch GUI has started as a personal open source project (Livestreamer Twitch GUI back then) and basically still is. I am the only person developing it without being paid for all my work and rely on Streamlink and its capabilities of playing Twitch's live streams (and VODs/clips if they would properly). The idea has always been to allow people to browse Twitch streams while being able to watch them in their not so resource heavy local video player instead their web browser.

The offical app on the other hand is being developed by multiple people who are being paid for their job. They have a completely different goal with their app and use the same technology that is being used on the website, which means that you basically don't have any advantage while using it in the sense of watching streams. In addition to that, it's not open source software and (presumably) infested with data trackers, etc. I'm not talking about ads, though.

Btw, this thread is still about a future VOD implementation in this application.
I'm going to lock this thread if more unrelated stuff gets posted. It is unnecessary noise.

@DoctorVanGogh
Copy link

Stupid question:

A simple youtube-dl -g [-f YourQuality] <VODURL> => Use resulting URL and "Open Network stream" in VLC will get you the VOD.

So wouldn't something like that work as a stopgap kind of implementation?

@bastimeyer
Copy link
Member

@DoctorVanGogh This is unrelated to Streamlink and the Twitch GUI and is basically the same as using Streamlink's --player-passthrough=hls parameter or its --stream-url parameter and using it as the player's input URL.

https://streamlink.github.io/cli.html#cmdoption-player-passthrough
https://streamlink.github.io/cli.html#cmdoption-stream-url

I'm going to lock the thread for now, as I've said in my previous post. Here's a "TL;DR":

  • Yes, you can watch VODs by using the Streamlink CLI.
    streamlink URL best
    Result: non-seekable VODs that always start at the beginning
  • Yes, you can pass through the VOD's HLS URL to your player by using the Streamlink CLI:
    streamlink --player-passthrough=hls URL best
    Result: seekable VODs, but buffering and caching is done by the player, which also has to support HLS
  • Yes, you can download VODs by using the Streamlink CLI:
    streamlink -o file.ts URL best
    Result: downloads VODs from the beginning while being unable to watch at the same time (there's a PR on the Streamlink repo to add simultaneous downloading and watching functionality)
  • No, passing though VOD HLS URLs to the player from the Twitch GUI is a bad idea because it bypasses Streamlink and its own buffering mechanism and player instances can't get killed from the GUI, because of Streamlink's hls passthrough logic and the detached player process.
  • No, ignoring these issues is a bad idea, because always watching VODs from the beginning and being unable to seek is a bad user experience.
  • No, this project does not and has never aimed at being feature equal to any kind of product of Twitch. If there is something missing, you're free to contribute to this open source project and you're also free to support its creators/contributors.

So what is blocking the VODs implementation then?
A rewrite of Streamlink's proxying logic, as mentioned/suggested in streamlink/streamlink#134. Streamlink has to act as a HLS proxy server, so that players are able to seek, but their requests are sent to Streamlink's proxy server instead of directly to the Twitch servers.

Here is the issue tracker of Streamlink itself:
https://github.com/streamlink/streamlink/issues?utf8=✓&q=twitch

@streamlink streamlink locked and limited conversation to collaborators Jul 11, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests