Browse Source

downloaders.py: Extractor: Add support for native hls

doc-issue-template
MrS0m30n3 9 years ago
parent
commit
e884eac937
1 changed files with 13 additions and 0 deletions
  1. 13
      youtube_dl_gui/downloaders.py

13
youtube_dl_gui/downloaders.py

@ -420,6 +420,19 @@ def extract_data(stdout):
if stdout[-1] == 'Aborting.':
data_dictionary['status'] = 'Filesize Abort'
elif stdout[0] == '[hlsnative]':
# native hls extractor
# see: https://github.com/rg3/youtube-dl/blob/master/youtube_dl/downloader/hls.py#L54
data_dictionary['status'] = 'Downloading'
if len(stdout) == 7:
segment_no = float(stdout[6])
current_segment = float(stdout[4])
# Get the percentage
percent = '{0:.1f}%'.format(current_segment / segment_no * 100)
data_dictionary['percent'] = percent
elif stdout[0] == '[ffmpeg]':
data_dictionary['status'] = 'Post Processing'

Loading…
Cancel
Save