mirror of
https://github.com/l1ving/youtube-dl
synced 2025-03-28 05:50:01 +08:00
Get list of all available thumbnails, rather than just the largest.
This commit is contained in:
parent
bebcdfeff6
commit
5509e05d34
@ -107,7 +107,11 @@ class RoosterTeethIE(InfoExtractor):
|
|||||||
description = attributes.get('caption')
|
description = attributes.get('caption')
|
||||||
series = attributes.get('show_title')
|
series = attributes.get('show_title')
|
||||||
|
|
||||||
thumbnail = try_get(data, lambda x: x['included']['images'][0]['attributes']['large'], compat_str)
|
thumbnails = []
|
||||||
|
for size in ['thumb', 'small', 'medium', 'large']:
|
||||||
|
thumbnail = try_get(data, lambda x: x['included']['images'][0]['attributes'][size], compat_str)
|
||||||
|
if thumbnail:
|
||||||
|
thumbnails.append({'url': thumbnail})
|
||||||
|
|
||||||
video_response = self._call_api(
|
video_response = self._call_api(
|
||||||
display_id,
|
display_id,
|
||||||
@ -154,7 +158,7 @@ class RoosterTeethIE(InfoExtractor):
|
|||||||
'display_id': display_id,
|
'display_id': display_id,
|
||||||
'title': title,
|
'title': title,
|
||||||
'description': description,
|
'description': description,
|
||||||
'thumbnail': thumbnail,
|
'thumbnails': thumbnails,
|
||||||
'series': series,
|
'series': series,
|
||||||
'episode': episode,
|
'episode': episode,
|
||||||
'formats': formats,
|
'formats': formats,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user