projects
/
youtube-dl
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Generic: use compat_urllib_parse_unquote to prevent utf8 mangling
[youtube-dl]
/
youtube_dl
/
downloader
/
__init__.py
diff --git
a/youtube_dl/downloader/__init__.py
b/youtube_dl/downloader/__init__.py
index eff1122c5c09eff494ad34af835b06e33c9e4751..f110830c472eb451d77b48fa9337bd5feee55952 100644
(file)
--- a/
youtube_dl/downloader/__init__.py
+++ b/
youtube_dl/downloader/__init__.py
@@
-6,7
+6,7
@@
from .f4m import F4mFD
from .hls import HlsFD
from .hls import NativeHlsFD
from .http import HttpFD
from .hls import HlsFD
from .hls import NativeHlsFD
from .http import HttpFD
-from .
mplayer import Mplayer
FD
+from .
rtsp import Rtsp
FD
from .rtmp import RtmpFD
from ..utils import (
from .rtmp import RtmpFD
from ..utils import (
@@
-17,8
+17,8
@@
PROTOCOL_MAP = {
'rtmp': RtmpFD,
'm3u8_native': NativeHlsFD,
'm3u8': HlsFD,
'rtmp': RtmpFD,
'm3u8_native': NativeHlsFD,
'm3u8': HlsFD,
- 'mms':
Mplayer
FD,
- 'rtsp':
Mplayer
FD,
+ 'mms':
Rtsp
FD,
+ 'rtsp':
Rtsp
FD,
'f4m': F4mFD,
}
'f4m': F4mFD,
}
@@
-34,6
+34,9
@@
def get_suitable_downloader(info_dict, params={}):
if ed.supports(info_dict):
return ed
if ed.supports(info_dict):
return ed
+ if protocol == 'm3u8' and params.get('hls_prefer_native'):
+ return NativeHlsFD
+
return PROTOCOL_MAP.get(protocol, HttpFD)
return PROTOCOL_MAP.get(protocol, HttpFD)