mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-21 20:46:36 -05:00
[FFmpegFixupM3u8PP] Check audio codec before fixup (#6778)
Closes #6673 Authored by: bashonly
This commit is contained in:
parent
925936908a
commit
3f7e2bd80e
1 changed files with 4 additions and 1 deletions
|
@ -898,8 +898,11 @@ def _needs_fixup(self, info):
|
||||||
@PostProcessor._restrict_to(images=False)
|
@PostProcessor._restrict_to(images=False)
|
||||||
def run(self, info):
|
def run(self, info):
|
||||||
if all(self._needs_fixup(info)):
|
if all(self._needs_fixup(info)):
|
||||||
|
args = ['-f', 'mp4']
|
||||||
|
if self.get_audio_codec(info['filepath']) == 'aac':
|
||||||
|
args.extend(['-bsf:a', 'aac_adtstoasc'])
|
||||||
self._fixup('Fixing MPEG-TS in MP4 container', info['filepath'], [
|
self._fixup('Fixing MPEG-TS in MP4 container', info['filepath'], [
|
||||||
*self.stream_copy_opts(), '-f', 'mp4', '-bsf:a', 'aac_adtstoasc'])
|
*self.stream_copy_opts(), *args])
|
||||||
return [], info
|
return [], info
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue