mirror of
https://codeberg.org/polarisfm/youtube-dl
synced 2025-01-10 07:07:55 +01:00
[AnimeLab] Add thumbnail extraction
This commit is contained in:
parent
84d4419bad
commit
27076a6e22
@ -119,7 +119,14 @@ class AnimeLabIE(InfoExtractor):
|
|||||||
|
|
||||||
description = raw_data.get('synopsis') or self._og_search_description(webpage, default=None)
|
description = raw_data.get('synopsis') or self._og_search_description(webpage, default=None)
|
||||||
|
|
||||||
# TODO extract thumbnails and other things youtube-dl optionally wants
|
thumbnail_data = raw_data.get('thumbnailInstance', {})
|
||||||
|
image_data = thumbnail_data.get('imageInfo', {})
|
||||||
|
thumbnails = [{
|
||||||
|
'id': str_or_none(thumbnail_data.get('id')),
|
||||||
|
'url': image_data.get('fullPath'),
|
||||||
|
'width': image_data.get('width'),
|
||||||
|
'height': image_data.get('height'),
|
||||||
|
}]
|
||||||
|
|
||||||
formats = []
|
formats = []
|
||||||
for video_data in raw_data['videoList']:
|
for video_data in raw_data['videoList']:
|
||||||
@ -181,6 +188,7 @@ class AnimeLabIE(InfoExtractor):
|
|||||||
'series': series,
|
'series': series,
|
||||||
'episode': episode_name,
|
'episode': episode_name,
|
||||||
'episode_number': int_or_none(episode_number),
|
'episode_number': int_or_none(episode_number),
|
||||||
|
'thumbnails': thumbnails,
|
||||||
'formats': formats,
|
'formats': formats,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user