aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl
diff options
context:
space:
mode:
authorSergey M․ <dstftw@gmail.com>2016-11-04 21:45:24 +0700
committerSergey M․ <dstftw@gmail.com>2016-11-04 21:45:24 +0700
commit640aff1d0c3d008f1286bb49b559938a7b5cd65a (patch)
treec3977580f2dfca155f44ec6201ae5b57b0a7011d /youtube_dl
parentc897af8aacae08852c70fbcec9fa6c42e6e278f7 (diff)
[anvato] Improve formats extraction
Diffstat (limited to 'youtube_dl')
-rw-r--r--youtube_dl/extractor/anvato.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/youtube_dl/extractor/anvato.py b/youtube_dl/extractor/anvato.py
index 46ca1899e..623f44dce 100644
--- a/youtube_dl/extractor/anvato.py
+++ b/youtube_dl/extractor/anvato.py
@@ -163,9 +163,10 @@ class AnvatoIE(InfoExtractor):
formats = []
for published_url in video_data['published_urls']:
video_url = published_url['embed_url']
+ media_format = published_url.get('format')
ext = determine_ext(video_url)
- if ext == 'smil':
+ if ext == 'smil' or media_format == 'smil':
formats.extend(self._extract_smil_formats(video_url, video_id))
continue
@@ -176,7 +177,7 @@ class AnvatoIE(InfoExtractor):
'tbr': tbr if tbr != 0 else None,
}
- if ext == 'm3u8':
+ if ext == 'm3u8' or media_format in ('m3u8', 'm3u8-variant'):
# Not using _extract_m3u8_formats here as individual media
# playlists are also included in published_urls.
if tbr is None:
@@ -187,7 +188,7 @@ class AnvatoIE(InfoExtractor):
'format_id': '-'.join(filter(None, ['hls', compat_str(tbr)])),
'ext': 'mp4',
})
- elif ext == 'mp3':
+ elif ext == 'mp3' or media_format == 'mp3':
a_format['vcodec'] = 'none'
else:
a_format.update({