mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-02 06:27:21 +00:00
do not rename protocol; add conditions to FFmpegFixupM3u8PP
This commit is contained in:
parent
fe592cd6ab
commit
e720e8879d
|
@ -3546,7 +3546,8 @@ def ffmpeg_fixup(cndn, msg, cls):
|
|||
'writing DASH m4a. Only some players support this container',
|
||||
FFmpegFixupM4aPP)
|
||||
ffmpeg_fixup(downloader == 'hlsnative' and not self.params.get('hls_use_mpegts')
|
||||
or info_dict.get('is_live') and self.params.get('hls_use_mpegts') is None,
|
||||
or info_dict.get('is_live') and self.params.get('hls_use_mpegts') is None
|
||||
or downloader == 'niconico_live',
|
||||
'Possible MPEG-TS in MP4 container or malformed AAC timestamps',
|
||||
FFmpegFixupM3u8PP)
|
||||
ffmpeg_fixup(downloader == 'dashsegments'
|
||||
|
|
|
@ -50,7 +50,7 @@ def get_suitable_downloader(info_dict, params={}, default=NO_DEFAULT, protocol=N
|
|||
'ism': IsmFD,
|
||||
'mhtml': MhtmlFD,
|
||||
'niconico_dmc': NiconicoDmcFD,
|
||||
'm3u8_niconico_live': NiconicoLiveFD,
|
||||
'niconico_live': NiconicoLiveFD,
|
||||
'fc2_live': FC2LiveFD,
|
||||
'websocket_frag': WebSocketFragmentFD,
|
||||
'youtube_live_chat': YoutubeLiveChatFD,
|
||||
|
|
|
@ -1007,7 +1007,7 @@ def _yield_formats(self, ws_url, headers, latency, video_id, is_live):
|
|||
for fmt, q in zip(formats, reversed(qualities[1:])):
|
||||
fmt.update({
|
||||
'format_id': q,
|
||||
'protocol': 'm3u8_niconico_live',
|
||||
'protocol': 'niconico_live',
|
||||
})
|
||||
yield fmt
|
||||
|
||||
|
|
|
@ -888,7 +888,7 @@ def run(self, info):
|
|||
class FFmpegFixupM3u8PP(FFmpegFixupPostProcessor):
|
||||
def _needs_fixup(self, info):
|
||||
yield info['ext'] in ('mp4', 'm4a')
|
||||
yield info['protocol'].startswith('m3u8')
|
||||
yield info['protocol'].startswith('m3u8') or info['protocol'] == 'niconico_live'
|
||||
try:
|
||||
metadata = self.get_metadata_object(info['filepath'])
|
||||
except PostProcessingError as e:
|
||||
|
|
Loading…
Reference in a new issue