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

Progress report for HLS downloader #78

Closed
codeasashu opened this issue Feb 13, 2016 · 5 comments
Closed

Progress report for HLS downloader #78

codeasashu opened this issue Feb 13, 2016 · 5 comments

Comments

@codeasashu
Copy link

I would love if we can get a progress report on streaming urls (for ex- http://hotstar.com/1000000554). Looks like ffmpeg output isn't piped to stdout. I have tried but failed to get frame report. I tried outputting stdout and stderr both didn't pointed out any frame report. Here is what I did at:
here

if stdout:
                print stdout #just to know standard output for a moment
                data_dict = extract_data(stdout)
                self._extract_info(data_dict)
                self._hook_data(data_dict)

and here

for line in iter(self._filedescriptor.readline, ''):
                    print line #to get standard error from console
                    # Ignore ffmpeg stderr
                    if str('ffmpeg version') in line:
                        ignore_line = True

                    if not ignore_line:
                        self._queue.put_nowait(line)

While I use the command: youtube-dl --newline -i -o C:\\Users\\Username\\%(title)s.%(ext)s http://hotstar.com/1000000554 in command prompt(I am using windows), I get following frame output (using ffmpeg version N-78355-g020b758) -
frameop

I am unable to get this stdout when using youtube-dlg via console. Can someone point me in some direction?

@codeasashu
Copy link
Author

I checked and found youtube-dl didn't output ffmpeg to console (which again outputs to stderr pipe, this explains the reason of framelines going to PipeReader).
I've made a pull request which now enables us to get progress.

@MrS0m30n3
Copy link
Owner

Hi @ashutosh2k12

Hotstar uses the HLS downloader which uses ffmpeg to download the video. Now the ffmpeg output gets written in stderr, if you want to see this output add the print statement in downloaders.py line 60 and change line 62 to False then you should be able to see the output from ffmpeg.

I am also planning to use both stderr & stdout (not only stdout like i do now) to extract data but its not high in my priorities.
If you want to see more stats about the download process when using the HLS downloader you can
you the native HLS downloader. Go to Options>Commands tab and add the --hls-prefer-native option.

Also you can read issue #49

@MrS0m30n3 MrS0m30n3 reopened this Feb 14, 2016
@MrS0m30n3
Copy link
Owner

We could extract those informations directly on the youtube-dl-gui side as i said in my previous post.
Anyway, leave this issue open because i will most likely need to add support on the youtube-dl-gui extractor after your pull request gets merged into the youtube-dl repo.

@MrS0m30n3 MrS0m30n3 changed the title Progress report for streaming videos Progress report for HLS downloader Feb 14, 2016
@MrS0m30n3
Copy link
Owner

@ashutosh2k12 Any news from the pull-request on the youtube-dl repo?

@MrS0m30n3
Copy link
Owner

@ashutosh2k12

Closing, you can reopen this issue when your pull request on the youtube-dl repo gets merged.

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

No branches or pull requests

2 participants