1 from __future__ import unicode_literals
5 from .common import InfoExtractor
6 from ..compat import compat_urllib_parse
14 class AUEngineIE(InfoExtractor):
15 _VALID_URL = r'http://(?:www\.)?auengine\.com/embed\.php\?.*?file=(?P<id>[^&]+).*?'
18 'url': 'http://auengine.com/embed.php?file=lfvlytY6&w=650&h=370',
19 'md5': '48972bdbcf1a3a2f5533e62425b41d4f',
23 'title': '[Commie]The Legend of the Legendary Heroes - 03 - Replication Eye (Alpha Stigma)[F9410F5A]'
27 def _real_extract(self, url):
28 video_id = self._match_id(url)
30 webpage = self._download_webpage(url, video_id)
31 title = self._html_search_regex(
32 r'<title>\s*(?P<title>.+?)\s*</title>', webpage, 'title')
33 video_urls = re.findall(r'http://\w+.auengine.com/vod/.*[^\W]', webpage)
34 video_url = compat_urllib_parse.unquote(video_urls[0])
35 thumbnails = re.findall(r'http://\w+.auengine.com/thumb/.*[^\W]', webpage)
36 thumbnail = compat_urllib_parse.unquote(thumbnails[0])
39 raise ExtractorError('Could not find video URL')
41 ext = '.' + determine_ext(video_url)
42 title = remove_end(title, ext)
48 'thumbnail': thumbnail,
49 'http_referer': 'http://www.auengine.com/flowplayer/flowplayer.commercial-3.2.14.swf',