mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-11-21 20:46:36 -05:00
parent
72e1fe969f
commit
46fff7105e
1 changed files with 4 additions and 2 deletions
|
@ -2079,8 +2079,10 @@ def feed_entry(name):
|
|||
for m in re.finditer(self._meta_regex('og:video:tag'), webpage)]
|
||||
for keyword in keywords:
|
||||
if keyword.startswith('yt:stretch='):
|
||||
w, h = keyword.split('=')[1].split(':')
|
||||
w, h = int(w), int(h)
|
||||
stretch_ratio = map(
|
||||
lambda x: int_or_none(x, default=0),
|
||||
keyword.split('=')[1].split(':'))
|
||||
w, h = (list(stretch_ratio) + [0])[:2]
|
||||
if w > 0 and h > 0:
|
||||
ratio = w / h
|
||||
for f in formats:
|
||||
|
|
Loading…
Reference in a new issue