|
|
@ -45,13 +45,18 @@ class PornHdIE(InfoExtractor):
|
|
|
|
thumbnail = self._search_regex(
|
|
|
|
thumbnail = self._search_regex(
|
|
|
|
r"'poster'\s*:\s*'([^']+)'", webpage, 'thumbnail', fatal=False)
|
|
|
|
r"'poster'\s*:\s*'([^']+)'", webpage, 'thumbnail', fatal=False)
|
|
|
|
|
|
|
|
|
|
|
|
quality = qualities(['SD', 'HD'])
|
|
|
|
quality = qualities(['sd', 'hd'])
|
|
|
|
formats = [{
|
|
|
|
sources = json.loads(js_to_json(self._search_regex(
|
|
|
|
'url': source['file'],
|
|
|
|
r"(?s)'sources'\s*:\s*(\{.+?\})\s*\}\);", webpage, 'sources')))
|
|
|
|
'format_id': '%s-%s' % (source['label'], determine_ext(source['file'])),
|
|
|
|
formats = []
|
|
|
|
'quality': quality(source['label']),
|
|
|
|
for container, s in sources.items():
|
|
|
|
} for source in json.loads(js_to_json(self._search_regex(
|
|
|
|
for qname, video_url in s.items():
|
|
|
|
r"(?s)'sources'\s*:\s*(\[.+?\])", webpage, 'sources')))]
|
|
|
|
formats.append({
|
|
|
|
|
|
|
|
'url': video_url,
|
|
|
|
|
|
|
|
'container': container,
|
|
|
|
|
|
|
|
'format_id': '%s-%s' % (container, qname),
|
|
|
|
|
|
|
|
'quality': quality(qname),
|
|
|
|
|
|
|
|
})
|
|
|
|
self._sort_formats(formats)
|
|
|
|
self._sort_formats(formats)
|
|
|
|
|
|
|
|
|
|
|
|
return {
|
|
|
|
return {
|
|
|
|