1
1
mirror of https://github.com/ytdl-org/youtube-dl synced 2024-12-04 09:42:59 +01:00

Changed m3u8 format handling

This commit is contained in:
DataGhost 2022-05-30 11:39:50 +02:00
parent bb4d3baa67
commit 71e630eebf

View File

@ -3,6 +3,7 @@ from __future__ import unicode_literals
from .common import InfoExtractor from .common import InfoExtractor
from ..utils import ( from ..utils import (
determine_ext,
int_or_none, int_or_none,
qualities, qualities,
) )
@ -65,12 +66,17 @@ class DumpertIE(InfoExtractor):
if not uri: if not uri:
continue continue
version = variant.get('version') version = variant.get('version')
formats.append({ ext = determine_ext(uri)
'url': uri, if ext == 'm3u8':
'format_id': version, formats.extend(self._extract_m3u8_formats(
'quality': quality(version), uri, video_id, ext='mp4', m3u8_id=format_id))
'ext': 'mp4', else:
}) formats.append({
'url': uri,
'format_id': version,
})
for format in formats:
format['quality'] = quality(format['format_id'])
self._sort_formats(formats) self._sort_formats(formats)
thumbnails = [] thumbnails = []