aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl
diff options
context:
space:
mode:
authorSergey M․ <dstftw@gmail.com>2015-06-27 00:41:26 +0600
committerSergey M․ <dstftw@gmail.com>2015-06-27 00:41:26 +0600
commit1b5a1ae257c6d64fd69ea91eaf69328d4b6d17df (patch)
treed3f7ddb924d408d63f5d2089eaea378e45617b3a /youtube_dl
parent2988835af5cbe695e61d3b58bc65027f5b48fb63 (diff)
[youtube] Pick up codecs info from DASH manifest when not set explicitly
Diffstat (limited to 'youtube_dl')
-rw-r--r--youtube_dl/extractor/youtube.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/youtube_dl/extractor/youtube.py b/youtube_dl/extractor/youtube.py
index a3da56c14..c9d8e5125 100644
--- a/youtube_dl/extractor/youtube.py
+++ b/youtube_dl/extractor/youtube.py
@@ -824,6 +824,12 @@ class YoutubeIE(YoutubeBaseInfoExtractor):
except StopIteration:
full_info = self._formats.get(format_id, {}).copy()
full_info.update(f)
+ codecs = r.attrib.get('codecs')
+ if codecs:
+ if full_info.get('acodec') == 'none' and 'vcodec' not in full_info:
+ full_info['vcodec'] = codecs
+ elif full_info.get('vcodec') == 'none' and 'acodec' not in full_info:
+ full_info['acodec'] = codecs
formats.append(full_info)
else:
existing_format.update(f)