projects
/
ytdl
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
82f3993
)
[orf:tvthek] Fix thumbnails extraction (closes #29217)
author
Sergey M․
<dstftw@gmail.com>
Sat, 5 Jun 2021 16:42:25 +0000
(23:42 +0700)
committer
Sergey M․
<dstftw@gmail.com>
Sat, 5 Jun 2021 16:42:25 +0000
(23:42 +0700)
youtube_dl/extractor/orf.py
patch
|
blob
|
history
diff --git
a/youtube_dl/extractor/orf.py
b/youtube_dl/extractor/orf.py
index 3fadbcbead6c901b4b99203dd11c58d1c68df97e..ed8a9a84147e5e7944e1ae4cd79847d7c6eb19e8 100644
(file)
--- a/
youtube_dl/extractor/orf.py
+++ b/
youtube_dl/extractor/orf.py
@@
-140,6
+140,25
@@
class ORFTVthekIE(InfoExtractor):
})
upload_date = unified_strdate(sd.get('created_date'))
})
upload_date = unified_strdate(sd.get('created_date'))
+
+ thumbnails = []
+ preview = sd.get('preview_image_url')
+ if preview:
+ thumbnails.append({
+ 'id': 'preview',
+ 'url': preview,
+ 'preference': 0,
+ })
+ image = sd.get('image_full_url')
+ if not image and len(data_jsb) == 1:
+ image = self._og_search_thumbnail(webpage)
+ if image:
+ thumbnails.append({
+ 'id': 'full',
+ 'url': image,
+ 'preference': 1,
+ })
+
entries.append({
'_type': 'video',
'id': video_id,
entries.append({
'_type': 'video',
'id': video_id,
@@
-149,7
+168,7
@@
class ORFTVthekIE(InfoExtractor):
'description': sd.get('description'),
'duration': int_or_none(sd.get('duration_in_seconds')),
'upload_date': upload_date,
'description': sd.get('description'),
'duration': int_or_none(sd.get('duration_in_seconds')),
'upload_date': upload_date,
- 'thumbnail
': sd.get('image_full_url')
,
+ 'thumbnail
s': thumbnails
,
})
return {
})
return {