Add --hls-prefer-ffmpeg

This commit is contained in:
Sergey M․
2016-04-21 23:02:17 +06:00
parent 88296ac326
commit bf09af3acb
3 changed files with 12 additions and 3 deletions

View File

@@ -41,9 +41,12 @@ def get_suitable_downloader(info_dict, params={}):
if ed.can_download(info_dict):
return ed
if protocol == 'm3u8' and params.get('hls_prefer_native'):
if protocol == 'm3u8' and params.get('hls_prefer_native') is True:
return HlsFD
if protocol == 'm3u8_native' and params.get('hls_prefer_native') is False:
return FFmpegFD
return PROTOCOL_MAP.get(protocol, HttpFD)