0
0
Fork 0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2024-12-03 03:57:26 +00:00

[generic] Add support for Limelight API

This commit is contained in:
remitamine 2016-01-30 20:45:56 +01:00
parent b8c9926c0a
commit 1bf996fa5c

View file

@ -1819,6 +1819,17 @@ def _playlist_from_matches(matches, getter=None, ie=None):
if digiteka_url:
return self.url_result(self._proto_relative_url(digiteka_url), DigitekaIE.ie_key())
# Look for Limelight embeds
mobj = re.search(r'LimelightPlayer\.doLoad(Media|Channel|ChannelList)\(["\'](?P<id>[a-z0-9]{32})', webpage)
if mobj:
lm = {
'Media': 'media',
'Channel': 'channel',
'ChannelList': 'channel_list',
}
return self.url_result('limelight:%s:%s' % (
lm[mobj.group(1)], mobj.group(2)), 'Limelight%s' % mobj.group(1), mobj.group(2))
# Look for AdobeTVVideo embeds
mobj = re.search(
r'<iframe[^>]+src=[\'"]((?:https?:)?//video\.tv\.adobe\.com/v/\d+[^"]+)[\'"]',